![]() ![]() ![]() alice.is_pgp_locked(): returns true if alice's private key is passphrase-protected and locked. ![]() alice.has_pgp_private(): returns true if alice's key_manager contains a private key.If you're importing a private key, you'll want to check if it has a passphrase and unlock it. KeyManager.import_from_armored_pgp(opts, cb): calls back with err, key_manager.KeyManager.generate(opts, cb) KeyManager.generate_rsa(opts, cb) KeyManager.generate_ecc(opts, cb): calls back with err, key_manager ( see examples).In any kbpgp function, you may set opts.asp as an ASP object to monitor progress and optionally cancel it.For a sign-and-encrypt action, you'll need two KeyManagers: one containing the private key (for the signer), and one containing the public key (for the recipient).įor example, assuming we have two KeyManager instances, alice and chuck, we might perform an encryption. Once you have a KeyManager instance, you can perform actions with the keys inside. Getting itīefore you can perform any crypto, you need a KeyManager.Ī KeyManager contains a public key and possibly the secret key and subkeys for a given person. It's actively maintained and yours forever under a BSD license. It's easy to use, designed for concurrency, and stable in both Node.js and the browser. Kbpgp is Keybase's implementation of PGP in JavaScript. ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |