diff options
author | Max Bires <jbires@google.com> | 2021-04-16 14:15:32 -0700 |
---|---|---|
committer | Max Bires <jbires@google.com> | 2021-04-17 15:37:43 -0700 |
commit | 4190509ed6fd13262daaaf783415306dfa30a313 (patch) | |
tree | 0ccc7080c98af56bd6862f06a837902eebc0955e /security/keymint/aidl/default/RemotelyProvisionedComponent.cpp | |
parent | 6594b5f1b4a65fb22e12c1c42dad235feb6ae69d (diff) |
Adding getHardwareInfo to IRPC
This adds a way to derive information about the hardware for clients
that call the HAL. The primary functional usecase here is to
differentiate which EC curve the underlying hardware for a given
instance of IRemotelyProvisionedComponent is supported.
Originally, curve 25519 would have been used in all implementations for
verifying the EEK certificate chain and doing ECDH, but secure elements
do not offer 25519 support yet. In order to support remote provisioning
on SEs, we have to relax the standard here a bit to allow for P256.
Test: Everything builds
Change-Id: I9245c6f4e27bd118fe093bffc0152549ed7f0825
Diffstat (limited to 'security/keymint/aidl/default/RemotelyProvisionedComponent.cpp')
-rw-r--r-- | security/keymint/aidl/default/RemotelyProvisionedComponent.cpp | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/security/keymint/aidl/default/RemotelyProvisionedComponent.cpp b/security/keymint/aidl/default/RemotelyProvisionedComponent.cpp index 5b027292fe..d6a1edc9dc 100644 --- a/security/keymint/aidl/default/RemotelyProvisionedComponent.cpp +++ b/security/keymint/aidl/default/RemotelyProvisionedComponent.cpp @@ -291,6 +291,13 @@ RemotelyProvisionedComponent::RemotelyProvisionedComponent( RemotelyProvisionedComponent::~RemotelyProvisionedComponent() {} +ScopedAStatus RemotelyProvisionedComponent::getHardwareInfo(RpcHardwareInfo* info) { + info->versionNumber = 1; + info->rpcAuthorName = "Google"; + info->supportedEekCurve = RpcHardwareInfo::CURVE_25519; + return ScopedAStatus::ok(); +} + ScopedAStatus RemotelyProvisionedComponent::generateEcdsaP256KeyPair(bool testMode, MacedPublicKey* macedPublicKey, bytevec* privateKeyHandle) { |