Fix shell command vulnerability in WindowManagerService

Gated entry to onShellCommand with ROOT and SHELL UID checks.
This prevents untrusted applications from executing any shell commands inside WindowManagerService.

Bug: 527036176
Test: atest DisplayAreaTest
Flag: EXEMPT BUGFIX
TAG=agy
CONV=29cf44a3-6266-4be5-8f50-636684cbcc90
Cherrypick-From: https://googleplex-android-review.googlesource.com/q/commit:41251a751e8ae1b368f035d4a02d8b200071a38f
Cherrypick-From: https://googleplex-android-review.googlesource.com/q/commit:3b944484beebfc13fb07a98fb6eec2df4c18e28d
Merged-In: Ic3fab3ddbb131aeb086fb05d4858ecb6f3173960
Change-Id: Ic3fab3ddbb131aeb086fb05d4858ecb6f3173960
2 files changed