【发布时间】:2019-05-01 09:16:15
【问题描述】:
我正在使用具有 Servlet 3.1 的 Jetty 9.2.25。我的 web.xml 中有以下 cookie 配置
<session-config>
<cookie-config>
<http-only>true</http-only>
<secure>false</secure>
</cookie-config>
</session-config>
当我将此安全标志设置为 true 时,它正在工作。但是当我将其设置为假如上所示并访问 https 站点时,安全标志被修改为 true,我无法访问 http 站点。我不明白这是怎么回事? 这是默认行为吗? 我尝试查看 Servlet 发行说明,但没有这样的更新。
对这种行为有任何想法吗?
访问 https 时如何将安全设置为假?
提前致谢。
【问题讨论】:
标签: servlets cookies jetty session-cookies web.xml