Using telnet to determin which service is running in ruby?

K

kazaam

Hi,
how can I get the servers response-message with net::telnet? Wether dump_log nor output_log are giving them. I mean if I try something like this just in ruby:

$(sleep 1; exit) | telnet ubuntuforums.org 22
Trying 82.211.81.186...
Connected to ubuntuforums.org.
Escape character is '^]'.
SSH-2.0-OpenSSH_4.6p1 Debian-5.CAT
Connection closed by foreign host.

I get the information on this certain port is running: SSH-2.0-OpenSSH_4.6p1 Debian-5.CAT.

But the net::telnet logs don't give this information. They are just reporting: "Trying to connect to ubuntuforums.org" and "Connected to ubuntuforums.org" but not which service is running. Is there another way in ruby to get it?
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads

Net::Telnet question 1
telnet terminal issue 0
Net::Telnet 1
Connecting to Cisco device using Ruby 2
Connecting via Net::Telnet 0
Telnet question 4
using win32-service 3
Net::Telnet and SMTP 13

Members online

Forum statistics

Threads
473,767
Messages
2,569,571
Members
45,045
Latest member
DRCM

Latest Threads

Top