简体   繁体   English

HttpSession.invalidate()和TCPDUMP

[英]HttpSession.invalidate() and TCPDUMP

I use TCPDUMP to track some applications' HTTP traffic, running under certain processes (IP@ + Port). 我使用TCPDUMP跟踪在某些进程(IP @ +端口)下运行的某些应用程序的HTTP通信。

When I invoke a page, TCPDUMP does indeed show the whole traffic behavior. 当我调用页面时,TCPDUMP确实显示了整个流量行为。

Even when I sign in through a Login/Password form, the generated traffic includes Set-Cookie header (JSessionID cookie). 即使当我通过“登录名/密码”表单登录时,生成的流量也包含Set-Cookie标头(JSessionID cookie)。

However, I wonder why there is no meaningful traffic when I log out; 但是,我想知道为什么注销时没有有意义的流量; namely, when the server side executes HTTPSession's invalidate() method, no meaningful HTTP information is yielded by Tomcat/Servlet Container. 也就是说,当服务器端执行HTTPSession的invalidate()方法时,Tomcat / Servlet容器不会产生有意义的HTTP信息。

How to catch the session termination in HTTP with Tomcat using TCPDUMP? 如何使用TCPDUMP在Tomcat中捕获HTTP中的会话终止?

There's nothing to see. 没什么可看的。 The session is invalidated at the server, but that doesn't generate any traffic. 该会话在服务器上无效,但这不会产生任何流量。 The next HTTP request will see the 302 response code or whatevwr it is, if there is a next request. 如果存在下一个请求,则下一个 HTTP请求将看到302响应代码或它的含义。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM