$ perl -MCGI::Cookie -le " print CGI::Cookie->new( qw/ -name mycookie /, -value => [qw/ foo bar /], qw/ -secure 1 -httponly 1 -expires +3M / ) " mycookie=foo&bar; path=/; expires=Thu, 10-May-2012 07:54:06 GMT; secure; HttpOnly #### $ lwp-request -USEd http://localhost/cgi-bin/httponly.cgi GET http://localhost/cgi-bin/httponly.cgi User-Agent: lwp-request/6.03 libwww-perl/6.03 200 OK Connection: close Date: Fri, 10 Feb 2012 07:59:39 GMT Server: Apache/2.0.54 (Win32) mod_ssl/2.0.54 OpenSSL/0.9.7g PHP/4.3.11 mod_perl/2.0.1 Perl/v5.8.9 Content-Type: text/html; charset=UTF-8 Client-Date: Fri, 10 Feb 2012 07:59:42 GMT Client-Peer: 127.0.0.1:80 Client-Response-Num: 1 Client-Transfer-Encoding: chunked Set-Cookie: mycookie=foo&bar; path=/; expires=Thu, 10-May-2012 07:59:41 GMT; secure; HttpOnly Title: Untitled Document