feat: Address unresolved comments from #705 (#708)

closes https://github.com/slsa-framework/slsa-verifier/issues/707

Signed-off-by: laurentsimon <laurentsimon@google.com>
This commit is contained in:
laurentsimon
2023-10-09 23:17:48 +00:00
committed by GitHub
parent 8602109f3f
commit 3b171c4140
+1 -1
View File
@@ -163,7 +163,7 @@ const (
func DsseVerifierNew(content []byte, format KeyFormat, keyID string, sigEncoding *SignatureEncoding) (*dsselib.EnvelopeVerifier, error) {
if format == KeyFormatPEM {
block, rest := pem.Decode(content)
if rest != nil {
if len(rest) != 0 {
return nil, fmt.Errorf("%w: additional data found", serrors.ErrorInvalidPEM)
}
if block == nil {