in reply to A question about HTML::TokeParser

For what you are doing, a better way might be using HTTP::Request, and steal some code from HTTP::Daemon see how it creates HTTP::Request object base on what is received.