synchronized void updateAuthServiceGlobals(ServiceSchemaManager scm) throws Exception {
  ServiceSchema schema=scm.getOrganizationSchema();
  Map attrs=schema.getAttributeDefaults();
  schema=scm.getGlobalSchema();
  attrs.putAll(schema.getAttributeDefaults());
  if (debug.messageEnabled()) {
    debug.message("attrs : " + attrs);
  }
  adminAuthModule=CollectionHelper.getMapAttr(attrs,ISAuthConstants.ADMIN_AUTH_MODULE);
  defaultAuthLevel=CollectionHelper.getMapAttr(attrs,ISAuthConstants.DEFAULT_AUTH_LEVEL,DEFAULT_AUTH_LEVEL);
  Set s=(Set)attrs.get(ISAuthConstants.AUTHENTICATORS);
  for (  final Object value : s) {
    String name=(String)value;
    int dot=name.lastIndexOf('.');
    if (dot > -1) {
      String tmp=name.substring(dot + 1,name.length());
      authMethods.put(tmp,name);
    }
 else {
      authMethods.put(name,name);
    }
  }
  if (debug.messageEnabled()) {
    debug.message("AM.update authMethods = " + authMethods.toString());
  }
  defaultSuccessURLSet=(Set)attrs.get(ISAuthConstants.LOGIN_SUCCESS_URL);
  defaultFailureURLSet=(Set)attrs.get(ISAuthConstants.LOGIN_FAILURE_URL);
  if (debug.messageEnabled()) {
    debug.message("Default Success URL Set = " + defaultSuccessURLSet);
    debug.message("Default Failure URL Set = " + defaultFailureURLSet);
  }
  Integer sleepTime=new Integer(CollectionHelper.getMapAttr(attrs,ISAuthConstants.SLEEP_INTERVAL));
  defaultSleepTime=sleepTime.longValue();
}

synchronized void updateAuthServiceGlobals ( ServiceSchemaManager scm ) throws Exception { ServiceSchema schema = scm . getOrganizationSchema ( ) ; Map attrs = schema . getAttributeDefaults ( ) ; schema = scm . getGlobalSchema ( ) ; attrs . putAll ( schema . getAttributeDefaults ( ) ) ; if ( debug . messageEnabled ( ) ) { debug . message ( "attrs : " + attrs ) ; } adminAuthModule = CollectionHelper . getMapAttr ( attrs , ISAuthConstants . ADMIN_AUTH_MODULE ) ; defaultAuthLevel = CollectionHelper . getMapAttr ( attrs , ISAuthConstants . DEFAULT_AUTH_LEVEL , DEFAULT_AUTH_LEVEL ) ; Set s = ( Set ) attrs . get ( ISAuthConstants . AUTHENTICATORS ) ; for ( final Object value : s ) { String name = ( String ) value ; int dot = name . lastIndexOf ( '.' ) ; if ( dot > - 1 ) { String tmp = name . substring ( dot + 1 , name . length ( ) ) ; authMethods . put ( tmp , name ) ; } else { authMethods . put ( name , name ) ; } } if ( debug . messageEnabled ( ) ) { debug . message ( "AM.update authMethods = " + authMethods . toString ( ) ) ; } defaultSuccessURLSet = ( Set ) attrs . get ( ISAuthConstants . LOGIN_SUCCESS_URL ) ; defaultFailureURLSet = ( Set ) attrs . get ( ISAuthConstants . LOGIN_FAILURE_URL ) ; if ( debug . messageEnabled ( ) ) { debug . message ( "Default Success URL Set = " + defaultSuccessURLSet ) ; debug . message ( "Default Failure URL Set = " + defaultFailureURLSet ) ; } Integer sleepTime = new Integer ( CollectionHelper . getMapAttr ( attrs , ISAuthConstants . SLEEP_INTERVAL ) ) ; defaultSleepTime = sleepTime . longValue ( ) ; }
update the authservice global and organization settings . most of the code is moved in from authenticatormanager . java .
