Show More
@@ -113,6 +113,9 b' class validator(object):' | |||||
113 | if not sock.cipher(): # work around http://bugs.python.org/issue13721 |
|
113 | if not sock.cipher(): # work around http://bugs.python.org/issue13721 | |
114 | raise util.Abort(_('%s ssl connection error') % host) |
|
114 | raise util.Abort(_('%s ssl connection error') % host) | |
115 | peercert = sock.getpeercert(True) |
|
115 | peercert = sock.getpeercert(True) | |
|
116 | if not peercert: | |||
|
117 | raise util.Abort(_('%s certificate error: ' | |||
|
118 | 'no certificate received') % host) | |||
116 | peerfingerprint = util.sha1(peercert).hexdigest() |
|
119 | peerfingerprint = util.sha1(peercert).hexdigest() | |
117 | nicefingerprint = ":".join([peerfingerprint[x:x + 2] |
|
120 | nicefingerprint = ":".join([peerfingerprint[x:x + 2] | |
118 | for x in xrange(0, len(peerfingerprint), 2)]) |
|
121 | for x in xrange(0, len(peerfingerprint), 2)]) |
General Comments 0
You need to be logged in to leave comments.
Login now