Skip to content

Commit

Permalink
override underlying md4 encryption with sha256 (fix node version issues)
Browse files Browse the repository at this point in the history
  • Loading branch information
harsh183 committed Jun 4, 2024
1 parent 3482469 commit bf4a4b7
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions config/webpack.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -77,6 +77,11 @@ const hasJsxRuntime = (() => {
}
})();

// https://stackoverflow.com/a/78005686
const crypto = require("crypto");
const crypto_orig_createHash = crypto.createHash;
crypto.createHash = algorithm => crypto_orig_createHash(algorithm == "md4" ? "sha256" : algorithm);

// This is the production and development configuration.
// It is focused on developer experience, fast rebuilds, and a minimal bundle.
module.exports = function (webpackEnv) {
Expand Down

0 comments on commit bf4a4b7

Please sign in to comment.