Vulnerability Development mailing list archives

thttpd-2.24


From: methodic <methodic () libpcap net>
Date: Sat, 08 Nov 2003 17:50:45 -0600

I noticed something very odd when strace'ing a thttpd..

If I issue:
perl -e 'print "GET /index.html HTTP/1.0\r\n\r\n"' | nc localhost 80
I get this:
readlink("index.html", 0xbfffd5a0, 5000) = -1 EINVAL (Invalid argument)
stat64("index.html", {st_mode=S_IFREG|0444, st_size=422, ...}) = 0

but if i take the slash out:
perl -e 'print "GET index.html HTTP/1.0\r\n\r\n"' | nc localhost 80
i get this:
read(1, "GET index.html HTTP/1.0\r\n\r\n", 500) = 27
readlink("ndex.html", 0xbfffd5a0, 5000) = -1 ENOENT (No such file or
directory)

hmm, i wonder where the first i in index.html went to? can anyone
reproduce? thoughts?

tia.


Current thread: