summaryrefslogtreecommitdiff
path: root/src/adb.h
diff options
context:
space:
mode:
authorTimo Teräs <timo.teras@iki.fi>2021-06-19 14:42:11 +0300
committerTimo Teräs <timo.teras@iki.fi>2021-06-19 14:43:22 +0300
commit17684141fe9d895361262b10c4c229fbcff6e702 (patch)
tree4a9d93a2c89cf176c849e7ce61e34a40770abeee /src/adb.h
parent8d92f9f2aecaf74973c26302ce7ad8f2a32e257f (diff)
downloadapk-tools-17684141fe9d895361262b10c4c229fbcff6e702.tar.gz
apk-tools-17684141fe9d895361262b10c4c229fbcff6e702.tar.bz2
apk-tools-17684141fe9d895361262b10c4c229fbcff6e702.tar.xz
apk-tools-17684141fe9d895361262b10c4c229fbcff6e702.zip
crypto: improve compatibility
EVP_MD_CTX_set_pkey_ctx() is fairly new openssl function, and not existing in many alternative. Use EVP_MD_CTX_reset() which is slightly more heavy but more portable. Add also signature buffer lengths to work with RSA.
Diffstat (limited to 'src/adb.h')
-rw-r--r--src/adb.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/adb.h b/src/adb.h
index 1944522..2319f92 100644
--- a/src/adb.h
+++ b/src/adb.h
@@ -74,7 +74,7 @@ static inline apk_blob_t adb_block_blob(struct adb_block *b) {
return APK_BLOB_PTR_LEN(adb_block_payload(b), adb_block_length(b));
}
-#define ADB_MAX_SIGNATURE_LEN 256
+#define ADB_MAX_SIGNATURE_LEN 2048
struct adb_sign_hdr {
uint8_t sign_ver, hash_alg;