TLS support WIP
Merge branch 'master' into tls_support
TLS support WIP