Forum Archive

How to use telnet?

nice_guy42

Hello everybody,

I'm neither a python nor an iOS expert, but I wrote some python scripts for practicing and learning. One of my "most favorite" scripts I wrote in the past uses telnet with telnetlib. It works fine on python for PC and python for iOS. Unfortunately I could not figure out, how to use telnet with pythonista.

Can anybody help?

Thank you, best regards,
nice_guy.

ccc

Telnet was determined to be too insecure for modern Internet computing so it has been largely phased out in favor of SSH2. The paramiko module of Pythonista may be of interest.

http://omz-software.com/pythonista/docs/ios/paramiko.html

http://jessenoller.com/blog/2009/02/05/ssh-programming-with-paramiko-completely-different

nice_guy42

Thank you ccc for these interesting articles. Unfortunately it is not that easy to switch to ssh. I control some clients (home automation, lab measurement equipment) via telnet. All the traffic is exclusive in the LAN, so the risc is not that high.

Any other ideas?

ccc

Maybe the best approach would be for you to paste some telnetlib code that you want to get working on Pythonista into an anynomous gist and send us the URL. http://gist.github.com

omz

telnetlib is currently not included in Pythonista because I couldn't get it to work properly at the time. I'll include it in the next release on an experimental basis because I think that I've solved some of the underlying issues, but I'm not 100% sure that it'll work well. If you'll post your code here, I can perhaps use that for testing.

Hvmhvm227

Any news on this omz? I'm having the same situation as nice_guy, in need of telnet for home automation.