From 788b0f7f2de48aa802c4ae50066ee1a620843279 Mon Sep 17 00:00:00 2001 From: Daniel Gultsch Date: Sat, 7 Mar 2020 18:33:22 +0100 Subject: [PATCH] momentarily go back to 16 byte IVs The Crypto provider used from Android P onwards (conscrypt) has a weird bug that when 12 bytes IVs are used it will decrypt or encrypt the entire file in RAM instead of streaming it. That will cause OOM for 'larger' files on http upload. (both downloads and uploads are effected) It is currently unclear why this is happening and why Conscrypt is put into a different mode. We are only observing that Android versions below P are fine and using 16 bytes is fine on all Android versions. --- src/main/java/eu/siacs/conversations/Config.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main/java/eu/siacs/conversations/Config.java b/src/main/java/eu/siacs/conversations/Config.java index 294e62539..e131a4a32 100644 --- a/src/main/java/eu/siacs/conversations/Config.java +++ b/src/main/java/eu/siacs/conversations/Config.java @@ -100,7 +100,7 @@ public final class Config { public static final boolean REMOVE_BROKEN_DEVICES = false; public static final boolean OMEMO_PADDING = false; public static final boolean PUT_AUTH_TAG_INTO_KEY = true; - public static final boolean TWELVE_BYTE_IV = true; + public static final boolean TWELVE_BYTE_IV = false; public static final boolean USE_BOOKMARKS2 = false;