WIP: Add compression to API (#91)
* Add compression to API * Add docs * Use defaults for a simpler interface * Update x/crypto * Fix ecdsa key types for lib update
This commit is contained in:
parent
9503b68f0c
commit
371d429001
13 changed files with 177 additions and 31 deletions
|
|
@ -328,10 +328,10 @@ func (key *Key) Check() (bool, error) {
|
|||
func (key *Key) PrintFingerprints() {
|
||||
for _, subKey := range key.entity.Subkeys {
|
||||
if !subKey.Sig.FlagsValid || subKey.Sig.FlagEncryptStorage || subKey.Sig.FlagEncryptCommunications {
|
||||
fmt.Println("SubKey:" + hex.EncodeToString(subKey.PublicKey.Fingerprint[:]))
|
||||
fmt.Println("SubKey:" + hex.EncodeToString(subKey.PublicKey.Fingerprint))
|
||||
}
|
||||
}
|
||||
fmt.Println("PrimaryKey:" + hex.EncodeToString(key.entity.PrimaryKey.Fingerprint[:]))
|
||||
fmt.Println("PrimaryKey:" + hex.EncodeToString(key.entity.PrimaryKey.Fingerprint))
|
||||
}
|
||||
|
||||
// GetHexKeyID returns the key ID, hex encoded as a string.
|
||||
|
|
@ -346,7 +346,7 @@ func (key *Key) GetKeyID() uint64 {
|
|||
|
||||
// GetFingerprint gets the fingerprint from the key.
|
||||
func (key *Key) GetFingerprint() string {
|
||||
return hex.EncodeToString(key.entity.PrimaryKey.Fingerprint[:])
|
||||
return hex.EncodeToString(key.entity.PrimaryKey.Fingerprint)
|
||||
}
|
||||
|
||||
// GetSHA256Fingerprints computes the SHA256 fingerprints of the key and subkeys.
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue