http://qs321.pair.com?node_id=164759


in reply to Embedding cookies in HTTP requests

$ perldoc lwpcook [...] COOKIES Some sites like to play games with cookies. By default LWP ignores cookies provided by the servers it visits. LWP will collect cookies and respond to cookie requests if you set up a cookie jar. use LWP::UserAgent; use HTTP::Cookies; $ua = LWP::UserAgent->new; $ua->cookie_jar(HTTP::Cookies->new(file => "lwpcookies.txt", autosave => 1)); # and then send requests just as you used to do $res = $ua->request(HTTP::Request->new(GET => "http://www.yah +oo.no")); print $res->status_line, "\n"; [...]

Looks rather complete and simple to me. HTTP::Cookies is also well documented.