Commit Graph

4 Commits

Author SHA1 Message Date
Devin Moore
212a6da42c Specify @throws for secure_element AIDL reset() method
This was expected to return an error in the HIDL version, so we
explicitly say which it should return on failure.

Brought up in ANAPIC review in ag/21108335

Test: none
Bug: none
Change-Id: I6f183a490f91aca5e08b5ae83017e707b63268ea
2023-03-22 19:52:23 +00:00
Henri Chataing
27b30c61d0 secure_element/aidl: Add error case for transmit()
Modify the semantics of transmit() to return a service
specific error with code CHANNEL_NOT_AVAILABLE if there
was an error in communicating with the secure element.

This can happen if the SE is put in low power mode when
no logical or basic channel is opened, e.g.

Bug: 270091254
Test: m VtsHalSecureElementTargetTest
Change-Id: I7df3ec6d9b6d5eeb2272971c44fc078a8558d2e6
2023-02-27 17:59:58 +00:00
Henri Chataing
cf06db3171 secure_element: Rework the VTS tests for ISecureElement AIDL
Add missing checks for the proper use of init() interface.
Test correct channel management.

Test: atest VtsHalSecureElementTargetTest
Bug: 123254068
Change-Id: I411b070aa1a3e1d4fb4ac38d004a1cfc81e86023
2023-01-12 13:51:38 +00:00
Steven Moreland
6fe6954dd4 secure-element to AIDL
Bug: 205762050
Test: atest VtsHalSecureElementTargetTest (8/8 passed)
Test: atest CtsOmapiTestCases
    - all tests pass except testStatusWordTransmit,
      testTransmitApdu, and testSelectNext. This is because
      these tests don't increase coverage of the HAL API
      except they call 'transmit' several times. Doing a full
      mock OMAPI/APDU implementation for cuttlefish/AOSP is
      tracked in b/123254068

Change-Id: I0ec0eb08fbcc4207d8c07427ccdf7ff106995627
2022-11-24 01:24:13 +00:00