Remove KeyStore#state()
Remove AndroidKeyStoreMaintenance#getState() and both overloads of KeyStore#state(). None of these are used by platform code anymore. The two KeyStore#state() methods do have @UnsupportedAppUsage, as do two values of the State enum: UNLOCKED and LOCKED. However, there is a clear public API equivalent for apps that may be checking these states: UserManager#isUserUnlocked(). Therefore, according to the policy on unsupported usage of internal APIs, we can remove these internal APIs. Also, the non-SDK dashboard has no runtime results for either method, and only one static analysis result which is from unused code in one app. This is consistent with these methods being entirely unused. Part of the motivation for removing these internal APIs is that upcoming changes to the lifetime of keystore superencryption keys would change the behavior of getState. So it seems like a good time to remove this unused/unsupported code instead of wasting time maintaining it. Bug: 296464083 Test: atest -p --include-subdirs system/security/keystore2 Change-Id: Iff821bbdeac5ee0653c9c71867fd53d38cb4d48f
Loading
Please register or sign in to comment