Externalize node-forge

This commit is contained in:
Sander Declerck 2025-11-28 15:03:36 +01:00
parent bb3e50008a
commit 1d00084202
No known key found for this signature in database
2 changed files with 9 additions and 11 deletions

View file

@ -3,11 +3,6 @@ import path from "path";
import fs from "fs";
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 ca = loadCa();