History log of /frameworks/base/services/core/java/com/android/server/SyntheticPasswordCrypto.java
Revision Date Author Comments (<<< Hide modified files) (Show modified files >>>)
12b644d275b121dd952a4a564fa65b9c18c9b22c 21-Apr-2017 Rubin Xu <rubinxu@google.com> Introduce KEYSTORE_FLAG_CRITICAL_TO_DEVICE_ENCRYPTION

This flag is used by system server to mark keys used during the
synthetic password auth flow. keys marked with this flag will not
be super encrypted because super encryption requires knowledge of
the synthetic password, causing a chicken-and-egg problem.

Bug: 35849499
Bug: 34600579
Test: cts-tradefed run cts-dev -m CtsDevicePolicyManagerTestCases -t com.android.cts.devicepolicy.MixedProfileOwnerTest#testResetPasswordWithToken

Change-Id: I474822f2e026f24ce6f6de1aa58b5012922f7b13
/frameworks/base/services/core/java/com/android/server/SyntheticPasswordCrypto.java
3bf722a8d54ca7192dfe07ee7b73eac7d25ccac5 15-Dec-2016 Rubin Xu <rubinxu@google.com> Add synthetic password to authentication flow

The user password is used to unlock a per-user synthetic password which
serves the purpose of what the user password previsouly achieves (protect
keystore, vold disk encryption, auth token generation).

Test: runtest frameworks-services -c com.android.server.SyntheticPasswordTests
Test: manual
1. Start with fresh device, enable synthetic password with "adb shell cmd lock_settings sp 1"
1.1 add device lock, reboot and verify (positive & negative); change device lock, reboot and verify.
1.2 Inflate a work profile, reboot and verify device lock. check SID with "adb shell dumpsys lock_settings"
1.3 Un-unify and add work challenge, reboot and verify work challenge and SID.
1.4 Re-unify work challenge, reboot and verify.
1.5 Clear device lock, reboot and verify lock and SID.

2. Start with a fresh device, add a device lock and inflate a work profile.
2.1 Enable synthetic password, note current SID
2.2 Reboot and unlock device. Verify synthetic password is generated and SID remains.
2.3 Clear device lock, reboot and verify (SID should be cleared)

3. Start with a fresh device, inflate a work profile, add separate work challenge
3.1 Enable synthetic password, not current SID
3.2 Reboot and unlock device and profile. Verify synthetic password is generated.
3.3 Clear device lock only, reboot and verify (work profile SID should remain)

All steps tested on marlin (FBE) and bullhead (FDE)

Bug: 33126414
Change-Id: Idb9ebfc7bba2fe40670c5fee2189e873d9704540
/frameworks/base/services/core/java/com/android/server/SyntheticPasswordCrypto.java