Cargo: Unknown certificate check failure on Windows 8

Hi! I am just starting with the rust language. It seems like cargo can’t download dependencies for my project. I am getting:

warning: spurious network error (2 tries remaining): unknown certificate check failure; class=Net (12); code=Certificate (-17)
warning: Certificate check failure might be caused by outdated TLS on older versions of Windows.
If you are using Windows 7, Windows Server 2008 R2 or Windows Server 2012, please follow these instructions to enable more secure TLS:

See for details.

error: failed to load source for a dependency on ftp

Caused by:
Unable to update registry

Caused by:
failed to fetch

Caused by:
unknown certificate check failure; class=Net (12); code=Certificate (-17)

This is strange since I am running an up-to-date Windows 8 x64. I can’t apply the patch suggested by Microsoft since it is for Windows 7, but I’ve created the DefaultSecureProtocols registry entry in order to use TLS 1.2 by default, but still getting the error.

I think rust and cargo are up to date:

> rustc -V
rustc 1.25.0 (84203cac6 2018-03-25)
> cargo -V
cargo 0.26.0 (41480f5cc 2018-02-26)

Any suggestions? Thanks in advance!

I might be wrong, but looks like windows 8 is not supported by Microsoft and thus does not have the relevant patch. Could you check if the nightly version of rust has the same problem? We’ve recently updated libgit which should fix this even for unpatched OSes


Installing the nightly version solved the problem! In case someone has the same problem until this gets stable, just

> rustup install nightly
> rustup default nightly

to get rid of it.

Thanks a lot!