When switching users and attempting to lock the device, the sysui main
thread becomes overwhelmed with events, creating a significant lag
between the time a message is posted and processed on the main
thread. This can be dangerous when these events are critical for
security, such as calls coming from PhoneWindowManager#lockNow() that
call KeyguardViewMediator#doKeyguardTimeout(). On older devices with
slower CPUs and less memory, the delay in processing can be
significant (15 - 30s).
The result of not prioritizing these events leads to a window of time
where a guest user can switch back to the owner, and gain access to
the owner's homescreen without needing to unlock the device with the
owner's credentials.
As a mitigation, prioritize two events originating in two specific
methods to make sure the device locks as soon as possible as well as
have the system server preemptively update its local cache.
Bug: 151095871
Test: Very manual race condition - follow steps listed in bug
Change-Id: I7585a0a5eeb308e0e32a4f77f581556d883b5cda
Merged-In: I7585a0a5eeb308e0e32a4f77f581556d883b5cda
(cherry picked from commit 28c53ab8bc)
This line was removed in O, S, & P, but somehow survived in the Q and R branches.
Bug: 193444889
Merged-In: I56589865427b10e2eab68e1ed2e7c290572a9edc
Change-Id: I56589865427b10e2eab68e1ed2e7c290572a9edc
This line was removed in O, S, & P, but somehow survived in the Q and R branches.
Bug: 193444889
Merged-In: I56589865427b10e2eab68e1ed2e7c290572a9edc
Change-Id: I56589865427b10e2eab68e1ed2e7c290572a9edc
If a profile owner is defined for a specific user, do not delete usage
stats for a package on package deletion.
Bug: 197399948
Test: atest UsageStatsTest [all]
Change-Id: I94a8e3dfca8ef4c7616f77944d61726e06043b85
Merged-In: I94a8e3dfca8ef4c7616f77944d61726e06043b85
For all other requests, drop this flag.
Test: atest FlagSlipperyTest
Bug: 157929241
Change-Id: Ia30f1c38d5ddb351c90b748ea76448a76a9dde7b
Merged-In: Ia30f1c38d5ddb351c90b748ea76448a76a9dde7b
* changes:
DO NOT MERGE: Revert "Map TYPE_TRUSTED_APPLICATION_OVERLAY to system window type for A11y"
Add mechanism for a task's windows to be trusted overlays
Change InputWindowInfo::isTrustedOverlay() to be permission and flag based
These decorations set flag_slippery, to cover the unlikely event of user
tapping a screen decor and then not able to send this touch gesture to
the neighboring window.
Bug: 157929241
Test: `adb shell dumpsys input` and make sure that ScreenDecorOverlay
and ScreeDecorOverlayBottom have FLAG_SLIPPERY
Change-Id: Ib276764edcf1acffe94e3db7397fd23aaaa5dbaa
Merged-In: Ib276764edcf1acffe94e3db7397fd23aaaa5dbaa
(cherry picked from commit 8eca1d5615)
- Exposes a method to set that a certain part of the SF hierarchy is
trusted, and sets this state for tasks in PIP.
Bug: 191529039
Bug: 196389741
Test: Manual, try using permission dialog while PIP is active
Change-Id: I170cb5a7d22ef569eb36de21cc0bcbef60dd385e
Merged-In: I170cb5a7d22ef569eb36de21cc0bcbef60dd385e
Add private flag to WindowManager.LayoutParams. If the flag is set,
check if caller has INTERNAL_SYSTEM_WINDOW permission.
Bug: 155781676
Bug: 196389741
Test: atest WindowManagerServiceTests
Change-Id: I70151697cc01e8427129f951f0ebadc4805b2d56
Merged-In: I70151697cc01e8427129f951f0ebadc4805b2d56
This adds a force flag, which we will use when turning the screen off to make sure that all UI components are reset to the SHADE state regardless.
Bug: 189575031
Test: make a call; lock screen; pull down shade
Merged-In: I79baeb71ac5d1ed45602ac55cdca996b3bed0ac3
Change-Id: I79baeb71ac5d1ed45602ac55cdca996b3bed0ac3
(cherry picked from commit 921d955822)
migrateExtraStreamToClipData() will only offer to promote Uri values
if a ClipData isn't already defined, so we ensure that a ClipData
value is always defined. This blocks later promotion and granting.
Bug: 200683077
Bug: 123700107
Test: manual
Change-Id: I99c1411e8b4eb01eb27ac4306e3bf6cc88cb4273
(cherry picked from commit 6ebf410b81)
This adds a force flag, which we will use when turning the screen off to make sure that all UI components are reset to the SHADE state regardless.
Bug: 189575031
Test: make a call; lock screen; pull down shade
Merged-In: I79baeb71ac5d1ed45602ac55cdca996b3bed0ac3
Change-Id: I79baeb71ac5d1ed45602ac55cdca996b3bed0ac3
This adds a force flag, which we will use when turning the screen off to make sure that all UI components are reset to the SHADE state regardless.
Bug: 189575031
Test: make a call; lock screen; pull down shade
Merged-In: I79baeb71ac5d1ed45602ac55cdca996b3bed0ac3
Change-Id: I79baeb71ac5d1ed45602ac55cdca996b3bed0ac3
This reverts commit b45ebca772.
Reason for revert: adding the fix for system to abandon sessions
BUG: 67862680
Test: manual
Change-Id: I2b735e4860dce6eb6d5d8ddc158e8b3165910dc7
Merged-In: I91170ba399b3a596320b3bd9c8188912e5c4f1be
This reverts commit b45ebca772.
Reason for revert: adding the fix for system to abandon sessions
BUG: 67862680
Test: manual
Change-Id: Ia798eb776eb1d05347514a238a6dd75e7c89e872
Merged-In: I91170ba399b3a596320b3bd9c8188912e5c4f1be
This reverts commit b45ebca772.
Reason for revert: adding the fix for system to abandon sessions
BUG: 67862680
Test: manual
Change-Id: I5b762a29d12f62b516a59a85530386236259308b
Merged-In: I91170ba399b3a596320b3bd9c8188912e5c4f1be
Prevents non-system apps from placing a window over the app selection
screen.
Bug: 143559931
Test: Installed test app and attempted to overlay
Change-Id: Ied05088a5007e0f10cd3e1abd8d7da8ffeb3b674
Merged-In: Ied05088a5007e0f10cd3e1abd8d7da8ffeb3b674
(cherry picked from commit 34534e1fd2)
Prevents non-system apps from placing a window over the app selection
screen.
Bug: 143559931
Test: Installed test app and attempted to overlay
Change-Id: Ied05088a5007e0f10cd3e1abd8d7da8ffeb3b674
Merged-In: Ied05088a5007e0f10cd3e1abd8d7da8ffeb3b674
(cherry picked from commit 34534e1fd2)