projects
/
platform
/
kernel
/
u-boot.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
774904c
)
lib: rsa: Also check for presence of r-squared property
author
Jan Kiszka
<jan.kiszka@siemens.com>
Thu, 7 May 2020 18:36:13 +0000
(20:36 +0200)
committer
Tom Rini
<trini@konsulko.com>
Fri, 15 May 2020 18:47:35 +0000
(14:47 -0400)
Better than crashing later if it is missing.
Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
lib/rsa/rsa-verify.c
patch
|
blob
|
history
diff --git
a/lib/rsa/rsa-verify.c
b/lib/rsa/rsa-verify.c
index
80e8173
..
f7ae174
100644
(file)
--- a/
lib/rsa/rsa-verify.c
+++ b/
lib/rsa/rsa-verify.c
@@
-445,7
+445,7
@@
static int rsa_verify_with_keynode(struct image_sign_info *info,
prop.rr = fdt_getprop(blob, node, "rsa,r-squared", NULL);
- if (!prop.num_bits || !prop.modulus) {
+ if (!prop.num_bits || !prop.modulus
|| !prop.rr
) {
debug("%s: Missing RSA key info", __func__);
return -EFAULT;
}