I think it is jealousy, not rules or company contracts that make bosses sue their employees. I say that because at one of my previous job, founder actively encouraged side projects and entrepreneurship.
But that company still end up shutting down side projects of two of its employees.
One was a simple site that documented company's API and had a few sample code snippets. It got popular. The guy running it even received recognition on company's newsletter. Next thing I know is that company forced the guy to handover site and domain to them. Apparently, he worked on it during work hours. He said he never did but who knows.
Then another guy's completely unrelated app got shut down due to same reasons. But the guy claims he never even opened app on his personal cell phone while on company property. Everyone in the company had some sort of app but this app got popular & profitable. Jealousy set in. One of his teammate claimed he saw the guys working on the app. He was forced to handover the code. Then company did nothing with the app and removed it from marketplace.
Rumor is that he has another app but he tells no one about it.
I believe same thing happens in big companies. AFAIK, they don't hire any team to monitor web to make sure their employees haven't released anything on their own. But someone who works with an employee learns about a successful app, gets jelous and tip legal department.
Lesson is even if your company is pro side projects, don't tell anyone about it. Humans are jealous creatures and they will find a way to hurt your project.