Fix SSL function signatures.

Using :int instead of :pointer was causing segfaults on linux x86_64.
Compatibility improvements.
Restore SSL support.