datapartyjs / gpg-promised

The GPG interface for nodejs we were promised
http://dataparty.xyz
Apache License 2.0
1 stars 1 forks source link

FEAT | Support key generation #3

Closed sevenbitbyte closed 4 years ago

sevenbitbyte commented 4 years ago

🚀 Feature Proposal

const GpgPromised = require('gpg-promised')
const KeyChain = GpgPromised.KeyChain

const keychain = new KeyChain()

await keychain.open()

await keychain.generate('user@host.com', 'passphrase')

await keychain.generate(email, passphrase, keyType='rsa', keySize=4096)

await keychain.refreshKeys(server)

await keychain.sendKeys(keyId, server)

await keychain.signKey(to, from, local)