MCPcopy Index your code
hub / github.com/nodejs/node / setFips

Function setFips

lib/crypto.js:257–267  ·  view source on GitHub ↗
(val)

Source from the content-addressed store, hash-verified

255}
256
257function setFips(val) {
258 if (getOptionValue('--force-fips')) {
259 if (val) return;
260 throw new ERR_CRYPTO_FIPS_FORCED();
261 } else {
262 if (!lazyOwnsProcessState()) {
263 throw new ERR_WORKER_UNSUPPORTED_OPERATION('Calling crypto.setFips()');
264 }
265 setFipsCrypto(val);
266 }
267}
268
269function getRandomValues(array) {
270 return lazyWebCrypto().crypto.getRandomValues(array);

Callers

nothing calls this directly

Calls 2

getOptionValueFunction · 0.85
lazyOwnsProcessStateFunction · 0.85

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…