geronimo-scm mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From a..@apache.org
Subject cvs commit: incubator-geronimo/modules/core/src/java/org/apache/geronimo/security SecurityService.java
Date Sun, 04 Jan 2004 22:59:34 GMT
adc         2004/01/04 14:59:34

  Modified:    modules/core/src/java/org/apache/geronimo/security
                        SecurityService.java
  Log:
  Set the PolicyConfigurationFactory.
  
  Revision  Changes    Path
  1.6       +20 -1     incubator-geronimo/modules/core/src/java/org/apache/geronimo/security/SecurityService.java
  
  Index: SecurityService.java
  ===================================================================
  RCS file: /home/cvs/incubator-geronimo/modules/core/src/java/org/apache/geronimo/security/SecurityService.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -r1.5 -r1.6
  --- SecurityService.java	2 Jan 2004 04:31:44 -0000	1.5
  +++ SecurityService.java	4 Jan 2004 22:59:34 -0000	1.6
  @@ -70,6 +70,7 @@
   import org.apache.geronimo.kernel.service.GeronimoMBeanInfo;
   import org.apache.geronimo.kernel.service.GeronimoOperationInfo;
   import org.apache.geronimo.kernel.service.GeronimoParameterInfo;
  +import org.apache.geronimo.kernel.service.GeronimoAttributeInfo;
   import org.apache.geronimo.security.util.ConfigurationUtil;
   
   
  @@ -83,6 +84,7 @@
   
       private final Log log = LogFactory.getLog(SecurityService.class);
   
  +    private String policyConfigurationFactory;
       private Collection realms = Collections.EMPTY_SET;
       private Collection ejbModuleConfigurations = Collections.EMPTY_SET;
       private Collection webModuleConfigurations = Collections.EMPTY_SET;
  @@ -110,9 +112,16 @@
                       new GeronimoParameterInfo("remove", Boolean.TYPE, "")},
                   GeronimoOperationInfo.ACTION_INFO,
                   "Get security configuration for web module identified by contextID"));
  +
  +        mbeanInfo.addAttributeInfo(new GeronimoAttributeInfo("PolicyConfigurationFactory",
  +                                                             true, true,
  +                                                             "The PolicyConfigurationFactory
to use",
  +                                                             (Object)"org.apache.geronimo.security.GeronimoPolicyConfigurationFactory"));
  +
           mbeanInfo.addEndpoint(new GeronimoMBeanEndpoint("Realms", SecurityRealm.class,
ObjectName.getInstance(SecurityRealm.BASE_OBJECT_NAME + ",*")));
           mbeanInfo.addEndpoint(new GeronimoMBeanEndpoint("EJBModuleConfigurations", EJBModuleConfiguration.class,
ObjectName.getInstance(EJBModuleConfiguration.BASE_OBJECT_NAME + ",*")));
           mbeanInfo.addEndpoint(new GeronimoMBeanEndpoint("WebModuleConfigurations", WebModuleConfiguration.class,
ObjectName.getInstance(WebModuleConfiguration.BASE_OBJECT_NAME + ",*")));
  +
           return mbeanInfo;
       }
   
  @@ -137,6 +146,16 @@
   
               throw (IllegalStateException)new IllegalStateException().initCause(pce);
           }
  +    }
  +
  +    public String getPolicyConfigurationFactory() {
  +        return policyConfigurationFactory;
  +    }
  +
  +    public void setPolicyConfigurationFactory(String policyConfigurationFactory) {
  +        this.policyConfigurationFactory = policyConfigurationFactory;
  +
  +        System.setProperty("javax.security.jacc.PolicyConfigurationFactory.provider", policyConfigurationFactory);
       }
   
       /**
  
  
  

Mime
View raw message