diff options
author | Android Build Coastguard Worker <android-build-coastguard-worker@google.com> | 2024-05-10 15:44:30 +0000 |
---|---|---|
committer | Android Build Coastguard Worker <android-build-coastguard-worker@google.com> | 2024-05-10 15:44:30 +0000 |
commit | 42eb59378db457ddaf0101831ec1aa8ac6edec6f (patch) | |
tree | 091176020462fc87022a319f8d06bcc49d59f4f9 | |
parent | 00e62848dfda904d52176cd8063754212fa1c715 (diff) | |
parent | 15404343c857b22a0cf8df8014c9aa3dd2b68057 (diff) | |
download | vboot_reference-busytown-mac-infra-release.tar.gz |
Snap for 11819167 from 15404343c857b22a0cf8df8014c9aa3dd2b68057 to busytown-mac-infra-releasebusytown-mac-infra-release
Change-Id: Ie2aef0a644ca3b57fe2a43e4e6ba8db9b63dc021
-rw-r--r-- | futility/futility.h | 2 | ||||
-rw-r--r-- | host/lib/util_misc.c | 6 |
2 files changed, 4 insertions, 4 deletions
diff --git a/futility/futility.h b/futility/futility.h index 550e381e..f3abacc7 100644 --- a/futility/futility.h +++ b/futility/futility.h @@ -40,7 +40,7 @@ enum vboot_version { }; /* What's our preferred API & data format? */ -enum vboot_version vboot_version; +extern enum vboot_version vboot_version; /* Here's a structure to define the commands that futility implements. */ struct futil_cmd_t { diff --git a/host/lib/util_misc.c b/host/lib/util_misc.c index e75251e6..ac0b3ea5 100644 --- a/host/lib/util_misc.c +++ b/host/lib/util_misc.c @@ -29,7 +29,7 @@ void PrintPubKeySha1Sum(VbPublicKey *key) free(digest); } -int vb_keyb_from_rsa(struct rsa_st *rsa_private_key, +int vb_keyb_from_rsa(RSA *rsa_private_key, uint8_t **keyb_data, uint32_t *keyb_size) { uint32_t i, nwords; @@ -46,7 +46,7 @@ int vb_keyb_from_rsa(struct rsa_st *rsa_private_key, int retval = 1; /* Size of RSA key in 32-bit words */ - nwords = BN_num_bits(rsa_private_key->n) / 32; + nwords = RSA_bits(rsa_private_key) / 32; bufsize = (2 + nwords + nwords) * sizeof(uint32_t); outbuf = malloc(bufsize); @@ -75,7 +75,7 @@ int vb_keyb_from_rsa(struct rsa_st *rsa_private_key, NEW_BIGNUM(B); #undef NEW_BIGNUM - BN_copy(N, rsa_private_key->n); + BN_copy(N, RSA_get0_n(rsa_private_key)); BN_set_word(Big1, 1L); BN_set_word(Big2, 2L); BN_set_word(Big32, 32L); |