GUACAMOLE-393: Add session invalidation hooks to AuthenticatedUser.
This commit is contained in:
1 parent
b90a989463
commit
c20457f89b
4 files changed
+20
No files matched your search
+5
@@ -136,4 +136,9 @@ public abstract class RemoteAuthenticatedUser implements AuthenticatedUser {
|
||||
return authenticationProvider;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void invalidate() {
|
||||
// Nothing to invalidate
|
||||
}
|
||||
|
||||
}
|
||||
+5
@@ -29,4 +29,9 @@ public abstract class AbstractAuthenticatedUser extends AbstractIdentifiable
|
||||
|
||||
// Prior functionality now resides within AbstractIdentifiable
|
||||
|
||||
@Override
|
||||
public void invalidate() {
|
||||
// Nothing to invalidate
|
||||
}
|
||||
|
||||
}
|
||||
@@ -49,4 +49,11 @@ public interface AuthenticatedUser extends Identifiable {
|
||||
*/
|
||||
Credentials getCredentials();
|
||||
|
||||
/**
|
||||
* Invalidates this authenticated user and their associated token such that
|
||||
* they are no longer logged in. This function will be automatically
|
||||
* invoked when the user logs out, or when their session expires.
|
||||
*/
|
||||
void invalidate();
|
||||
|
||||
}
|
||||
@@ -252,6 +252,9 @@ public class GuacamoleSession {
|
||||
}
|
||||
}
|
||||
|
||||
// Invalidate the authenticated user object
|
||||
authenticatedUser.invalidate();
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
Reference in new issue
Block a user