summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorTom Rini <trini@konsulko.com>2020-05-07 09:02:28 -0400
committerTom Rini <trini@konsulko.com>2020-05-07 09:02:28 -0400
commit69bf66ad8c0d53cc5e64d0f4f2e3bc9ad18e61aa (patch)
treeb89bafeea8ed15b1403edf892964adaa5003255d /lib
parent1259567ae3cd4c84acb9db6ab1fadcdcd26968a9 (diff)
parent5168d7a6264be30f82c1c074e43c24fcacbb4283 (diff)
Merge branch '2020-05-06-master-imports'
- ARM Juno updates - Assorted bugfixes
Diffstat (limited to 'lib')
-rw-r--r--lib/rsa/rsa-mod-exp.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/rsa/rsa-mod-exp.c b/lib/rsa/rsa-mod-exp.c
index 420ab2eba0..62b2557cc2 100644
--- a/lib/rsa/rsa-mod-exp.c
+++ b/lib/rsa/rsa-mod-exp.c
@@ -262,8 +262,8 @@ int rsa_mod_exp_sw(const uint8_t *sig, uint32_t sig_len,
if (!prop->public_exponent)
key.exponent = RSA_DEFAULT_PUBEXP;
else
- key.exponent =
- fdt64_to_cpu(*((uint64_t *)(prop->public_exponent)));
+ rsa_convert_big_endian((uint32_t *)&key.exponent,
+ prop->public_exponent, 2);
if (!key.len || !prop->modulus || !prop->rr) {
debug("%s: Missing RSA key info", __func__);