Repository: tomee Updated Branches: refs/heads/tomee-1.7.x ea67c41ef -> 9fcbdf922
Set Identity timeout Project: http://git-wip-us.apache.org/repos/asf/tomee/repo Commit: http://git-wip-us.apache.org/repos/asf/tomee/commit/9fcbdf92 Tree: http://git-wip-us.apache.org/repos/asf/tomee/tree/9fcbdf92 Diff: http://git-wip-us.apache.org/repos/asf/tomee/diff/9fcbdf92 Branch: refs/heads/tomee-1.7.x Commit: 9fcbdf922e6f507e01cfe88a427539ee034d068c Parents: ea67c41 Author: AndyGee <andy...@gmx.de> Authored: Fri Jul 3 14:50:06 2015 +0200 Committer: AndyGee <andy...@gmx.de> Committed: Fri Jul 3 14:50:06 2015 +0200 ---------------------------------------------------------------------- .../apache/openejb/core/security/AbstractSecurityService.java | 5 +++++ 1 file changed, 5 insertions(+) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/tomee/blob/9fcbdf92/container/openejb-core/src/main/java/org/apache/openejb/core/security/AbstractSecurityService.java ---------------------------------------------------------------------- diff --git a/container/openejb-core/src/main/java/org/apache/openejb/core/security/AbstractSecurityService.java b/container/openejb-core/src/main/java/org/apache/openejb/core/security/AbstractSecurityService.java index 0fad963..f40bf09 100644 --- a/container/openejb-core/src/main/java/org/apache/openejb/core/security/AbstractSecurityService.java +++ b/container/openejb-core/src/main/java/org/apache/openejb/core/security/AbstractSecurityService.java @@ -226,9 +226,13 @@ public abstract class AbstractSecurityService implements SecurityService<UUID>, } protected UUID registerSubject(final Subject subject, final long accessTimeout) { + final Identity identity = new Identity(subject); + identity.setTimeout(accessTimeout); + final UUID token = identity.getToken(); identities.put(token, identity); + return token; } @@ -261,6 +265,7 @@ public abstract class AbstractSecurityService implements SecurityService<UUID>, throw new LoginException("Identity is not currently logged in: " + securityIdentity); } + identity.access(); clientIdentity.set(identity); }