Board index » delphi » 'Black Box' telnet server

'Black Box' telnet server

Hello,
I have a following problem: there is a telnet server i need to communicate
with.
I know the serve's IP-address ... and that's it.
Basicly it's a 'black box' to me and i need to find out a way to make it
'talk' to me.

Question is what would be the first command i send when i get connected to
the server?
What should i try?

Any ideas would be highly appreciated!

Thank you,
Andrey

 

Re:'Black Box' telnet server


Quote
Andrey wrote:
> Question is what would be the first command i send when i get
> connected to the server?
> What should i try?

Telnet servers follow no specific protocol beyond the RFC describing
the method of connection and telnet option communication (which is
pretty basic, at best).  Basically however, most telnet servers have a
username and password prompt to authenticate (via cleartext), but how
this prompt is displayed can vary wildly from server to server.  You
may face a simple prompt such as--

User:

Or you might be connecting to an old-style BBS which may have a welcome
message preceding the login prompt. may in fact be using a customized
login prompt ('Enter your username or NEW:' for example), and may be
sending ANSI escape sequences (color coding sequences that look like
gibberish when viewed as text, but can be used for cursor positioning,
color changing, and so on).  If you're connecting to a device (such as
a router with local telnet configuration capabilities) you may not need
to login at all.  It all depends.

The thing to remember is that telnet is usually 100% text based (unless
there's a file transfer involved, in which case it involve binary data
transmissions) and that the data you receive is usually safe enough to
print to the screen (if a console app) or display in a terminal
emulation control (if a VCL or GUI based app).  From there you can
probably figure out how to deal with the incoming data specific to your
applications needs (assuming that your clients/customers will be
connecting to servers that behave identically to the one you're working
against for development).

Good luck.

Will

Re:'Black Box' telnet server


Some telnet servers will refuse to issue a login prompt unless some
initial option negotiation is completed first, (maybee to prevent
local echo, & hence display, of the entered password).  If you get on
connection is a funny symbol or two, (#255,blah), then you will have
to implement some sort of minimal reply to these requests/commands
from the server in order to proceed.

Rgds,
Martin

Other Threads