diff options
author | Rasmus Dahlberg <rasmus.dahlberg@kau.se> | 2020-11-05 12:24:01 +0100 |
---|---|---|
committer | Rasmus Dahlberg <rasmus.dahlberg@kau.se> | 2020-11-05 12:24:01 +0100 |
commit | cb8498119a0a3aaf34e09191e5e172173fdbc8ca (patch) | |
tree | ddf4cd77b348ba133586fd60fc0a749a2d472165 /reqres.go | |
parent | 8bb721bed66d09e27c9577d88d40cb1e48a8783d (diff) |
refactored signing/verification parts that are log specific
These methods are now private and attached to LogParameters.
Diffstat (limited to 'reqres.go')
-rw-r--r-- | reqres.go | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -66,13 +66,13 @@ func (lp *LogParameters) newAddEntryRequest(r *http.Request) ([]byte, []byte, er } // Check that there is a valid trust anchor - chain, err := buildChainFromDerList(lp, entry.Chain) + chain, err := lp.buildChainFromDerList(entry.Chain) if err != nil { return nil, nil, fmt.Errorf("invalid certificate chain: %v", err) } // Check that there is a valid signature - if err := verifySignature(lp, chain[0], tls.SignatureScheme(entry.SignatureScheme), entry.Item, entry.Signature); err != nil { + if err := lp.verifySignature(chain[0], tls.SignatureScheme(entry.SignatureScheme), entry.Item, entry.Signature); err != nil { return nil, nil, fmt.Errorf("invalid signature: %v", err) } |