Skip to main content

Old j2se/make/tools/crypto/sec-bin.zip in jdk7 b12

No replies
jdostert
Offline
Joined: 2006-05-21

Hi,

with jdk7 b12, I run into the following error:

gnumake[3]: Entering directory `/usr/sap/BUILD/d034648/p4/bas2/j2se/17_adapted/j2se/make/sun/security/jgss'
# Java sources to be compiled: (listed in file /priv/tmp/dol_b12/tmp/sun/sun.security.jgss/.classes.list)
../../../../src/share/classes/sun/security/jgss/krb5/InitSecContextToken.java
# Running javac:
/priv/d034648/jdk1.6.0//bin/javac -J-XX:ThreadStackSize=768 -J-client -J-Xmx512m -J-Xms256m -classpath /priv/tmp/dol_b12/classes -bootclasspath /priv/tmp/dol_b12/lib/jce.jar -sourcepath /priv/tmp/dol_b12/gensrc:../../../../src/solaris/classes:../../../../src/share/classes:../../../../src/closed/solaris/classes:../../../../src/closed/share/classes -d /priv/tmp/dol_b12/classes -encoding ascii -g -source 1.5 -target 5 @/priv/tmp/dol_b12/tmp/sun/sun.security.jgss/.classes.list
../../../../src/share/classes/sun/security/jgss/krb5/InitSecContextToken.java:103: cannot find symbol
symbol : constructor KrbApReq(byte[],sun.security.krb5.EncryptionKey[],java.net.InetAddress)
location: class sun.security.krb5.KrbApReq
apReq = new KrbApReq(apReqBytes, keys, addr);
^
1 error
gnumake[3]: *** [.compile.classlist] Error 1
gnumake[3]: Leaving directory `/usr/sap/BUILD/d034648/p4/bas2/j2se/17_adapted/j2se/make/sun/security/jgss'
gnumake[2]: *** [build] Error 1
gnumake[2]: Leaving directory `/usr/sap/BUILD/d034648/p4/bas2/j2se/17_adapted/j2se/make/sun/security'
gnumake[1]: *** [build] Error 1
gnumake[1]: Leaving directory `/usr/sap/BUILD/d034648/p4/bas2/j2se/17_adapted/j2se/make/sun'
gnumake: *** [sun] Error 2
gnumake: Leaving directory `/usr/sap/BUILD/d034648/p4/bas2/j2se/17_adapted/control/sap'
EXITCODE 2

In jdk7 b12, the file InitSecContextToken.java has been changed that it uses a different constructor for KrbApReq

p4 diff //bas2/j2se/17/j2se/src/share/classes/sun/security/jgss/krb5/InitSecContextToken.java

@@ -94,7 +95,12 @@
byte[] apReqBytes =
new sun.security.util.DerValue(is).toByteArray();
//debug("=====ApReqBytes: [" + getHexBytes(apReqBytes) + "]\n");
- apReq = new KrbApReq(apReqBytes, keys);
+
+ InetAddress addr = null;
+ if (context.getChannelBinding() != null) {
+ addr = context.getChannelBinding().getInitiatorAddress();
+ }
+ apReq = new KrbApReq(apReqBytes, keys, addr);
//debug("\nReceived AP-REQ and authenticated it.\n");

EncryptionKey sessionKey

The class sun.security.krb5.KrbApReq is part of j2se/make/tools/crypto/sec-bin.zip.
The version of sec-bin.zip shipped with jdk7 b12 does not contain a sun.security.krb5.KrbApReq with the required constructor.

d034648@ls3246:/tmp/sec-zip> /priv/d034648/jdk1.6.0/bin/javap sun.security.krb5.KrbApReq
Compiled from "KrbApReq.java"
public class sun.security.krb5.KrbApReq extends java.lang.Object{
public sun.security.krb5.KrbApReq(sun.security.krb5.Credentials, boolean, boolean, boolean, sun.security.krb5.Checksum) throws sun.security.krb5.Asn1Exception, sun.security.krb5.KrbCryptoException, sun.security.krb5.KrbException, java.io.IOException;
public sun.security.krb5.KrbApReq(byte[], sun.security.krb5.EncryptionKey[]) throws sun.security.krb5.KrbException, java.io.IOException;
sun.security.krb5.KrbApReq(sun.security.krb5.internal.APOptions, sun.security.krb5.internal.Ticket, sun.security.krb5.EncryptionKey, sun.security.krb5.Realm, sun.security.krb5.PrincipalName, sun.security.krb5.Checksum, sun.security.krb5.internal.KerberosTime, sun.security.krb5.EncryptionKey, sun.security.krb5.internal.SeqNumber, sun.security.krb5.internal.AuthorizationData) throws sun.security.krb5.Asn1Exception, java.io.IOException, sun.security.krb5.internal.KdcErrException, sun.security.krb5.KrbCryptoException;
void decode() throws sun.security.krb5.KrbException, java.io.IOException;
void decode(sun.security.util.DerValue) throws sun.security.krb5.KrbException, java.io.IOException;
public sun.security.krb5.Credentials getCreds();
sun.security.krb5.internal.KerberosTime getCtime();
int cusec();
sun.security.krb5.internal.APOptions getAPOptions() throws sun.security.krb5.KrbException, java.io.IOException;
public boolean getMutualAuthRequired() throws sun.security.krb5.KrbException, java.io.IOException;
boolean useSessionKey() throws sun.security.krb5.KrbException, java.io.IOException;
public sun.security.krb5.EncryptionKey getSubKey();
public java.lang.Integer getSeqNumber();
public sun.security.krb5.Checksum getChecksum();
public byte[] getMessage();
public sun.security.krb5.PrincipalName getClient();
static {};
}

Regards,
Jan