public static StandaloneConfiguration getInstance() { SecurityManager sm = System.getSecurityManager(); if (sm != null) { sm.checkPermission(new RuntimePermission(StandaloneConfiguration.class.getName() + ".getInstance")); } if(_instance == null) _instance = new StandaloneConfiguration(); return _instance; }
/** * Prepare for security operations. One of the operations * that is undertaken is to establish the JAAS {@code Configuration} * that uses our xml based configuration. * @see #release() to release the configuration */ public static void prepare() { SecurityManager sm = System.getSecurityManager(); if (sm != null) { sm.checkPermission(new RuntimePermission(SecurityFactory.class.getName() + ".prepare")); } if(Configuration.getConfiguration() instanceof ApplicationPolicyRegistration == false) { standaloneConfiguration.setParentConfig(parentConfiguration); Configuration.setConfiguration(standaloneConfiguration); } }
ApplicationPolicy aPolicy = getApplicationPolicy(appName); BaseAuthenticationInfo authInfo = null; if (aPolicy != null) ApplicationPolicy defPolicy = getApplicationPolicy(SecurityConstants.DEFAULT_APPLICATION_POLICY); authInfo = defPolicy != null ? (AuthenticationInfo) defPolicy.getAuthenticationInfo() : null;
/** * Prepare for security operations. One of the operations * that is undertaken is to establish the JAAS {@code Configuration} * that uses our xml based configuration. * @see #release() to release the configuration */ public static void prepare() { SecurityManager sm = System.getSecurityManager(); if (sm != null) { sm.checkPermission(new RuntimePermission(SecurityFactory.class.getName() + ".prepare")); } if(Configuration.getConfiguration() instanceof ApplicationPolicyRegistration == false) { standaloneConfiguration.setParentConfig(parentConfiguration); Configuration.setConfiguration(standaloneConfiguration); } }