Self_signed_cert_in_chain

I try to instal oxygen-cli using the following chain of commands:

  1. npm config set https-proxy http://xxxx.xxxx.xxxx.xxxx:xxxx
  2. npm install -g oxygen-cli

But the process ends with error: SELF_SIGNED_CERT_IN_CHAIN

npm ERR! code SELF_SIGNED_CERT_IN_CHAIN
npm ERR! errno SELF_SIGNED_CERT_IN_CHAIN
npm ERR! request to https://registry.npmjs.org/oxygen-cli failed, reason: self signed certificate in certificate chain

Please advise action to take.

Sergio Yahni

Hi Sergio,

Here are some related links with information that we could look into to attempt to troubleshoot with.

You could try this approach:

  1. Run these three commands in a sequence.

npm config set strict-ssl false
npm update npm –g
npm config set strict-ssl true
2) Set both properties proxy and https-proxy in the npm config using these commands:

npm config set proxy=“http://“proxy-name”:8080”
npm config set https-proxy=“http://“proxy-name”:8080”

and then install the oxygen-cli package

Please check out the npmjs blog post as well.

You can also email me - amos.feldman@cloudbeat.io and we can attempt to troubleshoot together.

Please let me know what else you’ve already tried.

Thanks,
-Amos

Thanks a lot.
To overcome a self-signed certificate error behind a corporate proxy:

  1. npm config set http-proxy http://proxy.[Company Name].com:8080
    • Additional npm configurations may be required
    • however, configurations behind a proxy should be http otherwise you will receive a self-signed certificate error
  2. npm install -g oxygen-cli
2 Likes

@sergioy Thanks for sharing the solution that worked for you with the community!