Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit c32cf376 authored by David Drysdale's avatar David Drysdale Committed by Automerger Merge Worker
Browse files

Merge "KeyMint: check missing EC_CURVE on v3+" into main am: c91d0569 am:...

Merge "KeyMint: check missing EC_CURVE on v3+" into main am: c91d0569 am: 60a02ab9 am: 65ec5bbe

Original change: https://android-review.googlesource.com/c/platform/hardware/interfaces/+/2750972



Change-Id: Iba7125e3160143319553b5e3a9ac0e8893043472
Signed-off-by: default avatarAutomerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
parents 2d5f915b 65ec5bbe
Loading
Loading
Loading
Loading
+4 −4
Original line number Diff line number Diff line
@@ -2611,16 +2611,16 @@ TEST_P(NewKeyGenerationTest, EcdsaInvalidCurve) {
/*
 * NewKeyGenerationTest.EcdsaMissingCurve
 *
 * Verifies that EC key generation fails if EC_CURVE not specified after KeyMint V2.
 * Verifies that EC key generation fails if EC_CURVE not specified after KeyMint V3.
 */
TEST_P(NewKeyGenerationTest, EcdsaMissingCurve) {
    if (AidlVersion() < 2) {
    if (AidlVersion() < 3) {
        /*
         * The KeyMint V1 spec required that EC_CURVE be specified for EC keys.
         * However, this was not checked at the time so we can only be strict about checking this
         * for implementations of KeyMint version 2 and above.
         * for implementations of KeyMint version 3 and above.
         */
        GTEST_SKIP() << "Requiring EC_CURVE only strict since KeyMint v2";
        GTEST_SKIP() << "Requiring EC_CURVE only strict since KeyMint v3";
    }
    /* If EC_CURVE not provided, generateKey
     * must return ErrorCode::UNSUPPORTED_KEY_SIZE or ErrorCode::UNSUPPORTED_EC_CURVE.