I want to know if it's possible to telnet on a certain port of an Android phone connected via USB. I've seen that if I telnet localhost:5556, I go to the emulator.
Could I do something similar when I connect a physical device? Which commands could be handled?
Open the Google Play Store from your Android device. Search for telnet ssh client. Locate and tap the entry for Telnet / SSH Simple Client (by Advanced Planning Corp) Tap Install.
If you have Android Device Bridge, a simple adb shell should give you access to a command line. EDIT: I have not tested this, but you may check /system/bin for "telnetd". Try running this and then typing "netstat". You should receive an IP address from netstat, and may be able to telnet to that IP address.
SSH lets you completely control your Android over WiFi. You can issue commands like ls, mkdir, find, etc. Though, to take full advantage of this, you'll have to be familiar with the terminal command. Moreover, SSH lets you transfer files securely to your Android device.
Mobile Telnet for Android This is free Android Telnet app which is based on opensource Putty Telnet as its backend library. Inspired by opensource community and in the hope of extending usage of Putty Telnet on Android devices, the Mobile Telnet was created.
Well, adb shell
is the way to connect to the terminal. You can actually telnet
to any port you want on the device, there just needs to be an application listening to that port. I don't believe the devices provide the same functionality that the emulator does as that would allow malicious users to do a number of things. Also, the functionality provided over telnet with the emulators is designed to provide development functionality to overcome the limitation of not being on a physical device (port forwarding, etc) .I'm not sure what the goal is, but you could create an application that supports telnet and bound to a specific port on the device if you wanted to.
In your android phone,you should have a terminal.apk(app) or some other terminal application installed. You also need busybox(app), and i assume you have already rooted your android device. open it,type the commands as follows:
su
busybox telnetd -l /system/bin/sh
Now on your client machhine side type command as follows:
adb forward tcp:6000 tcp:23
telnet 127.0.0.1 6000
~~there you go
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With