Added SSL support and support for authentication against a different database

1) Added basic SSL support.
2) Added support to authenticate against a different DB to the one being logged to.
3) Fixed issue where a capped collection wasn't being created when a username/password was supplied.