Skip to content

Commit 593e889

Browse files
committed
fix: set fips mode on start
1 parent 3e0a7f1 commit 593e889

1 file changed

Lines changed: 10 additions & 0 deletions

File tree

ee/apps/ddp-streamer/src/fips.ts

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,16 @@
1616
*/
1717
import crypto from 'crypto';
1818

19+
crypto.setFips(true);
20+
21+
if (crypto.getFips() !== 1) {
22+
throw new Error('FIPS mode was not enabled after crypto.setFips(true)');
23+
}
24+
25+
console.log('=========================================');
26+
console.log('FIPS COMPLIANCE CHECK: YES');
27+
console.log('=========================================');
28+
1929
try {
2030
crypto.createHash('sha1').update('test').digest('hex');
2131
console.log('🔓 Native SHA-1 allowed. Skipping FIPS WebSocket patch.');

0 commit comments

Comments
 (0)