LegacyCookieSupport.maybeQuote(header, cookie.getDomain()); if (cookie.isSecure()) { header.append("; secure");
header.append("; Discard"); if (cookie.isSecure()) { header.append("; Secure");
header.append("; Discard"); if (cookie.isSecure()) { header.append("; Secure");
c.setPath(cookie.getPath()); c.setSecure(cookie.isSecure()); c.setVersion(cookie.getVersion()); value[i++] = c;
header.append("; Discard"); if (cookie.isSecure()) { header.append("; Secure");
LegacyCookieSupport.maybeQuote(header, cookie.getDomain()); if (cookie.isSecure()) { header.append("; secure");
LegacyCookieSupport.maybeQuote(header, cookie.getDomain()); if (cookie.isSecure()) { header.append("; secure");
header.append("; Discard"); if (cookie.isSecure()) { header.append("; Secure");
header.append("; Discard"); if (cookie.isSecure()) { header.append("; Secure");
header.append("; Discard"); if (cookie.isSecure()) { header.append("; Secure");
@Override public Collection<Cookie> getRequestCookies() { final Collection<io.undertow.server.handlers.Cookie> uCookies = exchange.getRequestCookies().values(); final List<Cookie> cookies = new ArrayList<>(uCookies.size()); for (final io.undertow.server.handlers.Cookie uCookie : uCookies) { final Cookie cookie = new Cookie(uCookie.getName(), uCookie.getValue()); cookie.setComment(uCookie.getComment()); cookie.setDomain(uCookie.getDomain()); cookie.setPath(uCookie.getPath()); cookie.setMaxAge(uCookie.getMaxAge() == null ? -1 : uCookie.getMaxAge()); cookie.setSecure(uCookie.isSecure()); cookie.setHttpOnly(uCookie.isHttpOnly()); cookies.add(cookie); } return cookies; }
static public ninja.Cookie convertUndertowCookieToNinjaCookie(@NotNull Cookie undertowCookie) { ninja.Cookie.Builder ninjaCookieBuilder = ninja.Cookie.builder(undertowCookie.getName(), undertowCookie.getValue()); if (undertowCookie.getMaxAge() != null) { ninjaCookieBuilder.setMaxAge(undertowCookie.getMaxAge()); } if (undertowCookie.getComment() != null) { ninjaCookieBuilder.setComment(undertowCookie.getComment()); } if (undertowCookie.getDomain() != null) { ninjaCookieBuilder.setDomain(undertowCookie.getDomain()); } if (undertowCookie.getPath() != null) { ninjaCookieBuilder.setPath(undertowCookie.getPath()); } ninjaCookieBuilder.setHttpOnly(undertowCookie.isHttpOnly()); ninjaCookieBuilder.setSecure(undertowCookie.isSecure()); // TODO: discard, version, and expires??? return ninjaCookieBuilder.build(); }
public static H.Cookie undertow2osgl(Cookie uc) { H.Cookie c = new H.Cookie(uc.getName(), uc.getValue()); c.domain(uc.getDomain()).httpOnly(uc.isHttpOnly()) .path(uc.getPath()).secure(uc.isSecure()) .version(uc.getVersion()).comment(uc.getComment()); Integer maxAge = uc.getMaxAge(); if (null != maxAge) { c.maxAge(maxAge); } Date exp = uc.getExpires(); if (null != exp) { c.expires(exp); } return c; }
public static H.Cookie undertow2osgl(Cookie uc) { H.Cookie c = new H.Cookie(uc.getName(), uc.getValue()); c.domain(uc.getDomain()).httpOnly(uc.isHttpOnly()) .path(uc.getPath()).secure(uc.isSecure()) .version(uc.getVersion()).comment(uc.getComment()); Integer maxAge = uc.getMaxAge(); if (null != maxAge) { c.maxAge(maxAge); } Date exp = uc.getExpires(); if (null != exp) { c.expires(exp); } return c; }