The settings app may not be available. In that case, just show the adb
notification without a PendingIntent.
Bug: 156453114
Test: atest AdbNotificationsTest
Test: With USB debugging enabled, install TestDPC, and use it to hide settings app.
Unplug and replug USB. USB debugging notification shows up and clicking
it does nothing.
Change-Id: Ie29d2c425c05bce9371600d76e4eb2eaba692fd7
Change-Id: Ie5f746cbc7b8a32fc280177bf281a9e973c8df12
Use an explicit intent and set PendingIntent.FLAG_IMMUTABLE to prevent
someone from modifying the intent from PendingIntent.send(...).
Bug: 153356209
Test: atest AdbNotificationsTest
Test: In bug, install and launch the PoC apk and give it notification
permissions. Then, with USB/Wifi debugging enabled, disconnect and connect
the device to create the adb notification. the PoC apk should not have
permission to display information from
content://com.android.settings.files/my_cache/NOTICE.html.
Change-Id: Ie49aa3cf9b33168cf1435fc2427e95aac7f4609b
(cherry picked from commit 2c03881459)
Exempt-From-Owner-Approval: approved in master
There's some weird state where if persist.sys.usb.config=none,adb, then
adbd won't get started. Give back adbd start permissions to
UsbDeviceManager to see if that fixes the issue.
Bug: 150130503
Bug: 150116813
Test: adb shell su 0 setprop persist.sys.usb.config none,adb; adb reboot
adb should be online after.
Change-Id: I36c6ef4b20d58570a2d51ed70088ae5c54d6687d
Exempt-From-Owner-Approval: Fix adbd offline failure
(cherry picked from commit 7a3800993d)
Since wireless debugging can be enabled without usb debugging enabled,
we'll need to differentiate between which transport is enabled.
Also added the internal AdbManager stubs for wireless debugging. Adding
implementation in separate CL to get around merge conflict with a SysUI
CL in the stack.
BUG: b/111434128
Test: make
Exempt-From-Owner-Approval: already approved
Change-Id: I4e1ae6398f291f321e61e7eb119564ebd5e54c2e
Because the ADB keys are now stored in adb_temp_keys.xml as well, Test
Harness Mode should back up and restore that file. To resolve a comment
in the initial CL, it uses a LocalService to actually interact with the
AdbService to retrieve the file, so any future changes in file location
should be immediately propagated to Test Harness Mode.
There were also two minor bugs fixed in this CL:
1) When serializing the adb keys to the XML file, if the allowedTime was
0, they were all removed
2) If all keys are removed, the file was only an XML header and therefore
invalid XML
Test: adb shell cmd testharness enable
Test: adb shell settings put global adb_allowed_connection_time 1;
unplug device, plug device back in, adb shell cat
/data/misc/adb/adb_temp_keys.xml (should return 'No such file or
directory')
Change-Id: I09e2998a0b80660486502f7486d4c838219c342c
Also remove the "Usb" from the AIDL function since it's not really
related to USB.
Test: make
Bug: 63820489
Change-Id: Ibf23964665a115a5bc835820dcff98aaf7ba610f
This makes the AdbService the source of truth for whether ADB is enabled
on the system or not. All UsbManager checks will now query the
AdbService.
Test: make
Bug: 63820489
Change-Id: I2965a15b5fa9f747fe0ae4dc791b5e357e78253f
This is what the USB manager will use to query the current ADB state in
the future.
Bug: 63820489
Test: make
Change-Id: I70484f97e56af4e5104611dc3b43ef83885671d7
This adds the AIDL definition for ADB transports. For instance USB is
one type of ADB transport and the only one supported now.
Bug: 63820489
Test: make
Change-Id: Id422a814567021ab4b1097c2792a95c42bfccf74
This will allow the call of internal-only AdbService functions from within
the system server.
Bug: 63820489
Test: make
Change-Id: Ic761b513a8c10ce0173ddb6bc761a6372799f15c
Create skeleton service to migrate functions from UsbService in later
change.
Bug: 63820489
Test: make
Change-Id: I07672fe87cfae188fe77c173fc49119e182c6b05
JNITest class is no longer actively used. This patch
removes the class (java and jni) files.
JNI interfaces and calls are extensively tested in
the art unit tests (art/tests) and in cts (see
CtsJniTestCases).
Change-Id: I62f7c72deb5d206fa3f545ae39a9cb9011110d0a
Signed-off-by: Ashok Bhat <ashok.bhat@arm.com>
Many media files and source code files were marked as executable in Git.
Remove those.
Also a shell script and python script were not marked as executable.
Change-Id: Ieb51bafb46c895a21d2e83696f5a901ba752b2c5