Merge pull request #21908 from szubster/fips-md5-sha256
Switch md5 to sha256
This commit is contained in:
@@ -219,7 +219,7 @@ async function getProjectConfig(targetPath, extraConfig) {
|
||||
// If no explicit id was configured, generated one based on the configuration.
|
||||
if (!config.id) {
|
||||
const configHash = crypto
|
||||
.createHash('md5')
|
||||
.createHash('sha256')
|
||||
.update(version)
|
||||
.update(Buffer.alloc(1))
|
||||
.update(JSON.stringify(config.transform))
|
||||
|
||||
@@ -70,7 +70,7 @@ function createTransformer(config) {
|
||||
};
|
||||
|
||||
const getCacheKey = sourceText => {
|
||||
return createHash('md5')
|
||||
return createHash('sha256')
|
||||
.update(sourceText)
|
||||
.update(Buffer.alloc(1))
|
||||
.update(sucrasePkg.version)
|
||||
|
||||
@@ -25,7 +25,7 @@ function createTransformer(config) {
|
||||
|
||||
const getCacheKey = sourceText => {
|
||||
return crypto
|
||||
.createHash('md5')
|
||||
.createHash('sha256')
|
||||
.update(sourceText)
|
||||
.update(Buffer.alloc(1))
|
||||
.update(JSON.stringify(config))
|
||||
|
||||
Reference in New Issue
Block a user