环境
1.2
要求
用户输入所需的应用程序地址。Siteminder拦截并询问用户名和密码。客户端提供凭据。客户端使用应用程序并单击“注销/退出”按钮。应用程序破坏会话并将302重定向到相同的应用程序地址,Siteminder应该再次拦截。
问题
我正在尝试从从siteminder登录的richfaces应用程序中注销。注销后,它将返回应用程序的主页,而不是siteminder的登录页面。似乎它正在扼杀应用程序会话,而不是siteminder会话。有办法注销siteminder吗?
代码
public String logout() {
ExternalContext ec = FacesContext.getCurrentInstance().getExternalContext();
HttpSession session = (HttpSession)ec.getSession(false);
if (session != null) {
session.invalidate();
}
try {
String redirectPath = "https://abcd.xyz.com/context/start.jsf";
ec.redirect(redirectPath);
} catch (IOException e) {
e.printStackTrace();
}
return null;日志
com.ibm.ws.webcontainer.servlet.ServletWrapper doDestroy SRVE0253I主机名uri:摧毁成功。com.ibm.ws.webcontainer.servlet.ServletWrapper init SRVE0242I主机名:初始化成功。
发布于 2012-07-03 16:58:20
如果头文件中的SM_USER值为空/空,则使用servletfilter中的以下代码强制进行重定向。
if(servletPath.trim().equals("/login/logout.do")){
log.debug("User Logged Out. Redirecting to " + contextPath + homeLink);
RequestDispatcher rd = request.getRequestDispatcher(homeLink);
rd.forward(request, response);
return;
} 发布于 2015-08-18 16:10:38
您需要更新承载应用程序的Web代理的代理配置对象(ACO)。LogOffUri参数指示SiteMinder代理销毁SMSESSION (实际上将值设置为LOGGEDOFF)。
如果将LogOffUri ACO参数中指定的URI配置为将用户重定向回应用程序的主URL,则WebAgent将检测到SMSESSION无效,并将用户发送到登录页。
https://stackoverflow.com/questions/7937070
复制相似问题