mercurial/sslutil.py
changeset 32273 2e455cbeac50
parent 32247 e05cfb4a6a8e
child 32291 bd872f64a8ba
equal deleted inserted replaced
32272:78496ac30025 32273:2e455cbeac50
   805                 ui.debug('%s certificate matched fingerprint %s:%s\n' %
   805                 ui.debug('%s certificate matched fingerprint %s:%s\n' %
   806                          (host, hash, fmtfingerprint(fingerprint)))
   806                          (host, hash, fmtfingerprint(fingerprint)))
   807                 if settings['legacyfingerprint']:
   807                 if settings['legacyfingerprint']:
   808                     ui.warn(_('(SHA-1 fingerprint for %s found in legacy '
   808                     ui.warn(_('(SHA-1 fingerprint for %s found in legacy '
   809                               '[hostfingerprints] section; '
   809                               '[hostfingerprints] section; '
   810                               'if you trust this fingerprint, set the '
   810                               'if you trust this fingerprint, remove the old '
   811                               'following config value in [hostsecurity] and '
   811                               'SHA-1 fingerprint from [hostfingerprints] and '
   812                               'remove the old one from [hostfingerprints] '
   812                               'add the following entry to the new '
   813                               'to upgrade to a more secure SHA-256 '
   813                               '[hostsecurity] section: %s:fingerprints=%s)\n') %
   814                               'fingerprint: '
   814                             (host, host, nicefingerprint))
   815                               '%s:fingerprints=%s)\n') % (
       
   816                                   host, host, nicefingerprint))
       
   817                 return
   815                 return
   818 
   816 
   819         # Pinned fingerprint didn't match. This is a fatal error.
   817         # Pinned fingerprint didn't match. This is a fatal error.
   820         if settings['legacyfingerprint']:
   818         if settings['legacyfingerprint']:
   821             section = 'hostfingerprint'
   819             section = 'hostfingerprint'