email: add support for Server Name Indication (SNI)

Change the underlying socket factory reference to SSLCertificateSocketFactory which
has support for SNI since 4.2, and remove the access to the obsolete methods from
the old factory reference.
This change will setup the socket with a proper hostname prior to the ssl handshake.

Change-Id: Ic3315f3924f33470ea2da14e8ac3b946d039b1d5
JIRA: CYAN-3775
Issue: https://jira.cyanogenmod.org/browse/CYAN-3775
Signed-off-by: Jorge Ruesga <jorge@ruesga.com>
email: start handshake before hostname verification

Start handshake prior to hostname verification to ensure exceptions do not get silenced

Change-Id: Ide60753663d82d63b0f410b985447b7b26efd8f1
Signed-off-by: Jorge Ruesga <jorge@ruesga.com>
Merge branch 'remote' into mkl