aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRajesh Nyamagoud <nyamagoud@google.com>2022-11-15 18:21:56 +0000
committerAutomerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>2022-11-15 18:21:56 +0000
commit42dbf01f16769b9ef93a471479308dbf36de0b91 (patch)
tree1ab7930a01cf9e675b69a15683f09d4bfc4df2ef
parentaea0b59f3000733faa5ec573859c494d79764e0c (diff)
parent1a8badc2378487d162277f49cce1c8c9978612ef (diff)
downloadwycheproof-42dbf01f16769b9ef93a471479308dbf36de0b91.tar.gz
Revert "Keystore:Assuming KeyMint version 1 and above" am: eed98b9ccb am: f1188015d3 am: 1a8badc237
Original change: https://android-review.googlesource.com/c/platform/external/wycheproof/+/2285293 Change-Id: I59a4c326ea122b91a8a7e4e5868e661fce389455 Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
-rw-r--r--keystore-cts/java/android/keystore/cts/util/KeyStoreUtil.java5
-rw-r--r--keystore-cts/java/com/google/security/wycheproof/testcases/JsonEcdhTest.java12
2 files changed, 0 insertions, 17 deletions
diff --git a/keystore-cts/java/android/keystore/cts/util/KeyStoreUtil.java b/keystore-cts/java/android/keystore/cts/util/KeyStoreUtil.java
index ed50585..9f430c1 100644
--- a/keystore-cts/java/android/keystore/cts/util/KeyStoreUtil.java
+++ b/keystore-cts/java/android/keystore/cts/util/KeyStoreUtil.java
@@ -15,7 +15,6 @@ package android.keystore.cts.util;
import android.content.Context;
import android.security.keystore.KeyProtection;
-import android.keystore.cts.util.TestUtils;
import androidx.test.core.app.ApplicationProvider;
import org.bouncycastle.asn1.x500.X500Name;
import org.bouncycastle.asn1.x509.SubjectPublicKeyInfo;
@@ -87,10 +86,6 @@ public class KeyStoreUtil {
}
}
- public static int getFeatureVersionKeystore() {
- return TestUtils.getFeatureVersionKeystore(ApplicationProvider.getApplicationContext());
- }
-
public static boolean hasStrongBox() {
Context context = ApplicationProvider.getApplicationContext();
return TestUtils.hasStrongBox(context);
diff --git a/keystore-cts/java/com/google/security/wycheproof/testcases/JsonEcdhTest.java b/keystore-cts/java/com/google/security/wycheproof/testcases/JsonEcdhTest.java
index 42f3cf8..779dc42 100644
--- a/keystore-cts/java/com/google/security/wycheproof/testcases/JsonEcdhTest.java
+++ b/keystore-cts/java/com/google/security/wycheproof/testcases/JsonEcdhTest.java
@@ -14,7 +14,6 @@
package com.google.security.wycheproof;
import static org.junit.Assert.assertEquals;
-import static org.junit.Assume.assumeTrue;
import com.google.gson.JsonElement;
import com.google.gson.JsonObject;
@@ -30,7 +29,6 @@ import java.security.spec.InvalidKeySpecException;
import java.security.spec.X509EncodedKeySpec;
import javax.crypto.KeyAgreement;
import org.junit.After;
-import org.junit.Before;
import org.junit.Test;
import org.junit.Ignore;
import android.security.keystore.KeyProtection;
@@ -49,16 +47,6 @@ public class JsonEcdhTest {
KeyStoreUtil.cleanUpKeyStore();
}
- @Before
- public void setup() {
- // In this test class ECDH keys are imported for key agreement (PURPOSE_AGREE_KEY).
- // KeyMaster could support this key import through software emulation,
- // but currently it is missing (b/216434270). Hence, this assumption is added till ECDH
- // key import software emulation is not implemented.
- assumeTrue("PURPOSE_AGREE_KEY is supported in KeyMint version 1 and above.",
- KeyStoreUtil.getFeatureVersionKeystore() >= KeyStoreUtil.KM_VERSION_KEYMINT_1);
- }
-
/** Convenience mehtod to get a String from a JsonObject */
protected static String getString(JsonObject object, String name) throws Exception {
return object.get(name).getAsString();