org.apache.shiro.authz.aop
Class AuthenticatedAnnotationHandler
java.lang.Object
org.apache.shiro.aop.AnnotationHandler
org.apache.shiro.authz.aop.AuthorizingAnnotationHandler
org.apache.shiro.authz.aop.AuthenticatedAnnotationHandler
public class AuthenticatedAnnotationHandler
- extends AuthorizingAnnotationHandler
Handles RequiresAuthentication annotations and ensures the calling subject is
authenticated before allowing access.
- Since:
- 0.9.0
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
AuthenticatedAnnotationHandler
public AuthenticatedAnnotationHandler()
- Default no-argument constructor that ensures this handler to process
RequiresAuthentication annotations.
assertAuthorized
public void assertAuthorized(Annotation a)
throws UnauthenticatedException
- Ensures that the calling
Subject is authenticated, and if not, throws an
UnauthenticatedException indicating the method is not allowed to be executed.
- Specified by:
assertAuthorized in class AuthorizingAnnotationHandler
- Parameters:
a - the annotation to inspect
- Throws:
UnauthenticatedException - if the calling Subject has not yet
authenticated.
Copyright © 2004-2012 The Apache Software Foundation. All Rights Reserved.