ASP.NET 上的 Applet 和会话超时

发布于 2024-10-05 15:25:03 字数 340 浏览 1 评论 0原文

我有一个由 ColdFusion/ASP.NET 网站提供服务的小程序。每次用户与小程序交互时,我都会请求一个小的 ASP.Net 页面(.aspx 文件)。我明白了(处理过的 html,而不是原始的 .aspx)。我以为这就是保持 ASP.NET 会话存活所需要做的全部事情,但它不起作用。会话就终止了,就好像这一切都没有发生一样。

我可以访问会话 ID,并将其作为 cookie 包含在请求中。我知道这是正确的,因为小程序还使用服务器上的服务,并且这些服务获取正确的会话对象。

我在网页请求中没有任何其他请求属性(cookie 除外)。我应该添加推荐人吗?或连接? (我认为这只是 TCP/IP 相关)。或者还有什么我应该做的吗?

I've got an applet served by an ColdFusion/ASP.NET web site. Every time the user interacts with the applet, I request a small ASP.Net page (.aspx file). I get it fine (the processed html, not the raw .aspx). I thought that was all I had to do to keep the ASP.NET session alive, but it doesn't work. The session dies just as though none of that occurred.

I have access to the session id and I include it as a cookie in the request. I know it's correct because the applet also uses services on the server and those services get the correct session object.

I don't have any other request properties (other than cookies) in the request for the web page. Should I add, maybe Referrer? or Connection? (which I thought was just TCP/IP related). Or is there something else I should do?

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

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

发布评论

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

评论(1

情感失落者 2024-10-12 15:25:03

这是我目前的理解:首先,问题不在于会话超时。这是授权超时。授权 cookie 是“表单授权票”的加密。票证包含到期时间。服务器上不保存票据副本。当票证“即将”到期(超过超时期限的一半)时,将发出新的票证,并将加密版本作为响应 cookie 发送。我没有一直在寻找那块饼干。

至少,我认为正在发生这种情况。

Here's my current understanding: First, the problem wasn't the session time out. It was the authorization time out. The authorization cookie is an encryption of a "Forms Authorization Ticket". The ticket contains the expiration time. No copy of the ticket is kept on the server. When the ticket is "about" to expire (more than half-way through the time out period), a new ticket is issued and an encrypted version is sent as a response cookie. I have not been looking for that cookie.

At least, that's what I think is happening.

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