Using telnet to communicate with QNX Neutrino over TCP / IP in C ++

I can access the telnet server through PuTTY, which opens the terminal and allows me to send commands to retrieve data / logs and start / stop processes. I would like to start researching how to access this server through C ++ in order to automate the connection and commands for testing. Basically, I need a telnet client that can connect and authenticate itself, as well as write and read to / from the server, as if I were typing a terminal. Where to begin? I tried a couple of examples, including:

http://lists.boost.org/boost-users/att-40895/telnet.cpp

When I compile and run

./telnet 192.168.1.26 23

Nothing happens, but when I connect to the server using PuTTY, I get:

QNX Neutrino (localhost) (ttyp0)

login: root  
password:  
#  

. :
- Mac OS X 10.7.3 i686-apple-darwin11-llvm-gcc-4.2
- .
- PuTTY Windows 7, ethernet ethernet USB > TCP/IPv4: IP-, , .

+3
2
+6

API , . Telnet tcp/ip.

+1

All Articles