Provided by: libhttp-cookiejar-perl_0.008-1_all
HTTP::CookieJar - A minimalist HTTP user agent cookie jar
use HTTP::CookieJar; my $jar = HTTP::CookieJar->new; # add cookie received from a request $jar->add( "http://www.example.com/", "CUSTOMER=WILE_E_COYOTE; Path=/; Domain=example.com" ); # extract cookie header for a given request my $cookie = $jar->cookie_header( "http://www.example.com/" );
This module implements a minimalist HTTP user agent cookie jar in conformance with RFC 6265 <http://tools.ietf.org/html/rfc6265>. Unlike the commonly used HTTP::Cookies module, this module does not require use of HTTP::Request and HTTP::Response objects. An LWP-compatible adapter is available as HTTP::CookieJar::LWP.
new my $jar = HTTP::CookieJar->new; Return a new, empty cookie jar
LIMITATIONS AND CAVEATS
RFC 6265 vs prior standards This modules adheres as closely as possible to the user-agent rules of RFC 6265. Therefore, it does not handle nor generate "Set-Cookie2" and "Cookie2" headers, implement ".local" suffixes, or do path/domain matching in accord with prior RFC's. Internationalized domain names Internationalized domain names given in requests must be properly encoded in ASCII form. Public suffixes If Mozilla::PublicSuffix is installed, cookie domains will be checked against the public suffix list. Public suffix cookies are only allowed as host-only cookies. Third-party cookies According to RFC 6265, a cookie may be accepted only if has no "Domain" attribute (in which case it is "host-only") or if the "Domain" attribute is a suffix of the request URL. This effectively prohibits Site A from setting a cookie for unrelated Site B, which is one potential third-party cookie vector.
· HTTP::Cookies · Mojo::UserAgent::CookieJar
Bugs / Feature Requests Please report any bugs or feature requests through the issue tracker at <https://github.com/dagolden/HTTP-CookieJar/issues>. You will be notified automatically of any progress on your issue. Source Code This is open source software. The code repository is available for public review and contribution under the terms of the license. <https://github.com/dagolden/HTTP-CookieJar> git clone https://github.com/dagolden/HTTP-CookieJar.git
David Golden <email@example.com>
· Dan Book <firstname.lastname@example.org> · David Golden <email@example.com>
COPYRIGHT AND LICENSE
This software is Copyright (c) 2013 by David Golden. This is free software, licensed under: The Apache License, Version 2.0, January 2004