sivag1
sivag1

Reputation: 5004

failed to authenticate to <ip> | adb wifi

When connecting a device with ADB Wireless, got failed to authenticate to <ip>

adb devices gives the device shows up as unauthorized.

Upvotes: 28

Views: 45830

Answers (6)

Jan Moln&#225;r
Jan Moln&#225;r

Reputation: 420

Sometimes it helps to restart the device and the authorization dialog appears on the next attempt (experienced on two devices this week).

Upvotes: 0

Deyan Vitanov
Deyan Vitanov

Reputation: 784

As of March 2024 (using FireTVStick lite), invoking: adb connect <ip> prompts authorization message on the Fire TV and you don't need to use USB as workaround. Once accepting it on the TV the wifi can be used directly to connect without any need of USB. Cheers

Upvotes: 0

S. Vaghar
S. Vaghar

Reputation: 191

In the {} Developer options menu item, Revoke USB debugging authorizations, and then disable and enable the USB debugging option to get dialog.

Upvotes: 0

Philip Herbert
Philip Herbert

Reputation: 4619

Solution

1 Connect device(over USB) to computer (WINDOWS).

2 Authorize adb device, so it can communicate(handshake over USB) with computer

3 Check that the device is connected

$adb devices

List of devices attached

SC8SDQWGKBT4JVS4        device

4 Change to tcpip mode

$adb tcpip 5555

restarting in TCP mode port: 5555

5 Connect device(over WIFI) to computer, make sure both are on the same network

$adb connect 192.168.1.100

connected to 192.168.1.100:5555

6 Authorize adb device, so it can communicate(handshake over WIFI) with computer

7 Check that the device is connected

$adb devices

List of devices attached

SC8SDQWGKBT4JVS4        device

192.168.1.100:5555      unauthorized

Although I authorized the device, adb is seeing things differently.

To get things working correctly, unplug device from USB because there is a connection over WIFI.

8 Kill the adb server

$adb kill-server

9 Connect again over WIFI

$adb connect 192.168.1.100

* daemon not running. starting it now on port 5037 *

* daemon started successfully *

connected to 192.168.1.100:5555

10 Finally, Check that the device is connect

$adb devices

List of devices attached

192.168.1.100:5555      device

Device is now authorized, you can start debugging over WIFI.

Upvotes: 13

penkzhou
penkzhou

Reputation: 1210

Maybe you could use the ADB WiFi(an Android App).I use it and the device showed in the Android studio is authorized(Forget to tell,I use USB connect to the Mac ,then the phone will promote a dialog to authorize the mac to debug the phone).

Upvotes: 1

sivag1
sivag1

Reputation: 5004

From Android 4.2, every ADB device needs to be authorized for a computer to connect. This is done for security. So when a USB is connected a prompt comes asking to authorize the device when USB debugging is set. But does not happen for WIFI ADB.

So the workaround is to connect the device by USB, accepting the machine always. Then when the Wireless ADB is tried, it should work.

Upvotes: 31

Related Questions