equal
deleted
inserted
replaced
105 hostfingerprint = self.ui.config('hostfingerprints', host) |
105 hostfingerprint = self.ui.config('hostfingerprints', host) |
106 if not getattr(sock, 'getpeercert', False): # python 2.5 ? |
106 if not getattr(sock, 'getpeercert', False): # python 2.5 ? |
107 if hostfingerprint: |
107 if hostfingerprint: |
108 raise util.Abort(_("host fingerprint for %s can't be " |
108 raise util.Abort(_("host fingerprint for %s can't be " |
109 "verified (Python too old)") % host) |
109 "verified (Python too old)") % host) |
110 self.ui.warn(_("warning: certificate for %s can't be verified " |
110 if self.ui.configbool('ui', 'reportoldssl', True): |
111 "(Python too old)\n") % host) |
111 self.ui.warn(_("warning: certificate for %s can't be verified " |
|
112 "(Python too old)\n") % host) |
112 return |
113 return |
113 if not sock.cipher(): # work around http://bugs.python.org/issue13721 |
114 if not sock.cipher(): # work around http://bugs.python.org/issue13721 |
114 raise util.Abort(_('%s ssl connection error') % host) |
115 raise util.Abort(_('%s ssl connection error') % host) |
115 peercert = sock.getpeercert(True) |
116 peercert = sock.getpeercert(True) |
116 if not peercert: |
117 if not peercert: |