Friday, May 10, 2024
 Popular · Latest · Hot · Upcoming
3
rated 0 times [  3] [ 0]  / answers: 1 / hits: 831  / 1 Year ago, fri, december 2, 2022, 10:49:52

System Info:
Windows 7 64-bit
VirtualBox 4.2.18
Ubuntu 12.04 Guest
Apache 2 installed and running



Running HEAD / HTTP/1.0 on terminal returns server as Oversee Turing v1.0.0



Why is the server identifying itself as Oversee Turing?



There doesn't seem to be much information online except for web server stats sites.



I was wondering if there is more background info on this.



enter image description here


More From » apache2

 Answers
0

You are not querying your local server for its HEAD response. The servers you are querying is your local filesystem, file:/, for your first argument and http.com for your 2nd argument. So no worries, your Apache is not identifying itself as Oversee Turing unless you have told it to do so. Since you give two paths, do you get two responses.



It exist a lot of ways to check headers, and since that is not the question will i not cover it.



For a in depth explanation:



First, when you are giving / as the path for HEAD is it considered a local absolute path pointing to your filesystem root and will be expanded to file:/.



Second, HTTP/1.0 is considered another absolute path. To understand how argument is interpreted, we have to take a closer look in the source beneath. But summed up is the HEAD command pointing to a perl script. This perl script make use of uf_uri, a function from /usr/share/perl5/URI/Heuristic.pm to determine and return a full URI from a user friendly URI. That is done with running the function uf_uristr.



uf_uristr will match # no scheme specified at line 179 and will add schema to be http further will it expand the guess maps with the domain endings, on line 209+210 will it add .com. The different domain-endings will be tested in the for at line 215. The test will be done with gethostbyname("$guess.") and will set the $host to be the current $guess and exit the for loop if it gets a working result.



Then it will craft the URI it will return to the initial perl script on line 226;



$_ = "$scheme://$host$_";



$scheme = http
$host = http.com
$_ = /1.0


so the final $_ will be http://http.com/1.0



Source



$ ls -al /usr/bin/HEAD 
lrwxrwxrwx 1 root root 11 Nov 23 2011 /usr/bin/HEAD -> lwp-request

$ file /usr/bin/lwp-request
/usr/bin/lwp-request: a /usr/bin/perl -w script, ASCII text executable


Notice uf_uri:



vim +196 /usr/bin/lwp-request +"sp +440 /usr/bin/lwp-request"


uf_uri calls uf_uristr in /usr/share/perl5/URI/Heuristic.pm that is a part of the liburi-perl package.


[#29515] Saturday, December 3, 2022, 1 Year  [reply] [flag answer]
Only authorized users can answer the question. Please sign in first, or register a free account.
lowovey

Total Points: 287
Total Questions: 98
Total Answers: 117

Location: Bosnia and Herzegovina
Member since Thu, Jan 14, 2021
3 Years ago
;