Logout From ADF application
I implemented this method in the Action of the logout button
public String logout{
FacesContext fctx = FacesContext.getCurrentInstance();
ExternalContext ectx = fctx.getExternalContext();
HttpSession session = (HttpSession) ectx.getSession(false);
session.invalidate();
HttpServletRequest request = (HttpServletRequest)ectx.getRequest();
HttpServletResponse response = (HttpServletResponse) ectx.getResponse();
ServletAuthentication.logout(request,response,false);
try{
ectx.redirect("http://iaigc.net");
}
catch(Exception e){
e.printStackTrace();
}
fctx.responseComplete();
return null;
}
Then I changed the property of the ADF taskflow Taskflow Reentry to reentery-not-allowed to prevent the The browser back button to return to my page
public String logout{
FacesContext fctx = FacesContext.getCurrentInstance();
ExternalContext ectx = fctx.getExternalContext();
HttpSession session = (HttpSession) ectx.getSession(false);
session.invalidate();
HttpServletRequest request = (HttpServletRequest)ectx.getRequest();
HttpServletResponse response = (HttpServletResponse) ectx.getResponse();
ServletAuthentication.logout(request,response,false);
try{
ectx.redirect("http://iaigc.net");
}
catch(Exception e){
e.printStackTrace();
}
fctx.responseComplete();
return null;
}
Then I changed the property of the ADF taskflow Taskflow Reentry to reentery-not-allowed to prevent the The browser back button to return to my page
Comments