[automerger skipped] KeyMint VTS: skip device ID checks on GSI am: 32a7bece10 -s ours
am skip reason: Merged-In I3182bad5584c35df7b1eeb476dabb39d19fdf12c with SHA-1 555ba00c0f is already in history
Original change: https://googleplex-android-review.googlesource.com/c/platform/hardware/interfaces/+/18182183
Change-Id: I7b9c7e64bb43ce089d64f7d8debb6ebe83faa395
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
diff --git a/audio/common/all-versions/default/tests/hidlutils_tests.cpp b/audio/common/all-versions/default/tests/hidlutils_tests.cpp
index ec16b02..e5ed844 100644
--- a/audio/common/all-versions/default/tests/hidlutils_tests.cpp
+++ b/audio/common/all-versions/default/tests/hidlutils_tests.cpp
@@ -17,6 +17,7 @@
#include <array>
#include <string>
+#include <android-base/test_utils.h>
#include <gtest/gtest.h>
#define LOG_TAG "HidlUtils_Test"
@@ -1100,6 +1101,7 @@
TYPED_TEST_SUITE(FilterTest, FilterTestTypeParams);
TYPED_TEST(FilterTest, FilterOutNonVendorTags) {
+ SKIP_WITH_HWASAN; // b/230535046
TypeParam emptyTags;
EXPECT_EQ(emptyTags, HidlUtils::filterOutNonVendorTags(emptyTags));
diff --git a/audio/core/all-versions/vts/functional/7.0/AudioPrimaryHidlHalTest.cpp b/audio/core/all-versions/vts/functional/7.0/AudioPrimaryHidlHalTest.cpp
index f25c391..dfc2386 100644
--- a/audio/core/all-versions/vts/functional/7.0/AudioPrimaryHidlHalTest.cpp
+++ b/audio/core/all-versions/vts/functional/7.0/AudioPrimaryHidlHalTest.cpp
@@ -715,7 +715,7 @@
sink.base.channelMask.value(getConfig().base.channelMask);
sink.ext.mix({});
sink.ext.mix().ioHandle = helper.getIoHandle();
- sink.ext.mix().useCase.source(toString(xsd::AudioSource::AUDIO_SOURCE_MIC));
+ sink.ext.mix().useCase.source(initMetadata.tracks[0].source);
EXPECT_OK(getDevice()->createAudioPatch(hidl_vec<AudioPortConfig>{source},
hidl_vec<AudioPortConfig>{sink},
returnIn(res, mPatchHandle)));
diff --git a/audio/core/all-versions/vts/functional/AudioPrimaryHidlHalTest.h b/audio/core/all-versions/vts/functional/AudioPrimaryHidlHalTest.h
index 38d6eff..38e9e5f 100644
--- a/audio/core/all-versions/vts/functional/AudioPrimaryHidlHalTest.h
+++ b/audio/core/all-versions/vts/functional/AudioPrimaryHidlHalTest.h
@@ -1239,23 +1239,30 @@
: public OpenStreamTest<::android::hardware::audio::CORE_TYPES_CPP_VERSION::IStreamIn> {
void SetUp() override {
ASSERT_NO_FATAL_FAILURE(OpenStreamTest::SetUp()); // setup base
+ auto flags = getInputFlags();
#if MAJOR_VERSION <= 6
address.device = AudioDevice::IN_DEFAULT;
#elif MAJOR_VERSION >= 7
auto maybeSourceAddress = getCachedPolicyConfig().getSourceDeviceForMixPort(
getDeviceName(), getMixPortName());
+ auto& metadata = initMetadata.tracks[0];
if (maybeSourceAddress.has_value() &&
!xsd::isTelephonyDevice(maybeSourceAddress.value().deviceType)) {
address = maybeSourceAddress.value();
- auto& metadata = initMetadata.tracks[0];
metadata.source = toString(xsd::AudioSource::AUDIO_SOURCE_UNPROCESSED);
metadata.channelMask = getConfig().base.channelMask;
} else {
address.deviceType = toString(xsd::AudioDevice::AUDIO_DEVICE_IN_DEFAULT);
}
-#endif
+#if MAJOR_VERSION == 7 && MINOR_VERSION >= 1
+ auto flagsIt = std::find(flags.begin(), flags.end(),
+ toString(xsd::AudioInOutFlag::AUDIO_INPUT_FLAG_ULTRASOUND));
+ if (flagsIt != flags.end()) {
+ metadata.source = toString(xsd::AudioSource::AUDIO_SOURCE_ULTRASOUND);
+ }
+#endif // 7.1
+#endif // MAJOR_VERSION >= 7
const AudioConfig& config = getConfig();
- auto flags = getInputFlags();
testOpen(
[&](AudioIoHandle handle, AudioConfig config, auto cb) {
return getDevice()->openInputStream(handle, address, config, flags,
diff --git a/audio/effect/all-versions/default/Android.bp b/audio/effect/all-versions/default/Android.bp
index 1e01ffb..a3c3ed6 100644
--- a/audio/effect/all-versions/default/Android.bp
+++ b/audio/effect/all-versions/default/Android.bp
@@ -30,6 +30,7 @@
],
shared_libs: [
+ "libaudioutils",
"libbase",
"libcutils",
"libeffects",
@@ -48,6 +49,7 @@
"libeffects_headers",
"libhardware_headers",
"libmedia_headers",
+ "libmediautils_headers",
],
}
diff --git a/audio/effect/all-versions/default/Effect.cpp b/audio/effect/all-versions/default/Effect.cpp
index 49f6bf2..3baafc9 100644
--- a/audio/effect/all-versions/default/Effect.cpp
+++ b/audio/effect/all-versions/default/Effect.cpp
@@ -22,13 +22,11 @@
#include "Effect.h"
#include "common/all-versions/default/EffectMap.h"
-#include <memory.h>
-
#define ATRACE_TAG ATRACE_TAG_AUDIO
-
#include <HidlUtils.h>
#include <android/log.h>
#include <media/EffectsFactoryApi.h>
+#include <mediautils/ScopedStatistics.h>
#include <util/EffectUtils.h>
#include <utils/Trace.h>
@@ -49,21 +47,27 @@
namespace {
+#define SCOPED_STATS() \
+ ::android::mediautils::ScopedStatistics scopedStatistics { \
+ std::string("EffectHal::").append(__func__), mEffectHal->mStatistics \
+ }
+
class ProcessThread : public Thread {
public:
// ProcessThread's lifespan never exceeds Effect's lifespan.
- ProcessThread(std::atomic<bool>* stop, effect_handle_t effect,
- std::atomic<audio_buffer_t*>* inBuffer, std::atomic<audio_buffer_t*>* outBuffer,
- Effect::StatusMQ* statusMQ, EventFlag* efGroup)
- : Thread(false /*canCallJava*/),
- mStop(stop),
- mEffect(effect),
- mHasProcessReverse((*mEffect)->process_reverse != NULL),
- mInBuffer(inBuffer),
- mOutBuffer(outBuffer),
- mStatusMQ(statusMQ),
- mEfGroup(efGroup) {}
- virtual ~ProcessThread() {}
+ ProcessThread(std::atomic<bool>* stop, effect_handle_t effect,
+ std::atomic<audio_buffer_t*>* inBuffer, std::atomic<audio_buffer_t*>* outBuffer,
+ Effect::StatusMQ* statusMQ, EventFlag* efGroup, Effect* effectHal)
+ : Thread(false /*canCallJava*/),
+ mStop(stop),
+ mEffect(effect),
+ mHasProcessReverse((*mEffect)->process_reverse != NULL),
+ mInBuffer(inBuffer),
+ mOutBuffer(outBuffer),
+ mStatusMQ(statusMQ),
+ mEfGroup(efGroup),
+ mEffectHal(effectHal) {}
+ virtual ~ProcessThread() {}
private:
std::atomic<bool>* mStop;
@@ -73,6 +77,7 @@
std::atomic<audio_buffer_t*>* mOutBuffer;
Effect::StatusMQ* mStatusMQ;
EventFlag* mEfGroup;
+ Effect* const mEffectHal;
bool threadLoop() override;
};
@@ -102,6 +107,9 @@
audio_buffer_t* outBuffer =
std::atomic_load_explicit(mOutBuffer, std::memory_order_relaxed);
if (inBuffer != nullptr && outBuffer != nullptr) {
+ // Time this effect process
+ SCOPED_STATS();
+
if (efState & static_cast<uint32_t>(MessageQueueFlagBits::REQUEST_PROCESS)) {
processResult = (*mEffect)->process(mEffect, inBuffer, outBuffer);
} else {
@@ -359,7 +367,7 @@
// Create and launch the thread.
mProcessThread = new ProcessThread(&mStopProcessThread, mHandle, &mHalInBufferPtr,
- &mHalOutBufferPtr, tempStatusMQ.get(), mEfGroup);
+ &mHalOutBufferPtr, tempStatusMQ.get(), mEfGroup, this);
status = mProcessThread->run("effect", PRIORITY_URGENT_AUDIO);
if (status != OK) {
ALOGW("failed to start effect processing thread: %s", strerror(-status));
@@ -749,6 +757,8 @@
if (fd.getNativeHandle() != nullptr && fd->numFds == 1) {
uint32_t cmdData = fd->data[0];
(void)sendCommand(EFFECT_CMD_DUMP, "DUMP", sizeof(cmdData), &cmdData);
+ const std::string s = mStatistics->dump();
+ if (s.size() != 0) write(cmdData, s.c_str(), s.size());
}
return Void();
}
diff --git a/audio/effect/all-versions/default/Effect.h b/audio/effect/all-versions/default/Effect.h
index f9a6796..011544d 100644
--- a/audio/effect/all-versions/default/Effect.h
+++ b/audio/effect/all-versions/default/Effect.h
@@ -29,6 +29,7 @@
#include <fmq/MessageQueue.h>
#include <hidl/MQDescriptor.h>
#include <hidl/Status.h>
+#include <mediautils/MethodStatistics.h>
#include <utils/Thread.h>
#include <hardware/audio_effect.h>
@@ -169,7 +170,11 @@
Result setParameterImpl(uint32_t paramSize, const void* paramData, uint32_t valueSize,
const void* valueData);
- private:
+ // process execution statistics
+ const std::shared_ptr<mediautils::MethodStatistics<std::string>> mStatistics =
+ std::make_shared<mediautils::MethodStatistics<std::string>>();
+
+ private:
friend struct VirtualizerEffect; // for getParameterImpl
friend struct VisualizerEffect; // to allow executing commands
diff --git a/bluetooth/1.0/default/test/fuzzer/bluetoothV1.0_fuzzer.cpp b/bluetooth/1.0/default/test/fuzzer/bluetoothV1.0_fuzzer.cpp
index 90cdc66..fb8df99 100644
--- a/bluetooth/1.0/default/test/fuzzer/bluetoothV1.0_fuzzer.cpp
+++ b/bluetooth/1.0/default/test/fuzzer/bluetoothV1.0_fuzzer.cpp
@@ -88,11 +88,18 @@
}
mBtHci->close();
mBtHci.clear();
+ for (size_t i = 0; i < mFdCount; ++i) {
+ if (mFdList[i]) {
+ close(mFdList[i]);
+ }
+ }
}
bool init(const uint8_t* data, size_t size);
void process();
private:
+ size_t mFdCount = 1;
+ int32_t mFdList[CH_MAX] = {0};
sp<BluetoothHci> mBtHci = nullptr;
FuzzedDataProvider* mFdp = nullptr;
};
@@ -143,17 +150,15 @@
bool shouldSetH4Protocol = mFdp->ConsumeBool();
BtVendor* btVendor = BtVendor::getInstance();
- size_t fdcount = 1;
- int32_t fdList[CH_MAX] = {0};
if (!shouldSetH4Protocol) {
- fdcount = mFdp->ConsumeIntegralInRange<size_t>(kMinFdcount, CH_MAX - 1);
+ mFdCount = mFdp->ConsumeIntegralInRange<size_t>(kMinFdcount, CH_MAX - 1);
}
- for (size_t i = 0; i < fdcount; ++i) {
- fdList[i] = open("/dev/null", O_RDWR | O_CREAT);
+ for (size_t i = 0; i < mFdCount; ++i) {
+ mFdList[i] = open("/dev/null", O_RDWR | O_CREAT);
}
- btVendor->populateFdList(fdList, fdcount);
+ btVendor->populateFdList(mFdList, mFdCount);
mBtHci->initialize(bluetoothCallback);
if (!bluetoothCallback->isInitialized) {
@@ -181,12 +186,6 @@
}
btVendor->callRemainingCbacks();
-
- for (size_t i = 0; i < fdcount; ++i) {
- if (fdList[i]) {
- close(fdList[i]);
- }
- }
}
extern "C" int LLVMFuzzerTestOneInput(const uint8_t* data, size_t size) {
diff --git a/compatibility_matrices/Android.bp b/compatibility_matrices/Android.bp
index 422b37e..524242f 100644
--- a/compatibility_matrices/Android.bp
+++ b/compatibility_matrices/Android.bp
@@ -87,7 +87,6 @@
vintf_compatibility_matrix {
name: "framework_compatibility_matrix.current.xml",
- enabled: false,
stem: "compatibility_matrix.current.xml",
srcs: [
"compatibility_matrix.current.xml",
diff --git a/compatibility_matrices/Android.mk b/compatibility_matrices/Android.mk
index d6a44d0..d19f0da 100644
--- a/compatibility_matrices/Android.mk
+++ b/compatibility_matrices/Android.mk
@@ -103,6 +103,7 @@
framework_compatibility_matrix.5.xml \
framework_compatibility_matrix.6.xml \
framework_compatibility_matrix.7.xml \
+ framework_compatibility_matrix.current.xml \
framework_compatibility_matrix.device.xml \
my_framework_matrix_deps += \
diff --git a/security/keymint/aidl/android/hardware/security/keymint/ProtectedData.aidl b/security/keymint/aidl/android/hardware/security/keymint/ProtectedData.aidl
index cfbf171..6db58f2 100644
--- a/security/keymint/aidl/android/hardware/security/keymint/ProtectedData.aidl
+++ b/security/keymint/aidl/android/hardware/security/keymint/ProtectedData.aidl
@@ -18,13 +18,20 @@
/**
* ProtectedData contains the encrypted BCC and the ephemeral MAC key used to
- * authenticate the keysToSign (see keysToSignMac output argument).
+ * authenticate the keysToSign (see keysToSignMac output argument of
+ * IRemotelyProvisionedComponent.generateCertificateRequest).
* @hide
*/
@VintfStability
parcelable ProtectedData {
/**
- * ProtectedData is a COSE_Encrypt structure, specified by the following CDDL
+ * ProtectedData is a COSE_Encrypt structure, encrypted with an AES key that is agreed upon
+ * using Elliptic-curve Diffie-Hellman. The contents of the structure are specified by the
+ * following CDDL [RFC8610].
+ *
+ * Notes:
+ * - None of the CBOR in ProtectedData uses CBOR tags. If an implementation includes
+ * tags, parsers may reject the data.
*
* ProtectedData = [ // COSE_Encrypt
* protected: bstr .cbor {
@@ -34,13 +41,18 @@
* 5 : bstr .size 12 // IV
* },
* ciphertext: bstr, // AES-GCM-256(K, .cbor ProtectedDataPayload)
+ * // Where the encryption key 'K' is derived as follows:
+ * // ikm = ECDH(EEK_pub, Ephemeral_priv)
+ * // salt = null
+ * // info = .cbor Context (see below)
+ * // K = HKDF-SHA-256(ikm, salt, info)
* recipients : [
* [ // COSE_Recipient
* protected : bstr .cbor {
* 1 : -25 // Algorithm : ECDH-ES + HKDF-256
* },
* unprotected : {
- * -1 : PubKeyX25519 / PubKeyEcdhP256 // Of the sender
+ * -1 : PubKeyX25519 / PubKeyEcdhP256 // Ephemeral_pub
* 4 : bstr, // KID : EEK ID
* },
* ciphertext : nil
@@ -48,14 +60,14 @@
* ]
* ]
*
- * K = HKDF-256(ECDH(EEK_pub, Ephemeral_priv), Context)
- *
- * Context = [ // COSE_KDF_Context
+ * // The COSE_KDF_Context that is used to derive the ProtectedData encryption key with
+ * // HKDF. See details on use in ProtectedData comments above.
+ * Context = [
* AlgorithmID : 3 // AES-GCM 256
* PartyUInfo : [
* identity : bstr "client"
* nonce : bstr .size 0,
- * other : bstr // Ephemeral pubkey
+ * other : bstr // Ephemeral_pub
* ],
* PartyVInfo : [
* identity : bstr "server",
@@ -68,41 +80,55 @@
* ]
* ]
*
+ * // The data that is encrypted and included in ProtectedData ciphertext (see above).
* ProtectedDataPayload [
* SignedMac,
* Bcc,
* ? AdditionalDKSignatures,
* ]
+ *
+ * // AdditionalDKSignatures allows the platform to provide additional certifications
+ * // for the DK_pub. For example, this could be provided by the hardware vendor, who
+ * // certifies all of their devices. The SignerName is a free-form string describing
+ * // who generated the signature.
* AdditionalDKSignatures = {
* + SignerName => DKCertChain
* }
*
+ * // SignerName is a string identifier that indicates both the signing authority as
+ * // well as the format of the DKCertChain
* SignerName = tstr
*
* DKCertChain = [
- * 2* Certificate // Root -> Leaf. Root is the vendor
- * // self-signed cert, leaf contains DK_pub
+ * 2* Certificate // Root -> ... -> Leaf. "Root" is the vendor self-signed
+ * // cert, "Leaf" contains DK_pub. There may also be
+ * // intermediate certificates between Root and Leaf.
* ]
*
- * Certificate = COSE_Sign1 of a public key
+ * // Certificates may be either:
+ * // 1. COSE_Sign1, with payload containing PubKeyEd25519 or PubKeyECDSA256
+ * // 2. a bstr containing a DER-encoded X.509 certificate (RSA, NIST P-curve, or edDSA)
+ * Certificate = COSE_Sign1 / bstr
*
- * SignedMac = [ // COSE_Sign1
- * bstr .cbor { // Protected params
- * 1 : AlgorithmEdDSA / AlgorithmES256, // Algorithm
+ * // The SignedMac, which authenticates the MAC key that is used to authenticate the
+ * // keysToSign.
+ * SignedMac = [ // COSE_Sign1
+ * bstr .cbor { // Protected params
+ * 1 : AlgorithmEdDSA / AlgorithmES256, // Algorithm
* },
- * {}, // Unprotected params
- * bstr .size 32, // MAC key
+ * {}, // Unprotected params
+ * bstr .size 32, // Payload: MAC key
* bstr // PureEd25519(KM_priv, bstr .cbor SignedMac_structure) /
* // ECDSA(KM_priv, bstr .cbor SignedMac_structure)
* ]
*
- * SignedMac_structure = [
+ * SignedMac_structure = [ // COSE Sig_structure
* "Signature1",
- * bstr .cbor { // Protected params
- * 1 : AlgorithmEdDSA / AlgorithmES256, // Algorithm
+ * bstr .cbor { // Protected params
+ * 1 : AlgorithmEdDSA / AlgorithmES256, // Algorithm
* },
- * bstr .cbor SignedMacAad
- * bstr .size 32 // MAC key
+ * bstr .cbor SignedMacAad,
+ * bstr .size 32 // MAC key
* ]
*
* SignedMacAad = [
@@ -114,31 +140,48 @@
* // the signature.
* ]
*
+ * VerifiedDeviceInfo = DeviceInfo // See DeviceInfo.aidl
+ *
+ * // The BCC is the boot certificate chain, containing measurements about the device
+ * // boot chain. The BCC generally follows the Open Profile for DICE specification at
+ * // https://pigweed.googlesource.com/open-dice/+/HEAD/docs/specification.md.
+ * //
+ * // The first entry in the Bcc is the DK_pub, encoded as a COSE_key. All entries after
+ * // the first describe a link in the boot chain (e.g. bootloaders: BL1, BL2, ... BLN).
+ * // Note that there is no BccEntry for DK_pub, only a "bare" COSE_key.
* Bcc = [
* PubKeyEd25519 / PubKeyECDSA256, // DK_pub
* + BccEntry, // Root -> leaf (KM_pub)
* ]
*
- * BccPayload = { // CWT
- * 1 : tstr, // Issuer
- * 2 : tstr, // Subject
- * // See the Open Profile for DICE for details on these fields.
- * ? -4670545 : bstr, // Code Hash
- * ? -4670546 : bstr, // Code Descriptor
- * ? -4670547 : bstr, // Configuration Hash
- * ? -4670548 : bstr .cbor { // Configuration Descriptor
- * ? -70002 : tstr, // Component name
- * ? -70003 : int, // Firmware version
- * ? -70004 : null, // Resettable
- * },
- * ? -4670549 : bstr, // Authority Hash
- * ? -4670550 : bstr, // Authority Descriptor
- * ? -4670551 : bstr, // Mode
+ * // This is the signed payload for each entry in the Bcc. Note that the "Configuration
+ * // Input Values" described by the Open Profile are not used here. Instead, the Bcc
+ * // defines its own configuration values for the Configuration Descriptor field. See
+ * // the Open Profile for DICE for more details on the fields. All hashes are SHA256.
+ * BccPayload = { // CWT [RFC8392]
+ * 1 : tstr, // Issuer
+ * 2 : tstr, // Subject
* -4670552 : bstr .cbor PubKeyEd25519 /
- * bstr .cbor PubKeyECDSA256 // Subject Public Key
- * -4670553 : bstr // Key Usage
+ * bstr .cbor PubKeyECDSA256, // Subject Public Key
+ * -4670553 : bstr // Key Usage
+ *
+ * // NOTE: All of the following fields may be omitted for a "Degenerate BCC", as
+ * // described by IRemotelyProvisionedComponent.aidl.
+ * -4670545 : bstr, // Code Hash
+ * ? -4670546 : bstr, // Code Descriptor
+ * ? -4670547 : bstr, // Configuration Hash
+ * -4670548 : bstr .cbor { // Configuration Descriptor
+ * ? -70002 : tstr, // Component name
+ * ? -70003 : int, // Firmware version
+ * ? -70004 : null, // Resettable
+ * },
+ * -4670549 : bstr, // Authority Hash
+ * ? -4670550 : bstr, // Authority Descriptor
+ * -4670551 : bstr, // Mode
* }
*
+ * // Each entry in the Bcc is a BccPayload signed by the key from the previous entry
+ * // in the Bcc array.
* BccEntry = [ // COSE_Sign1 (untagged)
* protected : bstr .cbor {
* 1 : AlgorithmEdDSA / AlgorithmES256, // Algorithm
@@ -159,8 +202,8 @@
* payload: bstr .cbor BccPayload
* ]
*
- * VerifiedDeviceInfo = DeviceInfo // See DeviceInfo.aidl
- *
+ * // The following section defines some types that are reused throughout the above
+ * // data structures.
* PubKeyX25519 = { // COSE_Key
* 1 : 1, // Key type : Octet Key Pair
* -1 : 4, // Curve : X25519
@@ -168,25 +211,25 @@
* }
*
* PubKeyEd25519 = { // COSE_Key
- * 1 : 1, // Key type : octet key pair
- * 3 : AlgorithmEdDSA, // Algorithm : EdDSA
- * -1 : 6, // Curve : Ed25519
- * -2 : bstr // X coordinate, little-endian
+ * 1 : 1, // Key type : octet key pair
+ * 3 : AlgorithmEdDSA, // Algorithm : EdDSA
+ * -1 : 6, // Curve : Ed25519
+ * -2 : bstr // X coordinate, little-endian
* }
*
- * PubKeyEcdhP256 = { // COSE_Key
- * 1 : 2, // Key type : EC2
- * -1 : 1, // Curve : P256
- * -2 : bstr // Sender X coordinate
- * -3 : bstr // Sender Y coordinate
+ * PubKeyEcdhP256 = { // COSE_Key
+ * 1 : 2, // Key type : EC2
+ * -1 : 1, // Curve : P256
+ * -2 : bstr // Sender X coordinate
+ * -3 : bstr // Sender Y coordinate
* }
*
- * PubKeyECDSA256 = { // COSE_Key
- * 1 : 2, // Key type : EC2
- * 3 : AlgorithmES256, // Algorithm : ECDSA w/ SHA-256
- * -1 : 1, // Curve: P256
- * -2 : bstr, // X coordinate
- * -3 : bstr // Y coordinate
+ * PubKeyECDSA256 = { // COSE_Key
+ * 1 : 2, // Key type : EC2
+ * 3 : AlgorithmES256, // Algorithm : ECDSA w/ SHA-256
+ * -1 : 1, // Curve: P256
+ * -2 : bstr, // X coordinate
+ * -3 : bstr // Y coordinate
* }
*
* AlgorithmES256 = -7
diff --git a/security/keymint/aidl/android/hardware/security/keymint/Tag.aidl b/security/keymint/aidl/android/hardware/security/keymint/Tag.aidl
index b28ebcb..42dfad5 100644
--- a/security/keymint/aidl/android/hardware/security/keymint/Tag.aidl
+++ b/security/keymint/aidl/android/hardware/security/keymint/Tag.aidl
@@ -504,7 +504,9 @@
* that is necessary during all uses of the key. In particular, calls to exportKey() and
* getKeyCharacteristics() must provide the same value to the clientId parameter, and calls to
* begin() must provide this tag and the same associated data as part of the inParams set. If
- * the correct data is not provided, the method must return ErrorCode::INVALID_KEY_BLOB.
+ * the correct data is not provided, the method must return ErrorCode::INVALID_KEY_BLOB. Note
+ * that a key with a zero-length APPLICATION_ID cannot have its key characteristics retrieved
+ * using getKeyCharacteristics() due to a historical limitation of the API.
*
* The content of this tag must be bound to the key cryptographically, meaning it must not be
* possible for an adversary who has access to all of the secure world secrets but does not have
@@ -525,7 +527,9 @@
* that is necessary during all uses of the key. In particular, calls to begin() and
* exportKey() must provide the same value to the appData parameter, and calls to begin must
* provide this tag and the same associated data as part of the inParams set. If the correct
- * data is not provided, the method must return ErrorCode::INVALID_KEY_BLOB.
+ * data is not provided, the method must return ErrorCode::INVALID_KEY_BLOB. Note that a key
+ * with a zero-length APPLICATION_DATA cannot have its key characteristics retrieved using
+ * getKeyCharacteristics() due to a historical limitation of the API.
*
* The content of this tag must be bound to the key cryptographically, meaning it must not be
* possible for an adversary who has access to all of the secure world secrets but does not have