-
Notifications
You must be signed in to change notification settings - Fork 2.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
error unable to get local issuer certificate #841
Comments
I have the same issue because we are behind a proxy that adds self-signed ssl. |
The same issue happens when ca[]="-----BEGIN CERTIFICATE-----\n..." |
Having the same issue here at work! |
having the same issue, (i am using self-certificate.) |
Same issue, also setting the registry to a non-ssl variant or the original non-ssl registry.npmjs.org doesn't help. |
Behind a corporate proxy so running into this issue as well. |
I'm having the same exact error behind a corporate proxy :) . Can't wait for a fix :) |
I have same issue, the network is behind proxy, set strict-ssl to false and also config registry as non-ssl, still not work. Better to fix it as soon as possible. Can't wait it. |
PR #736 will add support for cafile, which is another way to solve this issue, and unlike disabling strict-ssl, you will not be vulnerable to MITM attacks. |
We've merged support for |
I'm still having this issue with yarn v0.21.3 Update: Also on nightly build 0.22.0-20170303.1013 |
I found that if I duplicated the strict-ssl and other config from .npmrc into .yarnrc then things started working (or use |
I had the same issue under the same circumstances but I ran this command |
Yes, that's what worked for me as well. |
@sylvesteraswin did the same and it worked, thx 👍 |
all broken in 0.23.1, setting registry to http and strict-ssl to false worked but now it does not. I have issues also with the certificate being intercepted and is why I need http. |
I tried |
@JesterXL It worked for me. Using same version v0.27.5 |
|
worked for me |
Just making sure people don't blindly copy paste code here: DO NOT DISABLE STRICT SSL CHECKS. Okay now that I have your attention, if you know what exactly you are doing and what risks you are taking on with this, you may. Otherwise, just don't. |
Is there a solution that doesn't involve exposing yourself to the dangers of using HTTP? I'd really like to be able to fix this without having to disable strict SSL. |
@ao Enjoy your non deterministic downloads! |
|
@vrajpoot That is great! But please do not post it here as it might trick other incautious people to also turn off basic security and potentially download malware on their computers. It it completely fine to like malware and on purpose infect your computer with it.... but it should stay as a research topic or a hobby thing not an actual thing that one would do on their work machine. |
@brandonsturgeon has brought up very valid points that should be addressed and the maintainers of yarn should respond. He's not the only one wondering. |
Interesting, everyone saying "do not disable strict-ssl". |
yarn config set strict-ssl false worked for me. Thanks |
I got this error when I tried to install jquery package. Upon tons of re-search finally found that Neither should one set the One can always check the configuration with yarn before and after above command |
@sandipt27 I'm sorry that it took you so long to find the right way. You didn't find them probably because:
You probably can't fix 3, and 2 is in another scope, but maybe someone can come out and fix 1. If you come up with a Pull Request and want a second pair of eye I can probably help (I do have some general knowledge about cryptography), although I'm not able to approve it since I'm not a maintainer. |
#841 (comment) I set up a private repository(Verdaccio) with local issuer certificate It worked in NPM without any issue. |
Will surely let you know for your needed help once I move towards Pull Request to fix it. :) |
I'm seeing the same thing as well sitting behind a Nexus proxy group. The CA file setting is set with both NPM and Yarn at this point, but I still get the error.
|
IIUC, once you set
|
This issue ranks pretty high in Google search. The amount of comments that tell you to disable SSL certificate verification is disturbing. Can we please make the web a safer place and cleanup the comments? The NODE_EXTRA_CA_CERTS as mentioned by @cben works for me and is IMHO the cleanest setting. |
NODE_EXTRA_CA_CERTS seems to work if you provide the whole chain as a CA. Is there a way to set the verification depth of the chain? If I provide a root CA and there is an intermediate, it does not work. It seems to only validate what's immediately in the CA store and will not walk up the chain to validate. |
@adjenks thats the idea of a certificate chain. If you don't provide the whole chain, you can't verify the correctness. |
Ah okay, thank you @wald-tq . Some clients, Chrome for example, will use the Authority Information Access (AIA) certificate extension, which contains information about how to get the issuer of this certificate, to fetch the certificate of the issuer automatically. I suppose it doesn't get used here. |
I hate to pile onto a thread this deep, please accept my apology. Given this docker file which is a modified "Getting Started Walkthrough" from docker desktop: FROM node:12-alpine Results:
executor failed running [/bin/sh -c yarn install --production --verbose]: exit code: 1 Q: Are there any glaring errors made to the original script that need to be corrected? Thank you, |
@stephenpatten: your Dockerfile looks good to me. Can't spot any errors. To debug the issue I would try the setup manually on command line and check if the certificate file is correct and contains all the certificates of the chain. |
renovate is getting this error; am i doing something wrong? |
On Windows I solved the issue by adding the following environment variable: NODE_EXTRA_CA_CERTS=C:\path\to\ca.pem where ca.pem is the chain certificate of the corporate CA that I exported from Firefox. |
It worked Thanks buddy |
Folks don't go for disabling |
Having the same issue with git push But working after git config --global http.sslbackend schannel but now again having same issue with yarn |
Hi
Do you want to request a feature or report a bug?
Bug
If the current behavior is a bug, please provide the steps to reproduce.
What is the expected behavior?
I want to install my dependencies.
Am I missing something (maybe) ?
Thanks
Please mention your node.js, yarn and operating system version.
NodeJS: V6.7
yarn: v0.15.1
OS: Windows 7
The text was updated successfully, but these errors were encountered: