         DESCRIPTION VARCHAR (1024),
         ROLE_CLAIM VARCHAR (512),
         AUTH_TYPE VARCHAR (255) NOT NULL,
-            PROVISIONING_USERSTORE_DOMAIN VARCHAR (512),
-            IS_LOCAL_CLAIM_DIALECT CHAR(1) DEFAULT '1',
-            IS_SEND_LOCAL_SUBJECT_ID CHAR(1) DEFAULT '0',
-            IS_SEND_AUTH_LIST_OF_IDPS CHAR(1) DEFAULT '0',
+	    	PROVISIONING_USERSTORE_DOMAIN VARCHAR (512),
+	    	IS_LOCAL_CLAIM_DIALECT CHAR(1) DEFAULT '1',
+	    	IS_SEND_LOCAL_SUBJECT_ID CHAR(1) DEFAULT '0',
+	    	IS_SEND_AUTH_LIST_OF_IDPS CHAR(1) DEFAULT '0',
         IS_USE_TENANT_DOMAIN_SUBJECT CHAR(1) DEFAULT '1',
         IS_USE_USER_DOMAIN_SUBJECT CHAR(1) DEFAULT '1',
-            SUBJECT_CLAIM_URI VARCHAR (512),
-            IS_SAAS_APP CHAR(1) DEFAULT '0',
-            IS_DUMB_MODE CHAR(1) DEFAULT '0',
+	    	SUBJECT_CLAIM_URI VARCHAR (512),
+	    	IS_SAAS_APP CHAR(1) DEFAULT '0',
+	    	IS_DUMB_MODE CHAR(1) DEFAULT '0',
         PRIMARY KEY (ID));
 
 ALTER TABLE SP_APP ADD CONSTRAINT APPLICATION_NAME_CONSTRAINT UNIQUE(APP_NAME, TENANT_ID);

);

CREATE TABLE IF NOT EXISTS IDN_OPENID_USER_RPS (
                  USER_NAME VARCHAR(255) NOT NULL,
                  TENANT_ID INTEGER DEFAULT 0,
                  RP_URL VARCHAR(255) NOT NULL,
                  TRUSTED_ALWAYS VARCHAR(128) DEFAULT 'FALSE',
                  LAST_VISIT DATE NOT NULL,
                  VISIT_COUNT INTEGER DEFAULT 0,
                  DEFAULT_PROFILE_NAME VARCHAR(255) DEFAULT 'DEFAULT',
                  PRIMARY KEY (USER_NAME, TENANT_ID, RP_URL)
);

CREATE TABLE IF NOT EXISTS IDN_OPENID_ASSOCIATIONS (
                  HANDLE VARCHAR(255) NOT NULL,
                  ASSOC_TYPE VARCHAR(255) NOT NULL,
                  EXPIRE_IN TIMESTAMP NOT NULL,
                  MAC_KEY VARCHAR(255) NOT NULL,
                  ASSOC_STORE VARCHAR(128) DEFAULT 'SHARED',
      TENANT_ID INTEGER DEFAULT -1,
                  PRIMARY KEY (HANDLE)
);

CREATE TABLE IDN_STS_STORE (

    USERNAME VARCHAR(45),
    PASSWORD VARCHAR(255),
    CALLBACK_HOST VARCHAR (45),
    TENANT_ID INTEGER DEFAULT -1,
    PRIMARY KEY (PROFILE_NAME, TENANT_ID)
);
