From aff99a812455345f2264b2989df90e7ec7032c02 Mon Sep 17 00:00:00 2001 From: Matthew R Date: Fri, 2 Jul 2021 23:47:09 -0400 Subject: [PATCH] changes to armor encoding --- routes/pgp.go | 4 ---- 1 file changed, 4 deletions(-) diff --git a/routes/pgp.go b/routes/pgp.go index 172920b..ba8e9bf 100644 --- a/routes/pgp.go +++ b/routes/pgp.go @@ -4,7 +4,6 @@ import ( "encoding/hex" "net/http" "time" - "io/ioutil" "golang.org/x/crypto/openpgp" "golang.org/x/crypto/openpgp/armor" @@ -23,8 +22,6 @@ type PGPKey struct { func GetOpenPGPInformationEncoded(c *gin.Context) { query := c.Copy().Request.Body - query2 := c.Copy().Request.Body - body, _ := ioutil.ReadAll(query2) block, err := armor.Decode(query) if err != nil { @@ -74,6 +71,5 @@ func GetOpenPGPInformationEncoded(c *gin.Context) { "publicKeyAlgorithm": key.PublicKeyAlgorithm, "fingerprint": hex.EncodeToString(key.Fingerprint[:]), "keyID": key.KeyID, - "armor": body, }) }