From 076750c0a84498766d39fa3caf241dc380d21017 Mon Sep 17 00:00:00 2001 From: Christian Schneppe Date: Sat, 20 Oct 2018 21:44:42 +0200 Subject: use bouncycastle provider up to api 27 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit apparently using conscrypt on Android below version 7? throws an exception when using 16 byte IVs. so we now use BC when ever possible (excluding api 28) we don’t know why Conscrypt behaves differently on various android versions --- src/main/java/de/pixart/messenger/utils/Compatibility.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/main/java/de/pixart/messenger/utils') diff --git a/src/main/java/de/pixart/messenger/utils/Compatibility.java b/src/main/java/de/pixart/messenger/utils/Compatibility.java index 6d5f35bc4..f178f17c7 100644 --- a/src/main/java/de/pixart/messenger/utils/Compatibility.java +++ b/src/main/java/de/pixart/messenger/utils/Compatibility.java @@ -37,8 +37,8 @@ public class Compatibility { return Build.VERSION.SDK_INT >= Build.VERSION_CODES.O; } - public static boolean twentyTwo() { - return Build.VERSION.SDK_INT >= Build.VERSION_CODES.LOLLIPOP_MR1; + public static boolean twentyEight() { + return Build.VERSION.SDK_INT >= Build.VERSION_CODES.P; } private static boolean getBooleanPreference(Context context, String name, @BoolRes int res) { -- cgit v1.2.3