I tried to use Axios with an https.Agent with pfx configuration but I get the below error message:
Error: unsupported
I checked https://github.com/axios/axios/issues/4778 and I applied the fix but it still didn't work. After that, I added a .npmrc file and by adding the node-options parameter there, it started working. The line that was added is:
node-options="--openssl-legacy-provider"
Can you please inform in which version of Node 18.x can I use my current setup without making use of .npmrc file? It won't be possible for me to downgrade the Node version. And if I have to use the .npmrc file, does it introduce any security threat?
Details
I tried to use Axios with an https.Agent with pfx configuration but I get the below error message:
Error: unsupported
I checked https://github.com/axios/axios/issues/4778 and I applied the fix but it still didn't work. After that, I added a .npmrc file and by adding the node-options parameter there, it started working. The line that was added is:
node-options="--openssl-legacy-provider"
Can you please inform in which version of Node 18.x can I use my current setup without making use of .npmrc file? It won't be possible for me to downgrade the Node version. And if I have to use the .npmrc file, does it introduce any security threat?
Node.js version
18.8.2
Example code
Operating system
Linux
Scope
Runtime
Module and version
Not applicable.