Documentation ¶
Overview ¶
This Source Code Form is subject to the terms of the Mozilla Public License, v. 2.0. If a copy of the MPL was not distributed with this file, You can obtain one at http://mozilla.org/MPL/2.0/.
Contributor: Julien Vehent jvehent@mozilla.com [:ulfr]
This Source Code Form is subject to the terms of the Mozilla Public License, v. 2.0. If a copy of the MPL was not distributed with this file, You can obtain one at http://mozilla.org/MPL/2.0/.
Contributor: Julien Vehent jvehent@mozilla.com [:ulfr]
This Source Code Form is subject to the terms of the Mozilla Public License, v. 2.0. If a copy of the MPL was not distributed with this file, You can obtain one at http://mozilla.org/MPL/2.0/.
Contributor: Julien Vehent jvehent@mozilla.com [:ulfr]
This Source Code Form is subject to the terms of the Mozilla Public License, v. 2.0. If a copy of the MPL was not distributed with this file, You can obtain one at http://mozilla.org/MPL/2.0/.
Contributor: Julien Vehent jvehent@mozilla.com [:ulfr]
Index ¶
- func ArmorPubKey(pubkey []byte) (armoredPubKey []byte, err error)
- func ArmoredKeysToKeyring(keys [][]byte) (keyring io.ReadSeeker, keycount int, err error)
- func GenerateKeyPair(name, desc, email string) (pubkey, privkey []byte, fp string, err error)
- func GetArmoredKeyFromKeyServer(keyid, keyserver string) (key []byte, err error)
- func GetFingerprintFromSignature(data string, signature string, keyring io.Reader) (fingerprint string, err error)
- func KeyringToArmoredPubKeys(keyring io.ReadCloser) (armoredkeys map[string][]byte, err error)
- func LoadArmoredPubKey(pubkey []byte) (pgpfingerprint string, err error)
- func Sign(data, keyid string, secringFile io.Reader) (sig string, err error)
- func Verify(data string, signature string, keyring io.Reader) (valid bool, entity *openpgp.Entity, err error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ArmorPubKey ¶
func ArmoredKeysToKeyring ¶
func ArmoredKeysToKeyring(keys [][]byte) (keyring io.ReadSeeker, keycount int, err error)
ArmoredKeysToKeyring takes a list of PGP keys in armored form and transforms it into a keyring that can be used in other openpgp's functions
func GenerateKeyPair ¶
func KeyringToArmoredPubKeys ¶
func KeyringToArmoredPubKeys(keyring io.ReadCloser) (armoredkeys map[string][]byte, err error)
KeyringToArmoredPubKeys reads all public keys from a keyring and returned their armored format into map of keys indexed by key fingerprint
func LoadArmoredPubKey ¶
LoadArmoredPubKey takes a single public key as a byte slice, validates it, and returns its its fingerprint or an error
Types ¶
This section is empty.
Directories ¶
Path | Synopsis |
---|---|
Package gpgagent interacts with the local GPG Agent.
|
Package gpgagent interacts with the local GPG Agent. |
Package pinentry interfaces with the pinentry(1) command to securely prompt the user for a password using whichever user interface the user is currently using.
|
Package pinentry interfaces with the pinentry(1) command to securely prompt the user for a password using whichever user interface the user is currently using. |