mirror of
https://github.com/parabirb/freeremote-server.git
synced 2026-07-30 13:54:25 -04:00
17 lines
414 B
JavaScript
17 lines
414 B
JavaScript
import { generateKey } from "openpgp";
|
|
import config from "./config.json" with { type: "json" };
|
|
|
|
const { publicKey, privateKey } = await generateKey({
|
|
curve: "ed25519",
|
|
userIDs: [
|
|
{
|
|
name: config.clubName,
|
|
email: config.clubEmail
|
|
}
|
|
],
|
|
format: "armored"
|
|
});
|
|
|
|
console.log(`Public key: ${JSON.stringify(publicKey)}
|
|
|
|
Private key: ${JSON.stringify(privateKey)}`); |