support @SensitiveData -> FLAG_CLEAR_BUF
Allow interfaces to be marked as SensitiveData, so that
transactions to them have data/replies cleared in kernel data.
Bug: 171501998
Test: aidl_integration_test, inspecting source
Change-Id: I89e20235ef587767eea8036bff2f7ac321926718
diff --git a/aidl_unittest.cpp b/aidl_unittest.cpp
index 9b899d1..c51f655 100644
--- a/aidl_unittest.cpp
+++ b/aidl_unittest.cpp
@@ -421,7 +421,8 @@
const string method = "package a; @nullable interface IFoo { int f(); }";
const string expected_stderr =
"ERROR: a/IFoo.aidl:1.21-31: 'nullable' is not a supported annotation for this node. "
- "It must be one of: Hide, UnsupportedAppUsage, VintfStability, JavaPassthrough, Descriptor\n";
+ "It must be one of: Hide, UnsupportedAppUsage, VintfStability, SensitiveData, "
+ "JavaPassthrough, Descriptor\n";
CaptureStderr();
EXPECT_EQ(nullptr, Parse("a/IFoo.aidl", method, typenames_, GetLanguage(), &error));
EXPECT_EQ(expected_stderr, GetCapturedStderr());
@@ -640,8 +641,8 @@
EXPECT_NE(0, ::android::aidl::compile_aidl(java_options, io_delegate_));
const std::string expected_stderr =
"ERROR: a/IFoo.aidl:1.23-33: 'JavaDerive' is not a supported annotation for this node. "
- "It must be one of: Hide, UnsupportedAppUsage, VintfStability, JavaPassthrough, "
- "Descriptor\n";
+ "It must be one of: Hide, UnsupportedAppUsage, VintfStability, SensitiveData, "
+ "JavaPassthrough, Descriptor\n";
EXPECT_EQ(expected_stderr, GetCapturedStderr());
}