Configuring JDBC Driver for SSO

When JDBC Driver is the client for SSO, use the DriverManager.getConnection() method, with an SSO connection property set to the Informix® service principal.

Procedure

  1. Set the DriverManager.getConnection() method with the SSO options.
    The following example illustrates valid syntax for one database URL:
    ="jdbc:informix-sqli://payroll.jkenterprises.com:9555/test:
    informixserver=ol_jk_ent1;CSM=(SSO=ol_jk_ent1@jkenterprises.com,ENC=true)";
    ENC in the database URL determines whether Generic Security Services (GSS) encryption is enabled or not. By default, the setting is ENC = true (encryption enabled).
  2. Create a login configuration file before you run the application with the following entry:
    com.sun.security.jgss.initiate {
    		com.sun.security.auth.module.Krb5LoginModule required
    		useTicketCache=true doNotPrompt=true;
    };

    See your Kerberos documentation about login modules for additional options.

  3. Provide the login configuration file with the -D option to run the application.
    The following example illustrates the format for the command, where IfmxLog.conf is the full path and name to the login configuration file and TestSso is the Java class name:
    java -Djava.security.auth.login.config=IfmxLog.conf TestSso