【发布时间】:2011-02-22 22:05:33
【问题描述】:
我对 Servlet 3.0 的身份验证功能有疑问:
在 Servlet v3 中使用此代码:
log.info(""+request.getUserPrincipal());
log.info(""+request.getAuthType());
log.info("===^===");
request.logout() ;
log.info(""+request.getUserPrincipal());
log.info(""+request.getAuthType());
request.authenticate(response) ;
log.info("===v===");
log.info(""+request.getUserPrincipal());
log.info(""+request.getAuthType());
我总是希望看到用户名/登录窗口,因为 logout() 函数。相反,它似乎是一种“缓存”机制,可以重新填充凭据并取消我的注销...
管理员
基础
===^===
空
空
===v===
管理员
基础
这是我的 firefox 的问题,还是我在 Servlet 代码中缺少的东西?
【问题讨论】:
标签: java security jakarta-ee java-ee-6 servlet-3.0