The Server Snooper

previously published in the weekly Possibilities ezine

When you want to know what type of server your competitors use for their domains, or your friend across town, who you gonna call?

Bontrager, of course.

Simply point your browser to their http://bontragercgi.com/Server_Snooper.php web page. At the Server Snooper page, type in the URL of the domain in question.

It will generate a short report of information. Some of the information may be things you never knew was available.

It’s a great research tool, or a time waster, depending on how you look at it.

Since playing with this new tool, I’ve found that some servers provide more information than others do. Some information is consistently provided. Other information only sometimes.

You can tell whether or not a redirector is in place by typing a URL of a web page that does not exist. If the resulting information includes a 307, 302, or 301 status code, it is evidence of a redirector.

Sometimes servers will report the date a web page was last modified. (How often do your competitors update their web pages?)

With some servers, you’ll get the last modified date only for static pages. Pages containing SSI or PHP code might not be considered static, as they can be modified on the fly. If a certain server won’t report even for static pages, try typing in just the domain name. You might then get the last modified date for the default page, even though the default page file name was not provided.

Don’t know the operating system your web site is running on, and you wonder whether or not your web site can run the Master Series scripts? Simply type your domain name and see what your server reports.

If the “Server” line says Unix or Linux, or mentions a common Unix or Linux distribution, like FreeBSD or Red Hat, your site qualifies.

Developers and programmers, use this tool to see information your web pages and scripts are actually sending to web browsers.

How To Read the Server Snooper Report

For reference, we’ll use this report from the server at URL http://www.bontragercgi.com/

HTTP/1.1 200 OK  Date: Sun, 13 Aug 2006 21:27:19 GMT  Server: Apache/1.3.34 (Unix) mod_fastcgi/2.4.2 [...]  Last-Modified: Sun, 13 Aug 2006 07:18:16 GMT  ETag: "73c54a-22a3-44ded238"  Accept-Ranges: bytes  Content-Length: 8867  Connection: close Content-Type: text/html

The first line of the Server Snooper report contains the HTTP version the server is using (usually 1.0 or 1.1) and the status code of the server’s reply.

If the web page exists at the URL you provided, the status code will be “200 OK.” Some other status codes you might see are “301 Moved Permanently,” “302 Found,” “307 Temporary Redirect,” “403 Forbidden,” “404 Not Found,” “410 Gone,” and “500 Internal Server Error.”

After the first line, the rest of the lines are name/value pairs separated with a colon character.

The Date line has been on every report I’ve obtained. It is the date and time the report was provided, usually expressed in Greenwich Mean Time. While you already know what time it is, and don’t need that information, programmers can use the Server Snooper report to calculate the difference between their server’s clock time and that of the remote server.

More interesting to you, probably, is when a Last-Modified line is on the report. The date/time on that line can be subtracted from the date/time on the Date line. The result is the number of days, hours, and even seconds that have elapsed since the document was last modified.

When the above Server Snooper report was obtained, the time elapsed since the document’s last modification was 14 hours, 9 minutes, and 3 seconds.

Most, but not all, reports have a Server line. In the above Server Snooper report, the server line was cropped to fit within established ezine margins for articles.

If you’re curious what the entire Server line was, type http://www.bontragercgi.com/ at the Server Snooper page.

The Server line sometimes contains little information and sometimes a lot. Usually, there is enough information to determine what operating system the server is running on.

The ETag line, when present, is a series of characters between quotation marks that represent the latest version of the document. This can be used by software for sending conditional GETs (conditionally requesting a document). If the ETag is the same as the current document, the current document is not provided again. This can be used by RSS readers, for example, to eliminate unnecessary downloads.

Between the Accept-Ranges line and the Content-Length line, you know that the document is 8867 bytes long.

After the document was sent by the server it closed the connection (Connection line). And the type of document that was sent (the Content-Type line) is text html.

Not all possible data lines are in the above example report. As you use the Server Snooper, you’ll see others.

The Set-Cookie line, for example, reveals what cookies are set prior to a page loading. (Cookies set after a page loads will not be revealed in the Server Snooper report.)

As you now understand, the savvy snooper can sometimes find out a lot about the server any domain is hosted on.

Will Bontrager
2006

Leave a Reply

You must be logged in to post a comment.