[PATCH 7/8] rsa: Turn error messages into debug messages
Sascha Hauer
s.hauer at pengutronix.de
Wed May 4 06:14:15 PDT 2022
Signed-off-by: Sascha Hauer <s.hauer at pengutronix.de>
---
crypto/rsa.c | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/crypto/rsa.c b/crypto/rsa.c
index 6d23ecb11c..e97e5192ab 100644
--- a/crypto/rsa.c
+++ b/crypto/rsa.c
@@ -342,27 +342,27 @@ int rsa_verify(const struct rsa_public_key *key, const uint8_t *sig,
PS_end = T_offset - 1;
if (buf[PS_end] != 0x00) {
- pr_err(" = -EBADMSG [EM[T-1] == %02u]\n", buf[PS_end]);
+ pr_debug(" = -EBADMSG [EM[T-1] == %02u]\n", buf[PS_end]);
ret = -EBADMSG;
goto out_free_digest;
}
for (i = 2; i < PS_end; i++) {
if (buf[i] != 0xff) {
- pr_err(" = -EBADMSG [EM[PS%x] == %02u]\n", i - 2, buf[i]);
+ pr_debug(" = -EBADMSG [EM[PS%x] == %02u]\n", i - 2, buf[i]);
ret = -EBADMSG;
goto out_free_digest;
}
}
if (memcmp(asn1_template, buf + T_offset, asn1_size) != 0) {
- pr_err(" = -EBADMSG [EM[T] ASN.1 mismatch]\n");
+ pr_debug(" = -EBADMSG [EM[T] ASN.1 mismatch]\n");
ret = -EBADMSG;
goto out_free_digest;
}
if (memcmp(hash, buf + T_offset + asn1_size, digest_length(d)) != 0) {
- pr_err(" = -EKEYREJECTED [EM[T] hash mismatch]\n");
+ pr_debug(" = -EKEYREJECTED [EM[T] hash mismatch]\n");
ret = -EKEYREJECTED;
goto out_free_digest;
}
--
2.30.2
More information about the barebox
mailing list