summaryrefslogtreecommitdiffstats
path: root/verifier.cpp
diff options
context:
space:
mode:
authorxunchang <xunchang@google.com>2019-03-26 17:54:34 +0100
committerxunchang <xunchang@google.com>2019-03-26 20:28:23 +0100
commit908ad77af8731c0e8a7645575ea71fbbdd404d41 (patch)
treee348ee403e9305962978ec7e326245a8e3b1d8da /verifier.cpp
parentMerge "Move librecovery_ui to a sub-directory" (diff)
downloadandroid_bootable_recovery-908ad77af8731c0e8a7645575ea71fbbdd404d41.tar
android_bootable_recovery-908ad77af8731c0e8a7645575ea71fbbdd404d41.tar.gz
android_bootable_recovery-908ad77af8731c0e8a7645575ea71fbbdd404d41.tar.bz2
android_bootable_recovery-908ad77af8731c0e8a7645575ea71fbbdd404d41.tar.lz
android_bootable_recovery-908ad77af8731c0e8a7645575ea71fbbdd404d41.tar.xz
android_bootable_recovery-908ad77af8731c0e8a7645575ea71fbbdd404d41.tar.zst
android_bootable_recovery-908ad77af8731c0e8a7645575ea71fbbdd404d41.zip
Diffstat (limited to 'verifier.cpp')
-rw-r--r--verifier.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/verifier.cpp b/verifier.cpp
index 68a011e0d..08d852b37 100644
--- a/verifier.cpp
+++ b/verifier.cpp
@@ -373,8 +373,8 @@ bool CheckRSAKey(const std::unique_ptr<RSA, RSADeleter>& rsa) {
const BIGNUM* out_e;
RSA_get0_key(rsa.get(), &out_n, &out_e, nullptr /* private exponent */);
auto modulus_bits = BN_num_bits(out_n);
- if (modulus_bits != 2048) {
- LOG(ERROR) << "Modulus should be 2048 bits long, actual: " << modulus_bits;
+ if (modulus_bits != 2048 && modulus_bits != 4096) {
+ LOG(ERROR) << "Modulus should be 2048 or 4096 bits long, actual: " << modulus_bits;
return false;
}