0

Recently Mercurial has added certificate validation when connecting to HTTPS servers. I'm trying to clone the wiki repository for a Google Code project at https://wiki.droidweight.googlecode.com/hg/, but the certificate is for *.googlecode.com.

Google Code's certificate does not cover multiple subdomains like *.*.googlecode.com.

I'm getting the error:

% hg clone --verbose https://wiki.droidweight.googlecode.com/hg/ -- C:\workspace\wiki
abort: wiki.droidweight.googlecode.com certificate error: certificate is for *.googlecode.com, googlecode.com, *.codespot.com, *.googlesource.com, googlesource.com (use --insecure to connect insecurely)

I need to get the certificate fingerprint. This SO answer says how to do it on *nix.

How would one get the fingerprint on Windows 7 (Home Premium)?

References:

Community
  • 1
  • 1
blokeley
  • 6,726
  • 9
  • 53
  • 75
  • Since you're using TortoiseHg, [this Q&A](http://stackoverflow.com/questions/6293167/disabling-https-host-authentication-in-tortoisehg-for-internal-self-signed-certif) will help, as there's a place in the UI for querying the fingerprint. – Joel B Fant Jun 14 '11 at 14:51

1 Answers1

0

Which version of Mercurial are you using? 1.8.2 prints the fingerprint when you clone, as per the documentation.

EDIT: After some testing, I realised that Mercurial prints the certificate when you connect insecurely (I don't have web.cacerts configured, so cloning always succeeded, though with a warning). So if you pass --insecure to your hg clone, you'll get a clone and a fingerprint.

Alternatively, install GnuWin32! It makes the Windows command line a fun place to be :) (I have no affiliation with GnuWin32; just hugely appreciative.)

anton.burger
  • 5,637
  • 32
  • 48
  • Thanks for the answer. I'm using mercurial 1.8.4 (the one bundled with TortoiseHg 2.0.5). I'll test and, if it works, mark the question answered. – blokeley Jun 14 '11 at 12:00