We need to check if the unlimited strength crypto JCE files are installed properly

Document ID : KB000013545
Last Modified Date : 14/02/2018
Show Technical Document Details
Introduction:

Sometimes during the installation of the product We are getting this error:

We are not able to install CA IDM 14.When I entered Web Server Application Information and click on NEXT It is stuck on the same screen.Attaching the screenshot of the screen 

When using the installer debug, is shows this message:

$CC_JCE_ROOT$ = D:\IBM\WebSphere\AppServer/java_1.7.1_64

Run command array: [D:\IBM\WebSphere\AppServer/java_1.7.1_64\jre\bin\java, -cp, /C:/Users/shegde_admin/AppData/Local/Temp/I1488469919/InstallerData/Execute.zip,

 

 com.netegrity.brlib.customcode.JCEStrengthReader, false] <OUT>

 

Also Somtimes during integration of IM and SM you get smjavaagentapi init -1 at startup step two.

 

 

Question:

How to test if the JCE unlimited strength crypto files have been installed properly? 

Answer:

Navigate to your JDK home folder and create a file called testUnlimitedStrength.java

Edit the file and add this to the contents:

 

          import java.security.NoSuchAlgorithmException;

          import javax.crypto.Cipher;

 

          public class testUnlimitedStrength

          {

            public static void main(final String[] args)

            {

              int strength = 0;

              try {

                strength = Cipher.getMaxAllowedKeyLength("AES");

 

                if ( strength > 2147483646 ){

                   System.out.printf("isUnlimitedSupported=TRUE Cypher Strength: ");

                   System.out.println(strength);

 

                } 

                else {

                  System.out.printf("isUnlimitedSupported=FALSE");

                  System.out.println(strength);

                }

              } 

              catch (NoSuchAlgorithmException e) {

                System.out.println("I cannot tell because I do not know AES");

              }

            }

          }

 

Save the file

From the command prompt of the jdk/bin directory run

  javac testUnlimitedStrength.java

Then from the command prompt of the jdk/bin directory run

  java testUnlimitedStrength

 

This should return: 

isUnlimitedSupported=TRUE Cypher Strength: 2147483647

Additional Information:

Common errors:

    During compile you get this or similar:

        testUnlimitedStrengthh.java:4: error: class testUnlimitedStrength is public, should be declared in a file named testUnlimitedStrength.java

    Your file name is not correct and should be testUnlimitedStrength.java