This repository has been archived by the owner. It is now read-only.

error setting certificate verify locations #1484

Closed
baloney opened this Issue Oct 3, 2011 · 31 comments

Comments

Projects
None yet
@baloney

baloney commented Oct 3, 2011

Hi,
I'm trying to follow the windows install instructions here:
http://npmjs.org/doc/README.html#Installing-on-Windows-Experimental
The install git link is dead so I hay have missed something but I installed git and got to:
git clone --recursive git://github.com/isaacs/npm.git
which gives the following error
Cloning into node_modules/abbrev...
error: error setting certificate verify locations:
CAfile: \bincurl-ca-bundle.crt
CApath: none
while accessing https://github.com/isaacs/abbrev-js.git/info/refs

fatal: HTTP request failed

@isaacs

This comment has been minimized.

Show comment
Hide comment
@isaacs

isaacs Oct 3, 2011

Member

Updated the instructions already. git config --system http.sslcainfo /bin/curl-ca-bundle.crt should make it work.

Member

isaacs commented Oct 3, 2011

Updated the instructions already. git config --system http.sslcainfo /bin/curl-ca-bundle.crt should make it work.

@isaacs isaacs closed this Oct 3, 2011

@DedrickEnc

This comment has been minimized.

Show comment
Hide comment
@DedrickEnc

DedrickEnc Feb 3, 2016

git config --global http.sslverify "false" will solve the problem

DedrickEnc commented Feb 3, 2016

git config --global http.sslverify "false" will solve the problem

@PoojaShekhar

This comment has been minimized.

Show comment
Hide comment
@PoojaShekhar

PoojaShekhar Feb 3, 2016

Hey Dedrick,

Thanks a ton !!! I also had the same problem and got that solved with the command you shared just now.Thanks a lot !!

PoojaShekhar commented Feb 3, 2016

Hey Dedrick,

Thanks a ton !!! I also had the same problem and got that solved with the command you shared just now.Thanks a lot !!

@Homezonic

This comment has been minimized.

Show comment
Hide comment
@Homezonic

Homezonic Feb 8, 2016

Wow. Thanks @DedrickEnc worked like charm

Homezonic commented Feb 8, 2016

Wow. Thanks @DedrickEnc worked like charm

@hilb3rt

This comment has been minimized.

Show comment
Hide comment
@hilb3rt

hilb3rt Feb 10, 2016

It should be noted @DedrickEnc's "solution" turns off the ssl verification and is a "work around" not a solution to the problem.

hilb3rt commented Feb 10, 2016

It should be noted @DedrickEnc's "solution" turns off the ssl verification and is a "work around" not a solution to the problem.

@NathanSteele

This comment has been minimized.

Show comment
Hide comment
@NathanSteele

NathanSteele Feb 11, 2016

@DedrickEnc, you are the MAN!!!!

NathanSteele commented Feb 11, 2016

@DedrickEnc, you are the MAN!!!!

@wilmertri

This comment has been minimized.

Show comment
Hide comment
@wilmertri

wilmertri Feb 20, 2016

Thanks good response!

wilmertri commented Feb 20, 2016

Thanks good response!

@dreamchenzhou

This comment has been minimized.

Show comment
Hide comment
@dreamchenzhou

dreamchenzhou Feb 27, 2016

@DedrickEnc thanks ,your advice work !

dreamchenzhou commented Feb 27, 2016

@DedrickEnc thanks ,your advice work !

@tejeswarbharath

This comment has been minimized.

Show comment
Hide comment
@tejeswarbharath

tejeswarbharath commented Mar 25, 2016

@DedrickEnc Thanks

@MariiaMaltseva

This comment has been minimized.

Show comment
Hide comment
@MariiaMaltseva

MariiaMaltseva Apr 2, 2016

@DedrickEnc, Thanks very much from Kiev!

MariiaMaltseva commented Apr 2, 2016

@DedrickEnc, Thanks very much from Kiev!

@hirenchauhan2

This comment has been minimized.

Show comment
Hide comment
@hirenchauhan2

hirenchauhan2 Apr 24, 2016

@DedrickEnc You saved my hours....!! Thanks Man..

hirenchauhan2 commented Apr 24, 2016

@DedrickEnc You saved my hours....!! Thanks Man..

@wacannon

This comment has been minimized.

Show comment
Hide comment
@wacannon

wacannon Apr 26, 2016

@DedrickEnc that worked, thanks!

wacannon commented Apr 26, 2016

@DedrickEnc that worked, thanks!

@crystalchi

This comment has been minimized.

Show comment
Hide comment
@crystalchi

crystalchi Jun 9, 2016

@DedrickEnc, Thanks you so much!

crystalchi commented Jun 9, 2016

@DedrickEnc, Thanks you so much!

@collhector

This comment has been minimized.

Show comment
Hide comment
@collhector

collhector Aug 28, 2016

@DedrickEnc , Thanks, but, what that command mean? Not clear why it work?

collhector commented Aug 28, 2016

@DedrickEnc , Thanks, but, what that command mean? Not clear why it work?

@Eugen1Buslaev

This comment has been minimized.

Show comment
Hide comment
@Eugen1Buslaev

Eugen1Buslaev commented Oct 21, 2016

@DedrickEnc , Thanks!

@danielarnost

This comment has been minimized.

Show comment
Hide comment
@danielarnost

danielarnost Dec 3, 2016

DedrickEnc's response will work but it is ill advised to disable all SSL verification, you can specify specific paths to disable:

DISABLE ALL SSL
// or switch off ALL SSL checks completely by executing:
git config --system http.sslverify false

OR
//Set this in your config to disable it only for the GIVEN url and not for all requests
[http "https://weak.example.com"]
sslVerify = false

Also for me, the cert was just randomly in the wrong place. I made a dummy path to where my terminal thought my cert was, and copied and pasted my cert in there (in my case:

  1. My terminal thought my cert was in : "C:\Program Files\path\to \git\bin\ca-bundle.crt, when that path did not exist on my computer.
  2. Make this path in your directory (you can use -p flag to make a layered directory and just copy paste your example, in my case : mkdir -p path\to \git\bin\
  3. Find your real cert and copy paste it in to terminal's desired path
  4. open terminal as admin for windows, use sudo command for mac
    run > git config --system http.sslcainfo "C:\Program Files\path\to \git\bin\ca-bundle.crt" --replace-all***
    . This worked without disabling SSL,)

danielarnost commented Dec 3, 2016

DedrickEnc's response will work but it is ill advised to disable all SSL verification, you can specify specific paths to disable:

DISABLE ALL SSL
// or switch off ALL SSL checks completely by executing:
git config --system http.sslverify false

OR
//Set this in your config to disable it only for the GIVEN url and not for all requests
[http "https://weak.example.com"]
sslVerify = false

Also for me, the cert was just randomly in the wrong place. I made a dummy path to where my terminal thought my cert was, and copied and pasted my cert in there (in my case:

  1. My terminal thought my cert was in : "C:\Program Files\path\to \git\bin\ca-bundle.crt, when that path did not exist on my computer.
  2. Make this path in your directory (you can use -p flag to make a layered directory and just copy paste your example, in my case : mkdir -p path\to \git\bin\
  3. Find your real cert and copy paste it in to terminal's desired path
  4. open terminal as admin for windows, use sudo command for mac
    run > git config --system http.sslcainfo "C:\Program Files\path\to \git\bin\ca-bundle.crt" --replace-all***
    . This worked without disabling SSL,)
@wxjaa

This comment has been minimized.

Show comment
Hide comment
@wxjaa

wxjaa Jan 14, 2017

thank you very much

wxjaa commented Jan 14, 2017

thank you very much

@wolfm

This comment has been minimized.

Show comment
Hide comment
@wolfm

wolfm Jan 29, 2017

daniealarnosts's solution worked for me too! Thanks a ton.

wolfm commented Jan 29, 2017

daniealarnosts's solution worked for me too! Thanks a ton.

@JieYuShi

This comment has been minimized.

Show comment
Hide comment
@JieYuShi

JieYuShi Feb 1, 2017

Thank you

JieYuShi commented Feb 1, 2017

Thank you

@FarzanehK

This comment has been minimized.

Show comment
Hide comment
@FarzanehK

FarzanehK commented Feb 12, 2017

@DedrickEnc , Thank you.

@Jim43

This comment has been minimized.

Show comment
Hide comment
@Jim43

Jim43 Mar 6, 2017

@danielarnost I can't find my cert file where the terminal show me,what can i do now ?

Jim43 commented Mar 6, 2017

@danielarnost I can't find my cert file where the terminal show me,what can i do now ?

@DanfengZhao

This comment has been minimized.

Show comment
Hide comment
@DanfengZhao

DanfengZhao commented Mar 20, 2017

@DedrickEnc , Thanks!

@xf789050

This comment has been minimized.

Show comment
Hide comment
@xf789050

xf789050 Mar 29, 2017

@danielarnost Thanks very much!

xf789050 commented Mar 29, 2017

@danielarnost Thanks very much!

@kris-luminar

This comment has been minimized.

Show comment
Hide comment
@kris-luminar

kris-luminar Mar 29, 2017

ln -s /etc/pki/tls/cert.pem /home/myusername/.linuxbrew/etc/openssl/cert.pem worked for me (basically, a refinement of @danielarnost 's solution.

This made it so I didn't have to use @DedrickEnc's presumably risky disabling cert workaround, which didn't completely work in my case anyway.

kris-luminar commented Mar 29, 2017

ln -s /etc/pki/tls/cert.pem /home/myusername/.linuxbrew/etc/openssl/cert.pem worked for me (basically, a refinement of @danielarnost 's solution.

This made it so I didn't have to use @DedrickEnc's presumably risky disabling cert workaround, which didn't completely work in my case anyway.

@khaynay

This comment has been minimized.

Show comment
Hide comment
@khaynay

khaynay Apr 9, 2017

Thanks @derrick. command worked for me

khaynay commented Apr 9, 2017

Thanks @derrick. command worked for me

@abobakr11

This comment has been minimized.

Show comment
Hide comment
@abobakr11

abobakr11 Sep 13, 2017

thanks man it work

abobakr11 commented Sep 13, 2017

thanks man it work

@faniuta

This comment has been minimized.

Show comment
Hide comment
@faniuta

faniuta Oct 14, 2017

you first should find your ca-bundle.crt file , check this path and if exist, try this :
git config --global http.sslcainfo "C:/Program Files/Git/mingw64/ssl/certs/ca-bundle.crt"

faniuta commented Oct 14, 2017

you first should find your ca-bundle.crt file , check this path and if exist, try this :
git config --global http.sslcainfo "C:/Program Files/Git/mingw64/ssl/certs/ca-bundle.crt"

@pietropino

This comment has been minimized.

Show comment
Hide comment
@pietropino

pietropino Dec 31, 2017

@faniuta +1, thanks, it looked for it in the wrong position.

pietropino commented Dec 31, 2017

@faniuta +1, thanks, it looked for it in the wrong position.

@Brain-Gamer

This comment has been minimized.

Show comment
Hide comment
@Brain-Gamer

Brain-Gamer Mar 15, 2018

@faniuta this helped me a lot! Although I had to change the system settings and not the global ones :D

Brain-Gamer commented Mar 15, 2018

@faniuta this helped me a lot! Although I had to change the system settings and not the global ones :D

@BettyWong256

This comment has been minimized.

Show comment
Hide comment
@BettyWong256

BettyWong256 Apr 12, 2018

@DedrickEnc , Thank you so much

BettyWong256 commented Apr 12, 2018

@DedrickEnc , Thank you so much

@rogerne

This comment has been minimized.

Show comment
Hide comment
@rogerne

rogerne Apr 20, 2018

Many thanks to @DedrickEnc.

rogerne commented Apr 20, 2018

Many thanks to @DedrickEnc.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.