ResponseBuilder builder = Response.ok();
Subject subject = SecurityUtils.getSubject();
if (!subject.isAuthenticated())
{
builder.status(401).entity("You are currently not login .please Login
for Access Services");
} else if (subject.getSession(false) == null) {
builder.status(401).entity("Your session has expired");
} else
{
Registeration registeration=new Registeration();
boolean status=registeration.getDetails(userId,builder);
log.debug("the status is:"+status);
}
return builder.build();
--
View this message in context:
http://shiro-user.582556.n2.nabble.com/how-to-know-from-subject-that-session-had-expired-or-user-is-un-authenticate-tp7579333p7579364.html
Sent from the Shiro User mailing list archive at Nabble.com.