~whereswaldon/forest-go

c7a4d89bc08753da0fc038d329bceed1d3285905 — Chris Waldon 5 months ago 4c1deda + e3a47dd
Merge branch 'protonpgp'
3 files changed, 6 insertions(+), 2 deletions(-)

M go.mod
M go.sum
M signature_validator.go
M go.mod => go.mod +3 -1
@@ 2,4 2,6 @@ module git.sr.ht/~whereswaldon/forest-go

require golang.org/x/crypto v0.0.0-20190513172903-22d7a77e9e5f

go 1.13
replace golang.org/x/crypto => github.com/ProtonMail/crypto v0.0.0-20191122234321-e77a1f03baa0

go 1.14

M go.sum => go.sum +2 -0
@@ 1,3 1,5 @@
github.com/ProtonMail/crypto v0.0.0-20191122234321-e77a1f03baa0 h1:mCww5Yl0Pm4PZPSooupyWDgihrh96p6+O4PY1hs0FBw=
github.com/ProtonMail/crypto v0.0.0-20191122234321-e77a1f03baa0/go.mod h1:MBriIAodHvZ+YvwvMJWCTmseW/LkeVRPWp/iZKvee4g=
golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w=
golang.org/x/crypto v0.0.0-20190513172903-22d7a77e9e5f h1:R423Cnkcp5JABoeemiGEPlt9tHXFfw5kvc0yqlxRPWo=
golang.org/x/crypto v0.0.0-20190513172903-22d7a77e9e5f/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI=

M signature_validator.go => signature_validator.go +1 -1
@@ 45,7 45,7 @@ func ValidateSignature(v SignatureValidator, identity *Identity) (bool, error) {

	signatureBuf := bytes.NewBuffer([]byte(v.GetSignature().Blob))
	keyring := openpgp.EntityList([]*openpgp.Entity{pubkeyEntity})
	_, err = openpgp.CheckDetachedSignature(keyring, signedContentBuf, signatureBuf)
	_, err = openpgp.CheckDetachedSignature(keyring, signedContentBuf, signatureBuf, nil)
	if err != nil {
		return false, err
	}