close socket upon CertificateError
PermissionError is new in Py33
1.3rc2
merge 1.3.X