ignore HttpOnly as a cookie name instead of throwing exception

This commit is contained in:
Jeff Pinner 2011-11-07 12:03:34 -08:00
parent cc472c55eb
commit fae46dabf1

View File

@ -95,6 +95,11 @@ public class CookieDecoder {
Set<Cookie> cookies = new TreeSet<Cookie>();
for (; i < names.size(); i ++) {
String name = names.get(i);
// Not all user agents understand the HttpOnly attribute -- be lenient
if (CookieHeaderNames.HTTPONLY.equalsIgnoreCase(name)) {
continue;
}
String value = values.get(i);
if (value == null) {
value = "";