You'll need to create a custom workflow that fires on email Create. You will then need to program custom logic to see if the email is from a known contact and if not create the contact.
hope this helps you going in the right direction. If you have more questions feel free to postback.
Hassan.
Hassan Hussain | http://hassanhussain.wordpress.com/