Skip to content

Commit

Permalink
fix: panic when checking signatures
Browse files Browse the repository at this point in the history
Signed-off-by: Timofey Kirillov <timofey.kirillov@flant.com>
  • Loading branch information
distorhead committed Apr 21, 2022
1 parent 5ea59a3 commit 8956c78
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions server/pkg/pgp/util.go
Original file line number Diff line number Diff line change
Expand Up @@ -29,10 +29,10 @@ func VerifyPGPSignatures(pgpSignatures []string, signedReaderFunc func() (io.Rea
}

if _, err = openpgp.CheckArmoredDetachedSignature(keyring, signedReader, strings.NewReader(pgpSignature)); err != nil {
i++
if logger != nil {
logger.Debug(fmt.Sprintf("[DEBUG-SIGNATURES] VerifyPGPSignatures -- will skip pgpKey >%v<", pgpKeys[i]))
logger.Debug(fmt.Sprintf("[DEBUG-SIGNATURES] VerifyPGPSignatures -- will skip pgpKey due to error: %s\n>%v<", err, pgpKeys[i]))
}
i++
continue
}

Expand Down

0 comments on commit 8956c78

Please sign in to comment.