Finding verion of OS and httpd

Posted on 1998-04-09
Last Modified: 2013-12-16
If I know a machine's IP, open ports such as 23, 79, 80, 110
Is there anyway to find the machine's OS version and httpd's version legally?

Of course I don't have an account on that machine.

Is it considered hacking?

Any advice will be greatly appreciated.

Question by:yjh123
LVL 84

Expert Comment

ID: 1812970
port 23 sometimes tells you the OS version.
port 80 may tell you the httpd version.


Expert Comment

ID: 1812971 from a port scan....I remember those days.....vaguely illicit doings

    To answer your second question first, the legality of any of the actions I am going to give you is entirely dependent upon the
    sysadmin.  Odds are that nothing will happen.  However there are a number of people I know personally who widely
    prosecute  (prosecute meaning chase, not prosecute meaning legal action) anyone who even looks at their machine the wrong
    way.  The worst I could possibly see happening to you is that your account with your ISP is terminated, and you get a nasty email from
    the person who's machine's door you knocked on.

    So, here's what you do.  I'm only answering this because I used to figure out what OS various corporations ran out of curiosity.  I'm not
    liable if you use this for the Dark Side.  That being said, off we go...
    To find the OS:
    1) Telnet in to the machine on port 23.  If you're lucky, it'll print out the OS.
    For Example:
    Redhat 5.0 (Hurricane)
    Linux 2.0.32 on an Intel

    In that case, there you go.  Then, instantly log off and hope the guy doesn't go after anyone who telnets in (they really
    shouldn't...that's  just ridiculous )
    2) You can tell what type of OS a lot of times by what kind of services they're running.  If port 139 is open, the odds get better its a
    WIndows machine.  If port 514 is open, it's a lot more likely that it's a Unix machine.  None of these are absolutes though. Note that a
    strobe or other portscan IS considered an attack by many and will be prosecuted. I police that on my machine.  I have a lot of
    security  options enabled, and if someone portscans me, I nail them.  Be forewarned.
    3) If port 25 is open, telnet into that.  If it gives you a message with "Sendmail 8.8.7" in it, its a UNIX machine.  If it says "Exchange
    Server", it's probably NT.

    To find out the httpd server version, try visiting the website.  A lot of educational servers display prominently their web server of
    choice.  Or, try accessing a web page that you know does not exist. Some servers give you non-generic  404 responses that can
    display their httpd version.  Or email their webmaster and ask.  If you are genuinely curious, there's no harm in asking, is there?

    I firmly believe there's no harm in looking around....of course, emailing the administrator can't hurt either.  The worst thing they'll say is
    "No, I won't tell you", in which case you can then go try the above things.  On the other hand, if they tell you, you've saved yourself the
    time, trouble, and potential litigation.  I always tell people what systems we run if asked  (Sun UltraSparc 1 with Solaris 2.5.1, P133 with
    Slackware 2.0.33, p233 with Windows NT 4 <NT bites the big one>).  Good luck, and please don't do anything improper with this. I'd
    feel guilty.

    Best Wishes,
    Matthew Zito


Author Comment

ID: 1812972
I heard that there is a way to find httpd version by telneting

into port 80.  Anyone knows?

Accepted Solution

bw021797 earned 100 total points
ID: 1812973
If you telnet into port 80 and then type:
GET / HTTP/1.0
then press enter TWICE.
you simulate a web browser's http request for the index document for a particular ip.  Look at the beginning of the header info and you will see what type of httpd server it is as well as the version number.  The httpd version and type is always present no matter what type.  This would not be hacking since your browser does the exact thing, you just simulate its http requests.

As for the OS version, that can be hidden better.  As stated above, using a port scanner will sometimes give you clues to which OS it is running, but that is a more intrusive type of info getting.

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Let's say you need to move the data of a file system from one partition to another. This generally involves dismounting the file system, backing it up to tapes, and restoring it to a new partition. You may also copy the file system from one place to…
Introduction Regular patching is part of a system administrator's tasks. However, many patches require that the system be in single-user mode before they can be installed. A cluster patch in particular can take quite a while to apply if the machine…
Learn several ways to interact with files and get file information from the bash shell. ls lists the contents of a directory: Using the -a flag displays hidden files: Using the -l flag formats the output in a long list: The file command gives us mor…
This video shows how to set up a shell script to accept a positional parameter when called, pass that to a SQL script, accept the output from the statement back and then manipulate it in the Shell.

713 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question