-
Notifications
You must be signed in to change notification settings - Fork 37
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
SELF_SIGNED_CERT_IN_CHAIN when using private hosted npm registry #78
Comments
oh do you have a certificate configured for your npm? can you post the output |
I've removed a couple things.
|
Okay cool, no problem. Aha so you have a So the problem is that there are a few places that npmd does http, and needs to check if it's to the registry, and then needs to use the configured CA and possibly auth. possibly those uses could be modularized somehow, since it's actually a little more complicated, @novemberborn is also working on a PR that enables private github repos, I'm thinking a pattern where you take a URL, check if it matches a certain domain, and then add whatever headers are ready to auth for that domain. hmm. I guess sometimes authing will require an async operation, |
My coworker just reminded me that we are not using a self-signed cert. "We are using a cert signed by our own root (for revocation, multiple server certs, etc.)." Probably doesn't change your theories for solving this. |
right - so putting the expected ca in the config is probably still the solution to this. |
I'm closing because we migrated off |
reopening this because the issue is not actually resolved, and someone else might have this problem |
👍 Self-signed certificates and NPM are a real pain in the ass. We install some dependencies directly over HTTPS. The only solution that works with npm for us is I wanted to give npmd a try. And here’s what I get:
|
Oh hmm... okay so the ideal solution would be to be able to configure a cert to use for a particular domain, right? I would be happy to merge a PR that allowed you to set certs, and to answer any questions necessary. |
Yeah, so we’ve tried with npm – and after a several hours’ fight we gave up – and decided to pull our HTTPS modules with the option @dylang was that why you migrated off HTTPS? How about forwarding any options to npm? So you could just do |
well the strict-ssl option is actually a thing that is being passed to request. npmd doesn't depend on npm. |
@tomekwi We migrated to http because of (from what we can remember) couch issues with our cert and trust store and we didn't care to spend time trying to resolve because our registry is inside our firewall. |
Our registry is behind a firewall so I don't have a way to provide a test case but I'm happy to try out a work in progress branch. FWIW the classic npm client works with our registry, as have tools that use the classic npm apis such as npm-check.
The text was updated successfully, but these errors were encountered: