Verifies SSL certificate of server

Fixes #5