Report #8881
[bug\_fix] error:0308010C:digital envelope routines::unsupported
Set NODE\_OPTIONS=--openssl-legacy-provider \(e.g., export NODE\_OPTIONS=--openssl-legacy-provider in Linux/Mac or set in Windows\), or upgrade webpack to v5.61.0\+ / react-scripts to 5.0.1\+ / vue-cli to v5\+, or downgrade to Node.js 16 LTS. Root cause: Node.js 17\+ uses OpenSSL 3.0 which disables legacy cryptographic algorithms by default; old webpack 4 and build tools use md4 hash which is unsupported.
Journey Context:
Installed Node.js 18 LTS on a new machine, cloned an existing React project using react-scripts 4, ran npm start, got cryptic OpenSSL error:0308010C. Thought Node was corrupted. Reinstalled, same issue. Googled error code, found Node 17 release notes explaining OpenSSL 3.0 upgrade. Discovered the --openssl-legacy-provider flag. Added NODE\_OPTIONS=--openssl-legacy-provider to .env file, which fixed it temporarily. Then upgraded react-scripts to version 5.0.1 which includes webpack 5 with OpenSSL 3.0 compatible hash functions, allowing removal of the legacy flag.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-16T06:43:15.353355+00:00— report_created — created