使用 JRun/ColdFusion 在 HTTPS(对于混合 HTTPS/HTTP 站点)时设置安全 cookie

发布于 2024-07-25 02:23:36 字数 387 浏览 4 评论 0原文

我们有一个在 CF7 上运行的站点,该站点具有登录和注销部分,并使用 jsessionid 进行会话。

当切换到 HTTPS(对于安全部分)时,我们需要启动一个新的安全会话,在 jsessionid cookie 上设置“安全”标志。

虽然 JRun 有一个设置“安全”的选项,但这似乎是一个要么全有要么全无的交易。

有没有办法在 HTTPS 模式下始终使用安全?


相关问题:为所有 cookie 设置 HttpOnly 标志 >

We have a site running on CF7 that has both logged in and logged out sections, and uses jsessionid for sessions.

When switching to HTTPS (for the secure sections), we need to start a new secure session, setting the 'Secure' flag on the jsessionid cookie.

Whilst JRun has an option for setting 'Secure' it appears to be an all-or-nothing deal.

Is there a way to always use Secure when in HTTPS mode?

Related Question: Setting HttpOnly flag for all cookies.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

久隐师 2024-08-01 02:23:36

这个解释看起来很彻底。 出于某种原因,这并不是一件小事。

12robots.com 使 JSESSIONID 会话令牌 Cookie 安全且仅 HTTP 并设置其 PATH

This explanation seems quite thorough. For some reason, it is not trivial.

12robots.com Making the JSESSIONID Session Token Cookie SECURE and HTTPOnly and settings its PATH

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文