Upgraded 8.6 Java Web Generation client receives security error from z/OS server
search cancel

Upgraded 8.6 Java Web Generation client receives security error from z/OS server

book

Article ID: 381066

calendar_today

Updated On:

Products

Gen Gen - Run Time Distributed

Issue/Introduction

Gen 8.5 Web Generation application client built with Java 8 connects to successfully Mainframe (z/OS) Gen server.

However after upgrading the client to 8.6 built with Java 11 a security error occurs when connecting to the server.
After debugging the root cause seems to be due to a difference in the value returned by CFBDynamicMessageSecurityExit.class function getSecurityType i.e. the 8.5 version returns 1 and 8.6 version returns 0.

Environment

Gen Java Web Generation

Resolution

CFBDynamicMessageSecurityExit.java is a Gen Web generation user exit which can be customised.

The security value "constants" are set near the top of the file i.e.
***
    public final static byte SECURITY_NO = 0;
    public final static byte SECURITY_STANDARD = 1;
    public final static byte SECURITY_ENHANCED = 2;
***
 
The default version for both Gen 8.5 and 8.6 has the same code to return the value of SECURITY_NO (0) i.e.
***
public byte getSecurityType() throws CSUException {
    return SECURITY_NO;
}
***
 
The 8.5 version had been customised to have "return SECURITY_STANDARD;" or maybe "return 1;" to cause the same effect.
So to resolve the problem the same change needs to be done for the 8.6 version.

The Gen 8.6 versions of the exit are located as follows:
Java 8: "%Gen86%Gen\classes\com\ca\gen\exits\msgobj\cfb"
Java 11: "%Gen86%Gen\classes\java11\com\ca\gen\exits\msgobj\cfb"


DETAILED STEPS
Based on doc. page Web Generation User Exits 

1. Make the required change to the source file CFBDynamicMessageSecurityExit.java in the Gen 8.6 Java 11 directory "%Gen86%Gen\classes\java11\com\ca\gen\exits\msgobj\cfb" which for the default installation Gen 8.6 directory would be "C:\Program Files (x86)\CA\Gen86\Gen\classes\java11\com\ca\gen\exits\msgobj\cfb".

2. Start command prompt and cd to that same directory:
cd C:\Program Files (x86)\CA\Gen86\Gen\classes\java11\com\ca\gen\exits\msgobj\cfb

3. Then create a command file in that directory to set the required CLASSPATH and execute the compile to create new CFBDynamicMessageSecurityExit.class file:
set CLASSPATH=C:\Progra~2\CA\Gen86\Gen\classes\java11\csu.jar
"Java11_JDK_install\bin\javac" CFBDynamicMessageSecurityExit.java
NOTES:
8.3 format is used for the Gen directory in the CLASSPATH so not to have spaces which might cause a problem.
Double quotes are used around the javac command because spaces in the Java11_JDK_install directory name might also cause a problem.

4. Re-assemble the application and the Gen 8.6 Java 11 runtimes file genrt.jar file that is created should include the new CFBDynamicMessageSecurityExit.class file.

Additional Information