summaryrefslogtreecommitdiffstats
path: root/adb
Commit message (Collapse)AuthorAgeFilesLines
* Merge "Windows adb: include stdint.h for uint8_t on MinGW-w64"Kenny Root2013-01-301-0/+1
|\
| * Windows adb: include stdint.h for uint8_t on MinGW-w64Ray Donnelly2013-01-081-0/+1
| | | | | | | | Change-Id: I84b8284bc034feb0acd313b0aad9e2fa5868854f
* | Merge "Windows adb: initialize on to 1 in disable_tcp_nagle"Kenny Root2013-01-301-1/+1
|\ \
| * | Windows adb: initialize on to 1 in disable_tcp_nagleRay Donnelly2013-01-111-1/+1
| | |
* | | Merge "Windows adb: Make client stdout and stderr handles uninheritable"David Turner2013-01-211-0/+21
|\ \ \ | |/ / |/| / | |/
| * Windows adb: Make client stdout and stderr handles uninheritableRay Donnelly2013-01-081-0/+21
| | | | | | | | Change-Id: Ib0519a199c9504aad1d0ecc3757f4d162984bf22
* | Merge "Correct LOCAL_LDLIBS of adb"Ying Wang2013-01-081-2/+2
|\ \
| * | Correct LOCAL_LDLIBS of adbChih-Wei Huang2013-01-011-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | adb doesn't really use ncurses-libs, remove it. Add -ldl for the symbols dlclose, dlerror, dlopen... introduced from dso_dlfcn.c of libcrypto_static.a. Change-Id: If1cc23987a9b35ec535bbf8f4e7db141b9f10af7
* | | Support adb client connect to remote serverMatt Gumbel2013-01-044-7/+73
|/ / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | ADB client: allow user to specify hostname and port number of remote adb server. ADB server: bind server to all network interfaces instead of just localhost when user gives -a flag. Primary use-case for this change is to support remote testing of USB devices. HostA is running some test automation software which invokes adb client. HostB has USB-only device attached and is running adb server. adb client on HostA makes connection to adb server on HostB to talk to the USB device. Change-Id: I845cc8c00350b400317f8c18f813e6fd79bd5470 Signed-off-by: Dean Kwon <daex.i.kwon@intel.com> Signed-off-by: Jim Bride <jim.bride@intel.com> Signed-off-by: Matt Gumbel <matthew.k.gumbel@intel.com>
* | adb: Improve ADB's forward redirection management.David 'Digit' Turner2012-11-263-33/+258
|/ | | | | | | | | | | | | | | | This adds a few new options/modes to 'adb forward': adb forward --list adb forward --remove <local> adb forward --remove-all adb forward --no-rebind <local> <remote> For more context, see http://code.google.com/p/android/issues/detail?id=39631 Note that this only affects the host adb client and server programs, i.e. it's compatible with devices running older adbd versions. Change-Id: I9cda3ba12b5a8560a2061620bc7f948e5c1e70f7
* am f621d62a: am c4244565: am d1e39491: Add usb vendor id for Teleepoch.Xavier Ducrohet2012-11-081-0/+4
|\ | | | | | | | | * commit 'f621d62adcbcd81d6479223d9afe47c1d966710d': Add usb vendor id for Teleepoch.
| * Add usb vendor id for Teleepoch.Xavier Ducrohet2012-11-061-0/+4
| | | | | | | | Change-Id: I82bbfed598fc3a886681c4139600cf487034c59c
* | am 51ccef27: Merge "Add TEMP_FAILURE_RETRY macro for darwin"Kenny Root2012-10-131-0/+15
|\ \ | | | | | | | | | | | | * commit '51ccef27cab58277775e62518a59666d2a059b62': Add TEMP_FAILURE_RETRY macro for darwin
| * | Add TEMP_FAILURE_RETRY macro for darwinKenny Root2012-10-131-0/+15
| | | | | | | | | | | | | | | | | | | | | | | | | | | Darwin doesn't define the TEMP_FAILURE_RETRY macro in unistd.h so we need to add it everywhere. Joy! (cherry picked from commit ec90f1dc11488f0ab8a25a9159965b4ae3c4ca88) Change-Id: Ida554fc65193672cc4616dec79e6282e06cc1b28
* | | am 207c17ff: Merge "Make adb robust against EINTR"Kenny Root2012-10-122-9/+10
|\ \ \ | |/ / | | / | |/ |/| * commit '207c17ff1f48d0db3c69628bb036a14db40b5887': Make adb robust against EINTR
| * Make adb robust against EINTRKenny Root2012-10-122-9/+10
| | | | | | | | Change-Id: I39a8d9007ce2d5662a33a50e4d7e2e7f8f9fad63
* | Merge "Bring back ADB_EXTERNAL_STORAGE." into jb-mr1-devJeff Sharkey2012-09-061-0/+10
|\ \
| * | Bring back ADB_EXTERNAL_STORAGE.Jeff Sharkey2012-09-061-0/+10
| | | | | | | | | | | | | | | Bug: 7119408 Change-Id: Ic9a23fb6adfb1db771e1e278179586bca69a5edd
* | | Dist fastboot and adb for the sdk build.Ying Wang2012-09-051-1/+1
|/ / | | | | | | | | | | | | So they can be downloaded from the build page. Bug: 7109694 Change-Id: Ibc60d0acbc5d2445c01010fd0bd4654a240b0a88
* | adb: Link statically with libcryptoBenoit Goby2012-08-311-5/+3
| | | | | | | | | | Bug: 7063951 Change-Id: I328b76a751aceaae625d64156f22ce3de65678c8
* | adb: Create private key with 0600 modeBenoit Goby2012-08-312-2/+8
| | | | | | | | | | | | | | Changed key name to force generating new pairs. Bug: 7092477 Change-Id: I680cb9dd1896ae52b2b29d63533f966e033d823f
* | adb: Add public key authentificationBenoit Goby2012-08-238-22/+882
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Secure adb using a public key authentication, to allow USB debugging only from authorized hosts. When a device is connected to an unauthorized host, the adb daemon sends the user public key to the device. A popup is shown to ask the user to allow debugging once or permanantly from the host. The public key is installed on the device in the later case. Other keys may be installed at build time. On the host, the user public/private key pair is automatically generated, if it does not exist, when the adb daemon starts and is stored in $HOME/.android/adb_key(.pub) or in $ANDROID_SDK_HOME on windows. If needed, the ADB_KEYS_PATH env variable may be set to a :-separated (; under Windows) list of private keys, e.g. company-wide or vendor keys. On the device, vendors public keys are installed at build time in /adb_keys. User-installed keys are stored in /data/misc/adb/adb_keys. ADB Protocol change: If the device needs to authenticate the host, it replies to CNXN packets with an AUTH packet. The AUTH packet payload is a random token. The host signs the token with one of its private keys and sends an AUTH(0) packet. If the signature verification succeeds, the device replies with a CNXN packet. Otherwise, it sends a new AUTH packet with a new token so that the host can retry with another private key. Once the host has tried all its keys, it can send an AUTH(1) packet with a public key as payload. adbd then sends the public key to the framework (if it has been started) for confirmation. Change-Id: I4e84d7621da956f66ff657245901bdaefead8395
* | Iteration on multi-user external storage.Jeff Sharkey2012-08-221-10/+0
| | | | | | | | | | | | | | | | | | | | Define /storage as top-level concept, so that we enforce permissions uniformly. Moves external storage paths from headers to per-device environment variables. Added missing mount flags, and we no longer have adb-specific external storage. Bug: 6925012 Change-Id: Ic7ca953be2f552d3f0ec9e69f89fef751daa1b29
* | Revert "adb: Add public key authentification"Benoit Goby2012-08-207-875/+18
| | | | | | | | This reverts commit f4ed516643ee8ed3a59ad1a8048f7ce5f47f93fb.
* | Merge "adb: Add public key authentification" into jb-mr1-devBenoit Goby2012-08-207-18/+875
|\ \
| * | adb: Add public key authentificationBenoit Goby2012-08-167-18/+875
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Secure adb using a public key authentication, to allow USB debugging only from authorized hosts. When a device is connected to an unauthorized host, the adb daemon sends the user public key to the device. A popup is shown to ask the user to allow debugging once or permanantly from the host. The public key is installed on the device in the later case. Other keys may be installed at build time. On the host, the user public/private key pair is automatically generated, if it does not exist, when the adb daemon starts and is stored in $HOME/.android/adb_key(.pub) or in $ANDROID_SDK_HOME on windows. If needed, the ADB_KEYS_PATH env variable may be set to a ;-separated list of private keys, e.g. company-wide or vendor keys. On the device, vendors public keys are installed at build time in /adb_keys. User-installed keys are stored in /data/misc/adb/adb_keys. ADB Protocol change: If the device needs to authenticate the host, it replies to CNXN packets with an AUTH packet. The AUTH packet payload is a random token. The host signs the token with one of its private keys and sends an AUTH(0) packet. If the signature verification succeeds, the device replies with a CNXN packet. Otherwise, it sends a new AUTH packet with a new token so that the host can retry with another private key. Once the host has tried all its keys, it can send an AUTH(1) packet with a public key as payload. adbd then sends the public key to the framework (if it has been started) for confirmation. Change-Id: Idce931a7bfe4ce878428eaa47838e5184ac6073f
* | | Merge "Replace a segfault with a warning." into jb-mr1-devJohn Grossman2012-08-201-1/+7
|\ \ \
| * | | Replace a segfault with a warning.John Grossman2012-08-201-1/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Just print a warning if ADB_EXTERNAL_STORAGE is not defined when ADB runs instead of segfaulting. If we really don't want to continue to run, we can make this a fatal error instead. Change-Id: Icfc5fb9e594b0a310029f1dca7e9476f27ceb7bc
* | | | am 42900c30: am 0874aa0e: Merge "adb: Pick desired product value from ↵Jean-Baptiste Queru2012-08-201-1/+1
|\ \ \ \ | |/ / / |/| | / | | |/ | |/| | | | | | | command line it follows -p" * commit '42900c30cf39ea4cdc41cc3671584b7f4f39b8bc': adb: Pick desired product value from command line it follows -p
| * | Merge "adb: Pick desired product value from command line it follows -p"Jean-Baptiste Queru2012-08-201-1/+1
| |\ \
| | * | adb: Pick desired product value from command line it follows -pVairavan Srinivasan2012-08-041-1/+1
| | | | | | | | | | | | | | | | Change-Id: Ic9fb74c99c88479addf3a2cc599b8492ced759d8
* | | | Migrate sdcard0 to shell-accessible location.Jeff Sharkey2012-08-201-21/+3
| |_|/ |/| | | | | | | | | | | | | | | | | | | | | | | Also remove mount() from adb, since it can come online long before data partition is ready. Set EXTERNAL_STORAGE environment variable to point to owner for backwards compatibility. Bug: 7005701 Change-Id: I63444f6636624eb7ad89f053daa289663424639e
* | | Multi-user external storage support.Jeff Sharkey2012-08-151-1/+23
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Remount rootfs as recursively shared, so that mount changes are propagated into child namespaces. Mount external storage for access from adb. Clean multi-user dependencies for use in Dalvik. Also define external storage paths. Bug: 6925012 Change-Id: I375de581a63f4f36667894c56a34a9dd45361e8f
* | | Allow adb to listen both on usb and tcp.Mike J. Chen2012-08-091-11/+15
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | (cherry picked from commit ae868a40459a6bcb89d8a4426503fea0c8002b25 in master) Change-Id: I980c7c5e8affbc8627d17b1d9303b002adcdb29a Signed-off-by: Mike J. Chen <mjchen@google.com> Conflicts: adb/adb.c
* | | am 7accfc2f: am f889f0db: Merge "Trivial signed/unsigned warning fix for adbd"Stephen Hines2012-08-081-1/+1
|\ \ \ | |/ / | | | | | | | | | * commit '7accfc2ffd3d0fb6e6e8985349e8773f1977df59': Trivial signed/unsigned warning fix for adbd
| * | Trivial signed/unsigned warning fix for adbdEdwin Vane2012-08-021-1/+1
| | | | | | | | | | | | | | | | | | Change-Id: Icd674006bb2b526166960b4f90eb274030d80439 Author: Edwin Vane <edwin.vane@intel.com> Reviewed-by: Ariel J Bernal <ariel.j.bernal@intel.com>
| * | Fix signed/unsigned comparison warningEdwin Vane2012-08-011-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | Trivial warning fix. Change-Id: I93b905b34155214fc2d211a0d9319f06b67fa193 Author: Edwin Vane <edwin.vane@intel.com> Reviewed-by: Ariel J Bernal <ariel.j.bernal@intel.com>
* | | am d4725517: am ec7d9dc7: Merge "Avoid zombies on androidscreencast"Colin Cross2012-07-231-0/+5
|\ \ \ | |/ / | | | | | | | | | * commit 'd47255175ede1af31aee9132914e5d14549ba577': Avoid zombies on androidscreencast
| * | Avoid zombies on androidscreencastYuriy Zabroda2012-07-231-0/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When using a third party screen capture program called androidscreencast (http://code.google.com/p/androidscreencast/) to get the framebuffer of the device, there are tons of screencap zombie processes got left behind. The issue is also mentioned here: http://code.google.com/p/android/issues/detail?id=22836. The cause of the issue is that adbd spawns off screencap processes, and these child processes were not waited to be finished. This change fixes the issue. Change-Id: Ife928d65ecf6a2ff39b8b72ddba930fda6733a00 Signed-off-by: Yuriy Zabroda <yuriy.zabroda@ti.com>
* | | Add Kobo's USB vendor ID to adbDan Zhang2012-07-091-0/+3
| | | | | | | | | | | | Change-Id: I8b86a851e6478d5e8248df4f1e53f3da4dc4b5e0
* | | am 504dccec: am aeceb517: adb: Fix adb tcpip commandBenoit Goby2012-06-121-3/+3
|\ \ \ | |/ / | | | | | | | | | * commit '504dccec97c12283f348838ba0bf88536322ee6b': adb: Fix adb tcpip command
| * | am aeceb517: adb: Fix adb tcpip commandBenoit Goby2012-06-121-3/+3
| |\ \ | | | | | | | | | | | | | | | | * commit 'aeceb5174502659cb4fff6de924b54ef7e6cdae7': adb: Fix adb tcpip command
| | * | adb: Fix adb tcpip commandBenoit Goby2012-06-121-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When running "adb tcpip 5555", adb create a service socket named "tcpip:5555". Only compare the 6 first chars "tcpip:" to decide if we enable exit_on_close. Bug: 6650130 Change-Id: I0835973de044f1cfde0e859ff0277c0ccc2630a3
* | | | Merge "FunctionFS: initial implementation"Benoit Goby2012-06-063-17/+364
|\ \ \ \
| * | | | FunctionFS: initial implementationAndrzej Pietrasiewicz2012-05-313-17/+364
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is the second version of a patch which demonstrates the possibility of using adbd (Android Debug Bridge daemon) with a generic FunctionFS gadget instead of a custom adb usb gadget in the Linux kernel. It contains changes introduced after Benoit's review - thank you Benoit. The patch adds a new usb access layer to adbd using FunctionFS. The former usb access method is still available. The method is chosen at runtime depending if /dev/usb-ffs/adb/ep0 or /dev/android_adb is accessible. How to use on the target device: $ insmod g_ffs.ko idVendor=<vendor ID> iSerialNumber=<some string> $ mount -t functionfs adb /dev/usb-ffs/adb -o uid=2000,gid=2000 $ ./adbd This patch requires a patch to bionic which adds <linux/usb_functionfs.h> which is an exact copy of the relevant file in the linux kernel. Change-Id: I4b42eb267ffa50fca7a5fba46f388a2f083e8b2d Signed-off-by: Andrzej Pietrasiewicz <andrzej.p@samsung.com> Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com> [benoit@android.com: detect at runtime if functionfs is mounted or fallback using f_adb] Signed-off-by: Benoit Goby <benoit@android.com>
* | | | | am 1b7a7e81: adb: Use bionic\'s strtok_r() for WindowsScott Anderson2012-06-053-2/+89
|\ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | * commit '1b7a7e81195ff06a7482f81cb92b094bb3481cb1': adb: Use bionic's strtok_r() for Windows
| * | | | | adb: Use bionic's strtok_r() for WindowsScott Anderson2012-06-053-2/+89
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | A recent change use strtok_r which broke the Windows build. Clear this potential landmine by adding adb_strtok_r to sysdeps.h in the typical fashion. For Windows, the actual implementation in sysdeps_win32.c was copied from bionic/libc/string/strtok.c. Change-Id: Ibb71555bc429f7058c07c3d39e0b62859c79635c Signed-off-by: Scott Anderson <saa@android.com>
* | | | | | am 2ca3e6b3: adb: Generalizing -s to take qualifiers.Scott Anderson2012-06-055-27/+126
|\ \ \ \ \ \ | |/ / / / / | | | | | | | | | | | | | | | | | | * commit '2ca3e6b35f79136418ebc32fef57580698dbd045': adb: Generalizing -s to take qualifiers.
| * | | | | adb: Generalizing -s to take qualifiers.Scott Anderson2012-06-055-27/+126
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Prior to this change, -s could take either a serial number or a device path (e.g. "-s 01498B1F02015015" or "-s usb:1-4.2"). This change extends -s to also allow product, model or device names (e.g. "-s product:mysid"). These new qualifiers will only be available on devices that are running an adb daemon that provides properties in the connect message per Change-Id: I09200decde4facb8fc9b4056fdae910155f2bcb9 The product, model and device are derived from the ro.product.name, ro.product.model and ro.product.device properties respectively. They are prefixed with "product:", "model:" or "device:" as appropriate. In addition, any non-alphanumerics in the model are changed to underscores. If the -s parameter matches multiple devices, the result will be the same as when multiple devices are connected but no -d, -e or -s option is specified. In general, this means the user will get "error: more than one device". However for get-state, get-devpath and get-serialno, they will get "unknown". The format of "devices -l" was changed to list all of the qualifiers that are available. The following example output (with the last digits of the serial numbers replaced with X's) is with a Galaxy Prime with an older adb daemon and another Galaxy Prime and Galaxy S both with the enhanced adb daemons: List of devices attached 016B75D60A0060XX device usb:2-5 product:mysid model:Galaxy_Nexus device:toro 3731B535FAC200XX device usb:1-4.2 product:soju model:Nexus_S device:crespo 01498B1F020150XX device usb:1-4.1 Note that the serial number and state are now column oriented instead of tab delimited. After the serial number and state, all qualifiers are listed with each preceded by a space. The output of the original devices command (without -l) is unchanged. Change-Id: Iceeb2789874effc25a630d514a375d6f1889dc56 Signed-off-by: Scott Anderson <saa@android.com>
* | | | | | am e82c2db0: adb: Transmit key properties in banner of connect messageScott Anderson2012-06-054-22/+89
|\ \ \ \ \ \ | |/ / / / / | | | | | | | | | | | | | | | | | | * commit 'e82c2db05cae70a0490a1f84b7211ef42c329671': adb: Transmit key properties in banner of connect message