| Commit message (Collapse) | Author | Age | Files | Lines |
... | |
| |
| |
| |
| |
| |
| |
| |
| | |
This doesn't fix the injection vulnerability, but it makes "adb backup"
no worse than the other commands, and lets me fix them all at once.
Bug: 20323053
Change-Id: I39843c065d9d738b6b7943b2ffd660e4a031cc36
|
| |
| |
| |
| |
| | |
Bug: 20317724
Change-Id: If137fc96f5f23576ccecd388ac87afefa47337c6
|
| |
| |
| |
| | |
Change-Id: Ib5511dcba56e80ffce6bc293d99251ccfd61c330
|
|\ \ |
|
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Also add some tests.
Bug: 20323050
Change-Id: I9eaf3dc04efd85206663c4cca4f8c1208620a89a
|
|/ /
| |
| |
| | |
Change-Id: Icd400be05c2bc726265832875b5a05dba7966847
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Bug: 20323052
Bug: 20323051
Bug: 20317728
Bug: 20317727
Bug: 20317726
Bug: 20317725
Change-Id: I57a5e30a5b7867715f55cee7429aa36d7ce21484
|
|\ \ |
|
| | |
| | |
| | |
| | | |
Change-Id: Ic046d6aa540738cb46b54531bc59ba3b47b0136d
|
|/ /
| |
| |
| |
| |
| |
| |
| |
| | |
Incorrectly set $ADB_VENDOR_KEYS is the most likely cause of failed
adb connections. Make it easier to debug such problems by including
the value in use in the error message.
Bug: 20165551
Change-Id: I64c1d98ae6d3fb40eea9e1f0ddcfcf4f2d9d7318
|
|\ \ |
|
| | |
| | |
| | |
| | | |
Change-Id: I21673211a702cc4f31d4311c36e2a4b22e55fac8
|
|\ \ \
| |/ / |
|
| | |
| | |
| | |
| | | |
Change-Id: I1c3c3a7bbd3824f5f3a37ee80c24d1c2a9b98748
|
|/ /
| |
| |
| | |
Change-Id: I27ca41b64d62bb3611b3a39a5c3bb4377d0773bc
|
| |
| |
| |
| | |
Change-Id: I8172e81e6c4665aa16e9e8e0c33b048dbb9ad848
|
|/
|
|
|
|
| |
As long as we have C in here, we can't use C++ in our headers.
Change-Id: Ibccaa77a5af506dc504aa9c39c8dca5dcdbeccab
|
|\ |
|
| |
| |
| |
| |
| |
| |
| | |
Set the verity mode as the value for partition.%s.verified to make it
easier for userspace to determine in which mode dm-verity was started.
Change-Id: Icc635515f8a8ede941277aed196867351d8387cb
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
adb shell uses termios to disable canonical input processing in order to
get raw control codes but it does not disable CR/LF translation. The default
for Linux terminals is to convert CR to LF unless the running program
specifically asks for this to be disabled. Since adb does not, there is no
way to send a CR to any program run on adb shell. Many programs do in fact
differentiate and so are broken by this behaviour, notably nano. This patch
sets the termios flags to disable all line ending translation.
Change-Id: I8b950220f7cc52fefaed2ee37d97e0789b40a078
Signed-off-by: Alistair Buxton <a.j.buxton@gmail.com>
|
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Change 055f1aa4ff58ba71133d506b202ad46612758ded switched to using isalnum(3)
but didn't take into account that isalnum has the opposite sense to the
function it replaced, so the tests should have been inverted.
Bug: http://b/20056546
Change-Id: I90630c0bea69ddbb4a95dc09f79f49d23fd497de
|
|/
|
|
| |
Change-Id: I720b8ef1050da45a7833adef8219b6acb2cf3a38
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Currently it requires manual key press to enter the sideload mode. This
CL adds 'adb reboot sideload' to reboot the device into sideload mode
directly with text display on. With 'adb reboot sideload-auto-reboot',
it will reboot after the sideload regardless of the installation result,
unless interrupted by user.
Since it needs to write to /cache/recovery/command file, 'adb root' is
required before calling 'adb reboot sideload' and the one with
'-auto-reboot'.
Also it requires the matching CL in bootable/recovery.
Change-Id: Ib7bd4e216a1efc01e64460659c97c6005bbaec1b
|
|
|
|
|
|
|
|
|
|
|
| |
adb root doesn't work on the emulator, so this prevents root access
to a userdebug emulator.
Since the emulator has always been root even on userdebug builds, it
may be that adb root has never worked on the emulator.
Bug: 19974213
This reverts commit abd6773b41effd1e1005ad7ce8cb5e370a367302.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The 'adb shell' command on Windows has had problems:
* Ctrl-C killed the local Windows adb.exe process instead of sending the
Ctrl-C to the Android device.
* Local echo was enabled, causing everything typed to be displayed twice.
* Line input was enabled, so the Android device only received input
after hitting enter. This meant that tab completion did not work because
the tab wasn't seen by the shell until pressing enter.
* The usual input line editing keys did not work (Ctrl-A to go to the
beginning of the line, etc.).
This commit fixes these issues by reconfiguring the Win32 console and
then translating input into what Gnome Terminal would send, in effect
somewhat emulating a Unix terminal.
This does not fix all Win32 console issues, but is designed to be better
than what we had before, and to make the common day-to-day usage much
more comfortable and usable.
Change-Id: Idb10e0b634e27002804fa99c09a64e7176cf7c09
Signed-off-by: Spencer Low <CompareAndSwap@gmail.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Addresses nnk's post commit review comments on
https://android-review.googlesource.com/#/c/139381/
Remove unneeded code for creating /data/adb.
Add an O_CLOEXEC.
Move the closing of stdin out to main().
Append the pid of the current process to the log file to avoid
clobbering the log if the process crashes and restarts within the same
second.
Change-Id: Ide0be86b4b33256486634c29ba02efaf10cf913d
|
|
|
|
|
|
|
|
|
| |
Previously the adbd trace mask had to be set as raw hex rather than
with the colon separated list. We all have better things to do than
memorize bitmasks, so make adbd use the same trace mask setting code
as adb.
Change-Id: I0bf0ab61c070d06d1cc2acf1ed90b2b77ccd261b
|
|\ |
|
| |
| |
| |
| |
| |
| |
| | |
Was manifesting as a write to a full disk hanging indefinitely.
Bug: 19846181
Change-Id: Ia581e0bbbb331c221bdb68882c238d0cb9f8a0b3
|
|\ \
| |/
|/| |
|
| |
| |
| |
| |
| |
| |
| |
| |
| | |
* sysdeps.h should always be included first.
* TRACE_TAG needs to be defined before anything is included.
* Some files were missing copyright headers.
* Save precious bytes on my SSD by removing useless whitespace.
Change-Id: I88980e6e00b5be1093806cf286740d9e4a033b94
|
|/
|
|
| |
Change-Id: I8786baf33c0b84e3614e9d40c404eeef94b91236
|
|\ |
|
| |
| |
| |
| |
| |
| |
| |
| |
| | |
if many jdwp connection are created(), the memory will be leaked.
When it deletes heap memory on jdwp_process_free(),
the proc->fde just set to null.
so it need to free() in fdevent_destory().
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
adb_auth_init in adb_auth_client.cpp sets FD_CLOEXEC on the control
socket, which prevents the leakage. However if ro.adb.secure
property is unset (as it is on the emulator), adb_auth_init is not
invoked, which results in the control socket fd leaking into any
process started by the deamon (specifically, any command executed
through adb shell).
Split the fd cleanup into a separate function that is called
unconditionally.
Change-Id: I73ea84977542ddfc4ac20599593ecf3745ae9108
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
This reverts commit 6084a0124f868c7ec43f6c415a27a168f27ff694.
The original build breakage is fixed by (a) building the verity
code for eng builds as well as userdebug builds and (b) moving
the exported remount service functions into a new header file.
Change-Id: Ice0c4f97d4db38ab7eb333c7a6e56bbd11123f5b
|
| |
| |
| |
| |
| |
| |
| |
| | |
This is broken on userdebug builds, and it isn't completely clear why. The declaration for make_block-device_writable in adb.h wasn't updated to match the definition (which uses a std::string instead of a char*). adb.h is currently extern "C", and it isn't clear why this is only broken for userdebug, so I'd like to revert while we investigate.
This reverts commit 81416fdb186070fe4db3ca5fed2e713a4eecaac1.
Change-Id: I47f321574f9f21052e2c7332e8b0f6ef9ab98277
|
| |
| |
| |
| |
| |
| | |
Add support for /oem partition in commands 'adb remount' and 'adb sync'.
Change-Id: I5defc74ccaa37feaef74b9268e22b4075f98a59f
|
| |
| |
| |
| |
| |
| |
| | |
Move StringPrintf and the string based file I/O from libutils to
libbase.
Change-Id: I0297a6063874b9d92100e0dd5123fddfbda932fe
|
| |
| |
| |
| | |
Change-Id: Ia7d22214bc8422c88edaaf9bb716d7e12e0bb381
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
This won't actually ever be uninitialized because the code will take a
failure path if the code that initializes it fails. The goto seems to
thwart this check though.
Not sure why this is only firing on userdebug builds yet. I'll look in
to it tomorrow.
Change-Id: Ie9d837d6baea255d2a4d169355b53dfd775eacce
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
I keep trying to clean things up and needing std::strings. Might as
well just do this now.
usb_linux_client.c is going to stay as C because GCC isn't smart
enough to deal with the designated initializers it uses (though for
some reason it is in C mode).
The Darwin files are staying as C because I don't have a way to test
that they build.
The Windows files are staying as C because while I can actually build
for them, it's slow and painful.
Change-Id: I75367d29205a9049d34460032b3bb36384f43941
|
|\ \ |
|
| |/
| |
| |
| | |
Change-Id: I71b11127d41ebac6caf68926089c5a3b99d8c21e
|
|/
|
|
|
|
|
| |
* Check the current adb user to choose the order of root/unroot.
* Re-root the device when finished.
Change-Id: I47a14b89e2c405bd63722e4d2043fcc629fb5e58
|
|
|
|
|
|
|
|
|
| |
If "adb remount" is done without having done "adb root" first,
scary looking SELinux denials are emitted before the operation
eventually fails. Avoid the scary looking messages by refusing
remount attempts if we're not running with privileges.
Change-Id: I298621251a10e38345ef77875003a97c8b5a0270
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Renamed readx/writex to ReadFdExactly/WriteFdExactly respectively.
These read/write a full fixed-size buffer. If the whole buffer cannot
be read/written, these functions return an error.
Rename write_string to WriteStringFully.
Move the TEMP_FAILURE_RETRY definition in sysdeps.h out of the
!Windows section. It seems Windows won't actually interrupt a call,
but it's easier to just define it than to #ifdef each call.
Change-Id: Ia8ddffa2a52764a2f9a281c96c937660e002b9b9
|
|
|
|
|
|
| |
None of the functions that require these are used.
Change-Id: I10cffab127795b94340131f8737f7924b9138f9e
|
|
|
|
| |
Change-Id: I946b5b1e5650540db3b4f75892214c4218b3baf3
|
|
|
|
| |
Change-Id: Ieb6f2650ce5f39f1d8c938d0ca8cbec459d8e2fd
|