I was in a similar situation at a previous company - they knew of my side project, and wanted to use some of the concepts of it in the work I was doing. As karterk mentioned, it really came down to trust - I explained that I would not be signing over rights to my software and that I would continue selling it on the side, without the modifications being made to it for them. They were fine with this and it never became an issue. I don't think a simple handshake would be sufficient in most cases, but I was trusting enough of my manager (I was there for over 4 years) and went that route. If you are truly concerned about the IP, then you should get both your manager, but also legal to approve it in writing.