Purchase your Section 508 Compliance Support guide now!

Purchase your Section 508 Compliance Support guide now!

SDK - Bad version number in .class file

An error occurs trying to implement the SDK sample TrustedSignonSample.

Error Message:

[ ERROR ] CAM-AAA-0064 The function 'CAM_AAA_JniAuthProvider::Configure' failed.
CAM-AAA-0154 Unable to load the Java authentication provider class 'TrustedSignonSample'.
Bad version number in .class file


Root Cause:

This error will occur when compiling with JDK 1.6 when Cognos 8.4 is using 1.5.

Solution:

Use JDK version 1.5 to build the classes and JAR file.

Steps:

example build.bat

@echo off

rem Copyright ? 2008 Cognos ULC, an IBM Company. All Rights Reserved.
rem Cognos and the Cognos logo are trademarks of Cognos ULC (formerly Cognos Incorporated).

rem Build Java files in directory TrustedSignonSample

echo Building TrustedSignonSample

rem Build the CLASSPATH required to build Java files in the directory TrustedSignonSample

set _CLASSPATH=..\lib\CAM_AAA_CustomIF.jar;..\adapters

rem Compile Java files
D:\jdk1.5.0_11\bin\javac -classpath %_CLASSPATH% -d . *.java

rem Create jar file
D:\jdk1.5.0_11\bin\jar cfm0 CAM_AAA_TrustedSignonSample.jar MANIFEST *.class

echo done