node
crypto
ai_generated
true
Error: error:0308010C:digital envelope routines::unsupported
ID: node/node-crypto-unsupported
90%Fix Rate
93%Confidence
50Evidence
2023-01-01First Seen
Version Compatibility
| Version | Status | Introduced | Deprecated | Notes |
|---|---|---|---|---|
| 20 | active | — | — | — |
Root Cause
OpenSSL 3.0 in Node.js 17+ removed support for legacy crypto algorithms (like MD4, old hash functions). Code or dependencies using these algorithms fail.
genericWorkarounds
-
92% success Update the dependency that uses the legacy algorithm to a newer version
Identify which package triggers the error from the stack trace, then npm update or npm install <package>@latest
Sources: https://nodejs.org/api/crypto.html
-
88% success Use --openssl-legacy-provider as a temporary bridge while upgrading dependencies
NODE_OPTIONS=--openssl-legacy-provider node app.js — use only as a short-term workaround
Sources: https://nodejs.org/api/cli.html#--openssl-legacy-provider
Dead Ends
Common approaches that don't work:
-
Setting NODE_OPTIONS=--openssl-legacy-provider permanently
60% fail
This is a temporary workaround that re-enables insecure algorithms; it will eventually stop working in future Node.js versions and masks security vulnerabilities
-
Downgrading to Node.js 16 LTS
70% fail
Node.js 16 is end-of-life and no longer receives security patches; this trades one problem for a worse one
Error Chain
Frequently confused with: