Commit Graph

30363 Commits

Author SHA1 Message Date
Mark Salyzyn b3b67adafd Merge "logd: validate and fill in socket credentials" am: 17254f59a2
am: 1423041905

Change-Id: I80c1ec043d288ae037a208702c639acf0042fc27
2017-05-11 23:40:19 +00:00
Mark Salyzyn 9a2b70a7c8 Merge "logcat: test: inject for *.event_tag_filter" am: 2841b4efe0
am: ed1e53fc77

Change-Id: I4b6c0f145fa83b4c1bb895256b4de45598e5f363
2017-05-11 23:39:49 +00:00
Renaud Paquay c134530c37 Merge "Fix uninitialized member variable" am: 46bb1ffa8a
am: 9cf71d784e

Change-Id: Ib7644e66e1860a13c0e79b5976d9159ff2de43d2
2017-05-11 23:39:22 +00:00
Mark Salyzyn 5698594d8a Merge "logd: test: check sepolicy background rate before testing" am: 5a40c42877
am: 1961eab662

Change-Id: I7ce24090e02b9902c615c2263cfaba3134c2526e
2017-05-11 23:38:51 +00:00
Mark Salyzyn 1423041905 Merge "logd: validate and fill in socket credentials"
am: 17254f59a2

Change-Id: I987d058e7245f5cb9a3603b3f52f7fa947d5dea7
2017-05-11 22:14:10 +00:00
Mark Salyzyn ed1e53fc77 Merge "logcat: test: inject for *.event_tag_filter"
am: 2841b4efe0

Change-Id: Ic1fb5ed5bb304ab4a6fa3e55414a07e73c5d546b
2017-05-11 22:13:48 +00:00
Siarhei Vishniakou d819380f50 Merge "Adding 'uhid' permission for access to /dev/uhid." am: cecbc9993d
am: 04daed4793

Change-Id: I2bcaa5fe48f60c837ac341c71819c492860f50e2
2017-05-11 22:02:14 +00:00
Treehugger Robot 17254f59a2 Merge "logd: validate and fill in socket credentials" 2017-05-11 21:49:30 +00:00
Treehugger Robot 2841b4efe0 Merge "logcat: test: inject for *.event_tag_filter" 2017-05-11 21:48:38 +00:00
Renaud Paquay 9cf71d784e Merge "Fix uninitialized member variable"
am: 46bb1ffa8a

Change-Id: I102f6414d6846186327f68b5dae2e23eadfa0502
2017-05-11 21:04:41 +00:00
Mark Salyzyn 1961eab662 Merge "logd: test: check sepolicy background rate before testing"
am: 5a40c42877

Change-Id: I785965cc1c27d598f3293493d133e7b865c98d59
2017-05-11 21:04:16 +00:00
Siarhei Vishniakou 04daed4793 Merge "Adding 'uhid' permission for access to /dev/uhid."
am: cecbc9993d

Change-Id: I0cfcdaac7685f10a6f2b5e9bfc54a83cc5385da2
2017-05-11 20:48:04 +00:00
Mark Salyzyn c4e4823b00 logd: validate and fill in socket credentials
- android::pidToUid() additional checking.  Make sure if we have to
  convert a PID to an UID that the parse of /proc/<pid>/status
  requires a trailing space after the number
- android::tidToPid() added, in the same vein as android::pidToUid().
- stats.tidToPid() added
- If no credentials, set PID to 0 and UID to DEFAULT_OVERFLOWUID
- If credentialed PID is 0, use stats.tidToPid()
- If credentialed UID is DEFAULT_OVERFLOWUID, use stats.pidToUid()

Test: remove +passcred from logd.rc for daemon and confirm very few
      UID=65534 or PID=0 cases actually show up
Bug: 37985222
Change-Id: I7d20506e70e67beb3043d1537cf9450ab58dc278
2017-05-11 12:21:02 -07:00
Treehugger Robot 46bb1ffa8a Merge "Fix uninitialized member variable" 2017-05-11 19:17:21 +00:00
Mark Salyzyn 24b79ce2bc logcat: test: inject for *.event_tag_filter
Inject a message for event_tag_filter and bucket tests. The former
registered an occasional failure.

Switch order of EXPECT checks so that constant is on the right so
that error reports make more sense.

Test: gTest logcat-unit-tests --gtest_filter=*.event_tag_filter
Test: gTest logcat-unit-tests
Bug: 37791296
Change-Id: Ic2536e6e4c95e3a913ad0ea4c22219aa3c5c01eb
2017-05-11 12:16:06 -07:00
Treehugger Robot 5a40c42877 Merge "logd: test: check sepolicy background rate before testing" 2017-05-11 19:13:52 +00:00
Siarhei Vishniakou cecbc9993d Merge "Adding 'uhid' permission for access to /dev/uhid." 2017-05-11 19:02:32 +00:00
Renaud Paquay b7a4f0b9e2 Fix uninitialized member variable
The default constructor of FileMap was missing an initializer for the
mFileMapping variables. This results in CloseHandle being called with
a "random" value, which can cause havoc in Win32 process over time (e.g.
in the case of libaapt2_jni.dll, which is loaded in a JVM process).

Also, update the code to use "NULL" for invalid file map handle
and "INVALID_HANDLE_VALUE" for invalid file handle.

Bug: 38197857
Test: Stress testing on (Windows) machine
Change-Id: Ibd769219d601fbafcfcee89e848b31cc5137826c
2017-05-11 10:30:52 -07:00
Mark Salyzyn c51ecf9238 logd: test: check sepolicy background rate before testing
logd.sepolicy_rate_limiter_* tests can fail individually so join them
together into one test.  The new test logd.sepolicy_rate_limiter
fails as a group if the background sepolicy activity is too high, so
check it and report a warning that the test can fail as a result so it
can be forgiven during unit testing.  The failure remains as a VTS
performance threshold that requires investigation.

The test takes a total of 45 seconds to run, it was split up as this
approaches the 60 second test timeout on go/apct.

Test: gTest logd-unit-tests --gtest_filter=logd.sepolicy_rate_limiter
      (run in loop ensuring passes do not interfere with eachother)
Bug: 37791296
Change-Id: Ia865241f684c6b0de428702cbd5110dc17927c66
2017-05-11 17:16:30 +00:00
Siarhei Vishniakou 0729dd1edb Adding 'uhid' permission for access to /dev/uhid.
This CL is in support of another CL c/2048848, topic
'Refactor hid command in /frameworks/base/cmds' in
internal master. Adding the permissions for
shell here to access uhid_node as part of the
new 'uhid' group.

Bug: 34052337
Test: Tested on angler, bluetooth mouse works OK.

Change-Id: If9e100aa1262d689fb8adc5c0ce93f157c96399e
2017-05-11 01:28:53 +00:00
Josh Gao 61c8aea04a Merge changes I0ff1fc5c,I7a23d3bf am: 7d199de8e2
am: 162ec283cf

Change-Id: I1dc9b13c00f6944368257e9a4e347278ec46f55f
2017-05-11 00:05:43 +00:00
Chih-Hung Hsieh 3f9923cf7f Merge "Work around clang-tidy segmentation fault." am: d761dd747e
am: 4a926efc49

Change-Id: I5e4b9b8507dc24bb44323c331eabe1afb25dd8f5
2017-05-11 00:05:13 +00:00
Josh Gao 162ec283cf Merge changes I0ff1fc5c,I7a23d3bf
am: 7d199de8e2

Change-Id: I6f47c2f66d79b8d26c239c974dcea34e4e8fef67
2017-05-10 23:54:41 +00:00
Chih-Hung Hsieh 4a926efc49 Merge "Work around clang-tidy segmentation fault."
am: d761dd747e

Change-Id: I51913166b123b41e31c23da8c0def798057dd556
2017-05-10 23:54:12 +00:00
Josh Gao 7d199de8e2 Merge changes I0ff1fc5c,I7a23d3bf
* changes:
  libdebuggerd: print the build fingerprint in fallback.
  libdebuggerd: implement fallback register dumping on arm/aarch64.
2017-05-10 23:24:38 +00:00
Treehugger Robot d761dd747e Merge "Work around clang-tidy segmentation fault." 2017-05-10 23:11:19 +00:00
Josh Gao 40866ccfc0 Merge "adb: fix darwin build break." am: a0661237e1
am: 8016a0aa11

Change-Id: I159bb4720cef0e9cfcb845d76195262f568e94b2
2017-05-10 22:10:48 +00:00
Josh Gao 8016a0aa11 Merge "adb: fix darwin build break."
am: a0661237e1

Change-Id: If89dd3fa27da4316122802af234b6104c2a8ef58
2017-05-10 22:08:44 +00:00
Josh Gao a0661237e1 Merge "adb: fix darwin build break." 2017-05-10 21:58:10 +00:00
Josh Gao 362b4041f3 adb: fix darwin build break.
Fix the following build breakage:

    system/core/adb/client/usb_osx.cpp:433:13: error: static declaration of 'usb_cleanup' follows non-static declaration
    static void usb_cleanup() NO_THREAD_SAFETY_ANALYSIS {
                ^
    system/core/adb/usb.h:48:5: note: previous declaration is here
        ADB_USB_INTERFACE(native::usb_handle*);

Bug: http://b/38203892
Test: mma on linux, darwin
Change-Id: I1c042e4d64ddcc0713f329202bc2037e590a9b4f
2017-05-10 13:58:51 -07:00
Josh Gao 75f0275fba Merge changes I394f5782,I9475f5d0,I59707186 am: 44f6592b0d
am: b7f3707cd3

Change-Id: Id2899cce43a39d099797ce9915b3d924cae41e75
2017-05-10 19:13:08 +00:00
Josh Gao b7f3707cd3 Merge changes I394f5782,I9475f5d0,I59707186
am: 44f6592b0d

Change-Id: Ic1a62436b98f986e129a6b08d1ab939b70d5f3e6
2017-05-10 19:01:57 +00:00
Josh Gao 44f6592b0d Merge changes I394f5782,I9475f5d0,I59707186
* changes:
  adb: move all cleanup to a function with defined ordering.
  adb: make `adb kill-server` wait for the server to die.
  adb: libusb: replace sleep with timed CV wait.
2017-05-10 18:42:14 +00:00
Elliott Hughes eba1d8338f Merge "Fix style nits in adb's Android.mk." am: 30b7f59efc
am: 86698112b9

Change-Id: I1ebbd9a008f5d0cd0812d85802888a952ea77a1b
2017-05-10 18:36:43 +00:00
Elliott Hughes 86698112b9 Merge "Fix style nits in adb's Android.mk."
am: 30b7f59efc

Change-Id: I6a2ff9ba9967e16917397141ced113d5a884d826
2017-05-10 17:55:03 +00:00
Elliott Hughes 30b7f59efc Merge "Fix style nits in adb's Android.mk." 2017-05-10 17:43:54 +00:00
Elliott Hughes 8964fbfa5f Fix style nits in adb's Android.mk.
We [try to] always use trailing \s in lists.

Bug: N/A
Test: builds
Change-Id: Ibc1ccacbe8a31f784f206d29a8c4f0f4650f7bde
2017-05-10 08:41:50 -07:00
Elliott Hughes 8ff4dbe443 Merge "Fix build error when (ADB|FASTBOOT)_VERSION has space" am: 3d29736d6b
am: f2f3c3b91c

Change-Id: Id03922e268fed3174ca4d63976c31b682c4ab202
2017-05-10 15:34:37 +00:00
Elliott Hughes f2f3c3b91c Merge "Fix build error when (ADB|FASTBOOT)_VERSION has space"
am: 3d29736d6b

Change-Id: I8b3fa683884606e441340940e52114c5f94bb484
2017-05-10 15:26:37 +00:00
Elliott Hughes 3d29736d6b Merge "Fix build error when (ADB|FASTBOOT)_VERSION has space" 2017-05-10 15:11:28 +00:00
SzuWei Lin b3526e1ee8 Fix build error when (ADB|FASTBOOT)_VERSION has space
Test: make, and build pass
Change-Id: I8fc608a5b8bccb43b8af72978ce16a945147f62d
2017-05-10 18:52:02 +08:00
George Burgess IV 543f2c68be Merge "fix static-analyzer logging/CHECK macros" am: 01e7990a10
am: 951d7e953e

Change-Id: I0d6055f7c055b4d841e02945d30074ce898aab5e
2017-05-10 03:13:18 +00:00
Dimitry Ivanov fb669dc648 Merge "Explicitly enable greylist for classloader-namespaces" am: 2f2cd76d4d
am: 55ecc6ff6f

Change-Id: I9a1514d4721902ce49058014d53b455e95bad5cb
2017-05-10 03:12:52 +00:00
George Burgess IV 951d7e953e Merge "fix static-analyzer logging/CHECK macros"
am: 01e7990a10

Change-Id: If2094a3c41fe95b6c5727e65cbd02cb6d88a08d8
2017-05-10 03:08:12 +00:00
Dimitry Ivanov 55ecc6ff6f Merge "Explicitly enable greylist for classloader-namespaces"
am: 2f2cd76d4d

Change-Id: I6dd5c358aa34da3166bfb5e7f579677f1ae2b7eb
2017-05-10 03:07:51 +00:00
Treehugger Robot 01e7990a10 Merge "fix static-analyzer logging/CHECK macros" 2017-05-10 03:05:40 +00:00
Treehugger Robot 2f2cd76d4d Merge "Explicitly enable greylist for classloader-namespaces" 2017-05-10 02:53:32 +00:00
Elliott Hughes 92764e2cb2 Merge "Show the "platform tools" version in adb/fastboot --version." am: 6f4d47438d
am: 3602f6141a

Change-Id: I359a28e0a82ae7cb9e84ff8fe147c8f9baf87a86
2017-05-10 01:56:28 +00:00
Bowgo Tsai fec0b13902 Merge "first stage mount: removing the requirement of by-name prefix for AVB" am: cdad92fdad
am: c82235ebbd

Change-Id: I333b3437621ee611cb9033a8e0d1fbd78fcef8d0
2017-05-10 01:56:03 +00:00
Elliott Hughes 3602f6141a Merge "Show the "platform tools" version in adb/fastboot --version."
am: 6f4d47438d

Change-Id: I5ff109186b29b9770f61506eb4cfb99ce71db4e9
2017-05-10 01:51:38 +00:00