Commit graph

71 commits

Author SHA1 Message Date
Shawn Willden
709e2e1ed9 Test import of a EC P-521 key.
This failure is also diagnosed by CTS, but it should be validated in VTS
as well.

Merged-In: Ia7654ff8813942fbca9dfa838337e9de5839a9e2
Bug: 33945114
Test: adb shell data/nativetests64/VtsHalKeymasterV3_0TargetTest/VtsHalKeymasterV3_0TargetTest
Change-Id: Ia7654ff8813942fbca9dfa838337e9de5839a9e2
2017-06-22 15:14:30 -06:00
Shawn Willden
2bd3e23f3c Test import of a EC P-521 key.
This failure is also diagnosed by CTS, but it should be validated in VTS
as well.

Bug: 33945114
Test: adb shell data/nativetests64/VtsHalKeymasterV3_0TargetTest/VtsHalKeymasterV3_0TargetTest
Change-Id: Ia7654ff8813942fbca9dfa838337e9de5839a9e2
2017-06-22 14:29:19 -06:00
Shawn Willden
da4568eb18 Merge "Check return from DeleteKey correctly." into oc-dev
am: c4f859d1b5

Change-Id: Ib41e416ab79a56cddbaa61084645f626b4a3b22b
2017-06-21 00:54:07 +00:00
TreeHugger Robot
c4f859d1b5 Merge "Check return from DeleteKey correctly." into oc-dev 2017-06-21 00:45:17 +00:00
Janis Danisevskis
eb5a6056bc Merge "Purge unsupported RSA key sizes from VTS tests" into oc-dev
am: bc970b089f

Change-Id: Id5c16a9a8a2ff95e18254da4b8568d68e15e5834
2017-06-14 02:32:40 +00:00
Janis Danisevskis
39daaa0f96 Purge unsupported RSA key sizes from VTS tests
Support for 256 bit RSA keys are not mandated by keymaster specs and
must not be used in the VTS tests.

Bug: 62581389
Change-Id: If315088db2752ac2efe31fdb95db7ca13c3ce225
2017-06-13 13:30:15 -07:00
Janis Danisevskis
db5b71c924 Fix expected attestation version.
am: 538b7d85ef

Change-Id: I35fd340baa71984a9aa5b1db6d8df1b09cda7a6c
2017-06-08 01:51:38 +00:00
Janis Danisevskis
538b7d85ef Fix expected attestation version.
The attestation version cannot be infered from the keymaster version
because we provide software attestation for legacy keymaster 1 keys.
This patch changes the attestation test to expect either attestation
version 1 or 2.

Bug: 37351644
Test: VtsHalKeymasterV3_0TargetTest
Change-Id: I4db83a543db20191d288b2ca8308aa6597cd8e22
2017-06-07 11:49:56 -07:00
Shawn Willden
76627c3f72 Annotate DeleteKey test with bug number. am: abcd323019
am: 392db77668

Change-Id: If2800344b883ae35e8372d977cc63abdf1832e0d
2017-06-01 15:29:01 +00:00
Shawn Willden
abcd323019 Annotate DeleteKey test with bug number.
Bug: 37623742
Change-Id: I2cb4bb39bacb3aabf5fff7937f60c7355c9636e3
Test: VTS test, manually run
2017-06-01 07:47:04 -06:00
Shawn Willden
1c69c5fcb8 Check return from DeleteKey correctly.
DeleteKey may legitimately return ErrorCode::UNIMPLEMENTED rather than
ErrorCode::OK, but the VTS test didn't allow that in all cases.  In many
case the return code was also left unchecked.

Test: adb shell/data/nativetest64/VtsHalKeymasterV3_0TargetTest/VtsHalKeymasterV3_0TargetTest
Bug: 62193967
Change-Id: I19a90a87850675b0700baf7409e57098e0584d54
2017-06-01 07:44:27 -06:00
Shawn Willden
41fbd43c10 Validate certificate names.
Bug: 38394614
Test: adb shell /data/nativetest64/VtsHalKeymasterV3_0TargetTest/VtsHalKeymasterV3_0TargetTest
Change-Id: If9d985807000f54f57f979f0c2d9f38df8fbd3d3
2017-05-23 19:56:02 -06:00
Shawn Willden
319e5c5c02 Verify that attestation root is a valid self-signed cert.
Bug: 38243685
Test: adb shell /data/nativetests64/VtsHalKeymasterV3_0TargetTest/VtsHalKeymasterV3_0TargetTest
Change-Id: I6b57025e4aab7d475116c51fb43ae9f31778d7c8
2017-05-23 19:45:47 -06:00
Shawn Willden
032d2afb2e Check HAL return codes.
Test: adb shell /data/nativetest64/VtsHalKeymasterV3_0TargetTest/VtsHalKeymasterV3_0TargetTest
Change-Id: I1772cfa97f60bab5acf12b4afccc242a11946085
2017-05-23 19:45:47 -06:00
Shawn Willden
58ce93480b Add missing application ID tag to AES/HMAC attestation calls
Test: Manually verified by running VTS
Change-Id: Iaba04736e3ccc43a662407a6c18416f20d0ee4ea
2017-04-27 13:58:36 +00:00
Shawn Willden
dc9965665e Require attestation app ID.
Bug: 37318025
Test: Manually tested
Change-Id: Iaa992c8d22e0c88c2a2570355199befa484adc19
2017-04-14 11:38:17 +00:00
Shawn Willden
4b93bb21dc Fix handling of KM3 attestations.
Test: Manually tested
Bug: 37318025
Change-Id: I91c0c0fe6d36fb4a02d6b58a3b0836a6f8996012
2017-04-14 11:37:42 +00:00
Janis Danisevskis
88164a4c0e Add DeleteKey and DeleteAllKeys test to Keymaster VTS tests
The tests added verify that a generated key is no longer usable
after it was
 - explicictely deleted with deleteKey, or
 - all keys where deleted with deleteAllKeys.

Bug: 32022681
Test: make vts -j30 BUILD_GOOGLE_VTS=true TARGET_PRODUCT=aosp_arm64 &&
      vts-tradefed run commandAndExit vts --skip-all-system-status-check
      --primary-abi-only --skip-preconditions
      --module VtsHalKeymasterV3_0TargetTest -l INFO
Change-Id: I172ee5d3ccf1850c3c92d3a1a9e991f46b07a0e3
2017-03-31 15:38:27 -07:00
Shawn Willden
63e15f0790 Revert "Revert "Add keymaster VTS tests.""
This reverts commit 8e10baee45.

Test: Tests pass, except known failures with in-progress vendor fixes
Change-Id: Ia95c1444100e123fa65d095b001878cf9040d0c4
2017-03-30 13:21:54 +00:00
Keun Soo Yim
8e10baee45 Revert "Add keymaster VTS tests."
This reverts commit dda22ea884.

Change-Id: Ie6a60e17ed5258840eba3d3f6b8092636160b2c2
2017-03-29 20:18:52 +00:00
Shawn Willden
dda22ea884 Add keymaster VTS tests.
Note: Recent Google devices have keymaster implementations that don't
pass this test suite.  See https://goo.gl/6hsGwa for a summary.

Bug: 32022681
Test: This is the test suite.
Change-Id: Ib200b68e0c7844df02eb9f086385d6c36e306d45
2017-03-29 13:28:16 +00:00