FileDocCategorySizeDatePackage
SecurityClientInterceptor.javaAPI DocJBoss 4.2.12402Fri Jul 13 21:02:28 BST 2007org.jboss.aspects.security

SecurityClientInterceptor

public final class SecurityClientInterceptor extends Object implements org.jboss.aop.advice.Interceptor, Serializable
The AuthenticationInterceptor authenticates the caller.
author
Bill Burke
version
$Revision: 57186 $

Fields Summary
private static final long
serialVersionUID
public static final SecurityClientInterceptor
singleton
Constructors Summary
Methods Summary
public java.lang.StringgetName()

       return "SecurityClientInterceptor"; 
public java.lang.Objectinvoke(org.jboss.aop.joinpoint.Invocation invocation)
Authenticates the caller using the principal and credentials in the Infocation if thre is a security manager and an invcocation method.

      // Get Principal and credentials 
      Principal principal = SecurityActions.getPrincipal();
      if (principal != null) invocation.getMetaData().addMetaData("security", "principal", principal);

      Object credential = SecurityActions.getCredential();
      if (credential != null) invocation.getMetaData().addMetaData("security", "credential", credential);
      
      return invocation.invokeNext();
   
java.lang.ObjectreadResolve()

      return singleton;