I don't think you necessarily have to assume your boss is trying to fire you. It's good to take precautions in case, as others have suggested. However, he may just be trying to get you to work harder, or trying to prove you're not better than him or something.
When he looks over your shoulder when you're typing, you might try stopping (maybe closing the document) turning to him and saying "Did you want to talk to me about something?" or if he asks you to type so he can watch, you might keep saying "I'll email it to you in half an hour." or maybe even "Actually, it makes me nervous when someone watches while I type. I'll email it to you in half an hour."
Cathy
When he looks over your shoulder when you're typing, you might try stopping (maybe closing the document) turning to him and saying "Did you want to talk to me about something?" or if he asks you to type so he can watch, you might keep saying "I'll email it to you in half an hour." or maybe even "Actually, it makes me nervous when someone watches while I type. I'll email it to you in half an hour."
Cathy