I know it's GeoIP for the IP location, but how is it telling the server type?

It just does a HTTP "GET /" request to that domain's webserver and looks into the response header, e.g what you get with a HEAD request:

perl -e 'use LWP::UserAgent; print LWP::UserAgent->new()->head("http:/ +/cosmicperl.com")->headers()->as_string' Connection: close Date: Mon, 11 Jun 2007 02:53:48 GMT Accept-Ranges: bytes Server: Apache/2.0.54 (Fedora) Vary: Accept-Encoding Content-Type: text/html; charset=ISO-8859-1 Client-Date: Mon, 11 Jun 2007 04:23:12 GMT Client-Peer: 213.133.65.182:80 Client-Response-Num: 1

More information is available if you exchange the head() with get() in the above one-liner. For the cert, it sends a HTTPS request and looks into what certificate is being sent; then the scripts asks some RBL database, etc.

And forgive me for being stupid but right now I can't remember how to get an IP from a domain name
See Socket, e.g.
perl -MSocket -le 'print inet_ntoa(inet_aton("cosmicperl.com"))' 213.133.65.182

--shmem

_($_=" "x(1<<5)."?\n".q·/)Oo.  G°\        /
                              /\_¯/(q    /
----------------------------  \__(m.====·.(_("always off the crowd"))."·
");sub _{s./.($e="'Itrs `mnsgdq Gdbj O`qkdq")=~y/"-y/#-z/;$e.e && print}

In reply to Re: Getting Remote server info?? by shmem
in thread Getting Remote server info?? by cosmicperl

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.