brew install gnupg
gpg --gen-key
var forge = require("node-forge"); | |
var pki = forge.pki; | |
var asn1 = forge.asn1; | |
// generate a keypair and create an X.509v3 certificate | |
var keys = pki.rsa.generateKeyPair(2048); | |
var cert = pki.createCertificate(); |