mirror of
https://github.com/AikidoSec/safe-chain.git
synced 2026-05-26 12:10:49 +00:00
Forge: usePureJavaScript
This commit is contained in:
parent
0fffcf2cc1
commit
bb3e50008a
1 changed files with 5 additions and 0 deletions
|
|
@ -3,6 +3,11 @@ import path from "path";
|
||||||
import fs from "fs";
|
import fs from "fs";
|
||||||
import os from "os";
|
import os from "os";
|
||||||
|
|
||||||
|
// Force node-forge to use pure JavaScript instead of native crypto
|
||||||
|
// This prevents segmentation faults in pkg binaries on Linux
|
||||||
|
// @ts-ignore - options exists but isn't in the type definitions
|
||||||
|
forge.options.usePureJavaScript = true;
|
||||||
|
|
||||||
const certFolder = path.join(os.homedir(), ".safe-chain", "certs");
|
const certFolder = path.join(os.homedir(), ".safe-chain", "certs");
|
||||||
const ca = loadCa();
|
const ca = loadCa();
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue