-
Notifications
You must be signed in to change notification settings - Fork 1.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
EE10 Unable to use Cookie attributes with HttpServletResponse.addCookie(jakarta.servlet.http.Cookie)
#10227
Labels
Bug
For general bugs on Jetty side
Comments
Can you show your code? |
Never mind. I was able to replicate with ... HttpServlet testServlet = new HttpServlet()
{
@Override
protected void doGet(HttpServletRequest req, HttpServletResponse resp) throws ServletException, IOException
{
resp.setCharacterEncoding("utf-8");
resp.setContentType("text/plain");
Cookie cookie = new Cookie("key", "foo");
cookie.setAttribute("SameSite", "Lax");
resp.addCookie(cookie);
resp.getWriter().println("hello");
}
}; PR incoming. |
HttpServletResponse.addCookie(jakarta.servlet.http.Cookie)
joakime
added a commit
that referenced
this issue
Aug 4, 2023
Opened PR #10228 |
Merged PR #10228 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Jetty version(s)
12 Beta 4
Description
While trying to use Cookie.setAttribute("SameSite",...) without any success I figured out that HttpCookieFacade.getAttributes() always returns Collections.emptyMap() instead of delegating it to the underlying Cookie instance.
The text was updated successfully, but these errors were encountered: