final class sun.security.ssl.DHKeyExchange$DHEPossession implements sun.security.ssl.NamedGroupPossession
minor version: 0
major version: 59
flags: flags: (0x0030) ACC_FINAL, ACC_SUPER
this_class: sun.security.ssl.DHKeyExchange$DHEPossession
super_class: java.lang.Object
{
final java.security.PrivateKey privateKey;
descriptor: Ljava/security/PrivateKey;
flags: (0x0010) ACC_FINAL
final javax.crypto.interfaces.DHPublicKey publicKey;
descriptor: Ljavax/crypto/interfaces/DHPublicKey;
flags: (0x0010) ACC_FINAL
final sun.security.ssl.NamedGroup namedGroup;
descriptor: Lsun/security/ssl/NamedGroup;
flags: (0x0010) ACC_FINAL
void <init>(sun.security.ssl.NamedGroup, java.security.SecureRandom);
descriptor: (Lsun/security/ssl/NamedGroup;Ljava/security/SecureRandom;)V
flags: (0x0000)
Code:
stack=4, locals=5, args_size=3
start local 0 start local 1 start local 2 0: aload 0
invokespecial java.lang.Object.<init>:()V
1: ldc "DiffieHellman"
invokestatic java.security.KeyPairGenerator.getInstance:(Ljava/lang/String;)Ljava/security/KeyPairGenerator;
2: astore 3
start local 3 3: aload 3
aload 1
getfield sun.security.ssl.NamedGroup.keAlgParamSpec:Ljava/security/spec/AlgorithmParameterSpec;
aload 2
invokevirtual java.security.KeyPairGenerator.initialize:(Ljava/security/spec/AlgorithmParameterSpec;Ljava/security/SecureRandom;)V
4: aload 0
aload 3
invokevirtual sun.security.ssl.DHKeyExchange$DHEPossession.generateDHKeyPair:(Ljava/security/KeyPairGenerator;)Ljava/security/KeyPair;
astore 4
start local 4 5: aload 4
ifnonnull 7
6: new java.lang.RuntimeException
dup
ldc "Could not generate DH keypair"
invokespecial java.lang.RuntimeException.<init>:(Ljava/lang/String;)V
athrow
7: StackMap locals: sun.security.ssl.DHKeyExchange$DHEPossession sun.security.ssl.NamedGroup java.security.SecureRandom java.security.KeyPairGenerator java.security.KeyPair
StackMap stack:
aload 0
aload 4
invokevirtual java.security.KeyPair.getPrivate:()Ljava/security/PrivateKey;
putfield sun.security.ssl.DHKeyExchange$DHEPossession.privateKey:Ljava/security/PrivateKey;
8: aload 0
aload 4
invokevirtual java.security.KeyPair.getPublic:()Ljava/security/PublicKey;
checkcast javax.crypto.interfaces.DHPublicKey
putfield sun.security.ssl.DHKeyExchange$DHEPossession.publicKey:Ljavax/crypto/interfaces/DHPublicKey;
end local 4 end local 3 9: goto 14
StackMap locals: sun.security.ssl.DHKeyExchange$DHEPossession sun.security.ssl.NamedGroup java.security.SecureRandom
StackMap stack: java.security.GeneralSecurityException
10: astore 3
start local 3 11: new java.lang.RuntimeException
dup
12: ldc "Could not generate DH keypair"
aload 3
13: invokespecial java.lang.RuntimeException.<init>:(Ljava/lang/String;Ljava/lang/Throwable;)V
athrow
end local 3 14: StackMap locals:
StackMap stack:
aload 0
aload 1
putfield sun.security.ssl.DHKeyExchange$DHEPossession.namedGroup:Lsun/security/ssl/NamedGroup;
15: return
end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 16 0 this Lsun/security/ssl/DHKeyExchange$DHEPossession;
0 16 1 namedGroup Lsun/security/ssl/NamedGroup;
0 16 2 random Ljava/security/SecureRandom;
3 9 3 kpg Ljava/security/KeyPairGenerator;
5 9 4 kp Ljava/security/KeyPair;
11 14 3 gse Ljava/security/GeneralSecurityException;
Exception table:
from to target type
1 9 10 Class java.security.GeneralSecurityException
MethodParameters:
Name Flags
namedGroup
random
void <init>(int, java.security.SecureRandom);
descriptor: (ILjava/security/SecureRandom;)V
flags: (0x0000)
Code:
stack=5, locals=6, args_size=3
start local 0 start local 1 start local 2 0: aload 0
invokespecial java.lang.Object.<init>:()V
1: getstatic sun.security.ssl.PredefinedDHParameterSpecs.definedParams:Ljava/util/Map;
iload 1
invokestatic java.lang.Integer.valueOf:(I)Ljava/lang/Integer;
invokeinterface java.util.Map.get:(Ljava/lang/Object;)Ljava/lang/Object;
checkcast javax.crypto.spec.DHParameterSpec
2: astore 3
start local 3 3: ldc "DiffieHellman"
invokestatic java.security.KeyPairGenerator.getInstance:(Ljava/lang/String;)Ljava/security/KeyPairGenerator;
4: astore 4
start local 4 5: aload 3
ifnull 8
6: aload 4
aload 3
aload 2
invokevirtual java.security.KeyPairGenerator.initialize:(Ljava/security/spec/AlgorithmParameterSpec;Ljava/security/SecureRandom;)V
7: goto 9
8: StackMap locals: sun.security.ssl.DHKeyExchange$DHEPossession int java.security.SecureRandom javax.crypto.spec.DHParameterSpec java.security.KeyPairGenerator
StackMap stack:
aload 4
iload 1
aload 2
invokevirtual java.security.KeyPairGenerator.initialize:(ILjava/security/SecureRandom;)V
9: StackMap locals:
StackMap stack:
aload 0
aload 4
invokevirtual sun.security.ssl.DHKeyExchange$DHEPossession.generateDHKeyPair:(Ljava/security/KeyPairGenerator;)Ljava/security/KeyPair;
astore 5
start local 5 10: aload 5
ifnonnull 16
11: new java.lang.RuntimeException
dup
12: new java.lang.StringBuilder
dup
ldc "Could not generate DH keypair of "
invokespecial java.lang.StringBuilder.<init>:(Ljava/lang/String;)V
13: iload 1
invokevirtual java.lang.StringBuilder.append:(I)Ljava/lang/StringBuilder;
ldc " bits"
invokevirtual java.lang.StringBuilder.append:(Ljava/lang/String;)Ljava/lang/StringBuilder;
14: invokevirtual java.lang.StringBuilder.toString:()Ljava/lang/String;
15: invokespecial java.lang.RuntimeException.<init>:(Ljava/lang/String;)V
athrow
16: StackMap locals: java.security.KeyPair
StackMap stack:
aload 0
aload 5
invokevirtual java.security.KeyPair.getPrivate:()Ljava/security/PrivateKey;
putfield sun.security.ssl.DHKeyExchange$DHEPossession.privateKey:Ljava/security/PrivateKey;
17: aload 0
aload 5
invokevirtual java.security.KeyPair.getPublic:()Ljava/security/PublicKey;
checkcast javax.crypto.interfaces.DHPublicKey
putfield sun.security.ssl.DHKeyExchange$DHEPossession.publicKey:Ljavax/crypto/interfaces/DHPublicKey;
end local 5 end local 4 18: goto 23
StackMap locals: sun.security.ssl.DHKeyExchange$DHEPossession int java.security.SecureRandom javax.crypto.spec.DHParameterSpec
StackMap stack: java.security.GeneralSecurityException
19: astore 4
start local 4 20: new java.lang.RuntimeException
dup
21: ldc "Could not generate DH keypair"
aload 4
22: invokespecial java.lang.RuntimeException.<init>:(Ljava/lang/String;Ljava/lang/Throwable;)V
athrow
end local 4 23: StackMap locals:
StackMap stack:
aload 0
aload 0
getfield sun.security.ssl.DHKeyExchange$DHEPossession.publicKey:Ljavax/crypto/interfaces/DHPublicKey;
invokeinterface javax.crypto.interfaces.DHPublicKey.getParams:()Ljavax/crypto/spec/DHParameterSpec;
invokestatic sun.security.ssl.NamedGroup.valueOf:(Ljavax/crypto/spec/DHParameterSpec;)Lsun/security/ssl/NamedGroup;
putfield sun.security.ssl.DHKeyExchange$DHEPossession.namedGroup:Lsun/security/ssl/NamedGroup;
24: return
end local 3 end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 25 0 this Lsun/security/ssl/DHKeyExchange$DHEPossession;
0 25 1 keyLength I
0 25 2 random Ljava/security/SecureRandom;
3 25 3 params Ljavax/crypto/spec/DHParameterSpec;
5 18 4 kpg Ljava/security/KeyPairGenerator;
10 18 5 kp Ljava/security/KeyPair;
20 23 4 gse Ljava/security/GeneralSecurityException;
Exception table:
from to target type
3 18 19 Class java.security.GeneralSecurityException
MethodParameters:
Name Flags
keyLength
random
void <init>(sun.security.ssl.DHKeyExchange$DHECredentials, java.security.SecureRandom);
descriptor: (Lsun/security/ssl/DHKeyExchange$DHECredentials;Ljava/security/SecureRandom;)V
flags: (0x0000)
Code:
stack=4, locals=5, args_size=3
start local 0 start local 1 start local 2 0: aload 0
invokespecial java.lang.Object.<init>:()V
1: ldc "DiffieHellman"
invokestatic java.security.KeyPairGenerator.getInstance:(Ljava/lang/String;)Ljava/security/KeyPairGenerator;
2: astore 3
start local 3 3: aload 3
aload 1
getfield sun.security.ssl.DHKeyExchange$DHECredentials.popPublicKey:Ljavax/crypto/interfaces/DHPublicKey;
invokeinterface javax.crypto.interfaces.DHPublicKey.getParams:()Ljavax/crypto/spec/DHParameterSpec;
aload 2
invokevirtual java.security.KeyPairGenerator.initialize:(Ljava/security/spec/AlgorithmParameterSpec;Ljava/security/SecureRandom;)V
4: aload 0
aload 3
invokevirtual sun.security.ssl.DHKeyExchange$DHEPossession.generateDHKeyPair:(Ljava/security/KeyPairGenerator;)Ljava/security/KeyPair;
astore 4
start local 4 5: aload 4
ifnonnull 7
6: new java.lang.RuntimeException
dup
ldc "Could not generate DH keypair"
invokespecial java.lang.RuntimeException.<init>:(Ljava/lang/String;)V
athrow
7: StackMap locals: sun.security.ssl.DHKeyExchange$DHEPossession sun.security.ssl.DHKeyExchange$DHECredentials java.security.SecureRandom java.security.KeyPairGenerator java.security.KeyPair
StackMap stack:
aload 0
aload 4
invokevirtual java.security.KeyPair.getPrivate:()Ljava/security/PrivateKey;
putfield sun.security.ssl.DHKeyExchange$DHEPossession.privateKey:Ljava/security/PrivateKey;
8: aload 0
aload 4
invokevirtual java.security.KeyPair.getPublic:()Ljava/security/PublicKey;
checkcast javax.crypto.interfaces.DHPublicKey
putfield sun.security.ssl.DHKeyExchange$DHEPossession.publicKey:Ljavax/crypto/interfaces/DHPublicKey;
end local 4 end local 3 9: goto 14
StackMap locals: sun.security.ssl.DHKeyExchange$DHEPossession sun.security.ssl.DHKeyExchange$DHECredentials java.security.SecureRandom
StackMap stack: java.security.GeneralSecurityException
10: astore 3
start local 3 11: new java.lang.RuntimeException
dup
12: ldc "Could not generate DH keypair"
aload 3
13: invokespecial java.lang.RuntimeException.<init>:(Ljava/lang/String;Ljava/lang/Throwable;)V
athrow
end local 3 14: StackMap locals:
StackMap stack:
aload 0
aload 1
getfield sun.security.ssl.DHKeyExchange$DHECredentials.namedGroup:Lsun/security/ssl/NamedGroup;
putfield sun.security.ssl.DHKeyExchange$DHEPossession.namedGroup:Lsun/security/ssl/NamedGroup;
15: return
end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 16 0 this Lsun/security/ssl/DHKeyExchange$DHEPossession;
0 16 1 credentials Lsun/security/ssl/DHKeyExchange$DHECredentials;
0 16 2 random Ljava/security/SecureRandom;
3 9 3 kpg Ljava/security/KeyPairGenerator;
5 9 4 kp Ljava/security/KeyPair;
11 14 3 gse Ljava/security/GeneralSecurityException;
Exception table:
from to target type
1 9 10 Class java.security.GeneralSecurityException
MethodParameters:
Name Flags
credentials
random
private java.security.KeyPair generateDHKeyPair(java.security.KeyPairGenerator);
descriptor: (Ljava/security/KeyPairGenerator;)Ljava/security/KeyPair;
flags: (0x0002) ACC_PRIVATE
Code:
stack=2, locals=8, args_size=2
start local 0 start local 1 0: aload 1
invokevirtual java.security.KeyPairGenerator.getProvider:()Ljava/security/Provider;
invokevirtual java.security.Provider.getName:()Ljava/lang/String;
invokestatic sun.security.util.KeyUtil.isOracleJCEProvider:(Ljava/lang/String;)Z
ifeq 1
iconst_0
goto 2
StackMap locals:
StackMap stack:
1: iconst_1
2: StackMap locals:
StackMap stack: int
istore 2
start local 2 3: iconst_0
istore 3
start local 3 4: iconst_0
istore 4
start local 4 5: goto 18
6: StackMap locals: int int int
StackMap stack:
aload 1
invokevirtual java.security.KeyPairGenerator.generateKeyPair:()Ljava/security/KeyPair;
astore 5
start local 5 7: iload 2
ifeq 16
8: aload 5
invokevirtual java.security.KeyPair.getPublic:()Ljava/security/PublicKey;
invokestatic sun.security.ssl.DHKeyExchange$DHEPossession.getDHPublicKeySpec:(Ljava/security/PublicKey;)Ljavax/crypto/spec/DHPublicKeySpec;
astore 6
start local 6 9: aload 6
invokestatic sun.security.util.KeyUtil.validate:(Ljava/security/spec/KeySpec;)V
10: goto 16
StackMap locals: sun.security.ssl.DHKeyExchange$DHEPossession java.security.KeyPairGenerator int int int java.security.KeyPair javax.crypto.spec.DHPublicKeySpec
StackMap stack: java.security.InvalidKeyException
11: astore 7
start local 7 12: iload 3
ifeq 14
13: aload 7
athrow
14: StackMap locals: java.security.InvalidKeyException
StackMap stack:
iconst_1
istore 3
15: goto 17
end local 7 end local 6 16: StackMap locals:
StackMap stack:
aload 5
areturn
end local 5 17: StackMap locals:
StackMap stack:
iinc 4 1
StackMap locals:
StackMap stack:
18: iload 4
iconst_2
if_icmple 6
end local 4 19: aconst_null
areturn
end local 3 end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 20 0 this Lsun/security/ssl/DHKeyExchange$DHEPossession;
0 20 1 kpg Ljava/security/KeyPairGenerator;
3 20 2 doExtraValidation Z
4 20 3 isRecovering Z
5 19 4 i I
7 17 5 kp Ljava/security/KeyPair;
9 16 6 spec Ljavax/crypto/spec/DHPublicKeySpec;
12 16 7 ivke Ljava/security/InvalidKeyException;
Exception table:
from to target type
9 10 11 Class java.security.InvalidKeyException
Exceptions:
throws java.security.GeneralSecurityException
MethodParameters:
Name Flags
kpg
private static javax.crypto.spec.DHPublicKeySpec getDHPublicKeySpec(java.security.PublicKey);
descriptor: (Ljava/security/PublicKey;)Ljavax/crypto/spec/DHPublicKeySpec;
flags: (0x000a) ACC_PRIVATE, ACC_STATIC
Code:
stack=5, locals=3, args_size=1
start local 0 0: aload 0
instanceof javax.crypto.interfaces.DHPublicKey
ifeq 6
1: aload 0
checkcast javax.crypto.interfaces.DHPublicKey
astore 1
start local 1 2: aload 1
invokeinterface javax.crypto.interfaces.DHPublicKey.getParams:()Ljavax/crypto/spec/DHParameterSpec;
astore 2
start local 2 3: new javax.crypto.spec.DHPublicKeySpec
dup
aload 1
invokeinterface javax.crypto.interfaces.DHPublicKey.getY:()Ljava/math/BigInteger;
4: aload 2
invokevirtual javax.crypto.spec.DHParameterSpec.getP:()Ljava/math/BigInteger;
aload 2
invokevirtual javax.crypto.spec.DHParameterSpec.getG:()Ljava/math/BigInteger;
5: invokespecial javax.crypto.spec.DHPublicKeySpec.<init>:(Ljava/math/BigInteger;Ljava/math/BigInteger;Ljava/math/BigInteger;)V
areturn
end local 2 end local 1 6: StackMap locals:
StackMap stack:
ldc "DiffieHellman"
invokestatic java.security.KeyFactory.getInstance:(Ljava/lang/String;)Ljava/security/KeyFactory;
astore 1
start local 1 7: aload 1
aload 0
ldc Ljavax/crypto/spec/DHPublicKeySpec;
invokevirtual java.security.KeyFactory.getKeySpec:(Ljava/security/Key;Ljava/lang/Class;)Ljava/security/spec/KeySpec;
checkcast javax.crypto.spec.DHPublicKeySpec
8: areturn
end local 1 9: StackMap locals:
StackMap stack: java.security.GeneralSecurityException
astore 1
start local 1 10: new java.lang.RuntimeException
dup
ldc "Unable to get DHPublicKeySpec"
aload 1
invokespecial java.lang.RuntimeException.<init>:(Ljava/lang/String;Ljava/lang/Throwable;)V
athrow
end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 11 0 key Ljava/security/PublicKey;
2 6 1 dhKey Ljavax/crypto/interfaces/DHPublicKey;
3 6 2 params Ljavax/crypto/spec/DHParameterSpec;
7 9 1 factory Ljava/security/KeyFactory;
10 11 1 e Ljava/security/GeneralSecurityException;
Exception table:
from to target type
6 8 9 Class java.security.NoSuchAlgorithmException
6 8 9 Class java.security.spec.InvalidKeySpecException
MethodParameters:
Name Flags
key
public byte[] encode();
descriptor: ()[B
flags: (0x0001) ACC_PUBLIC
Code:
stack=5, locals=4, args_size=1
start local 0 0: aload 0
getfield sun.security.ssl.DHKeyExchange$DHEPossession.publicKey:Ljavax/crypto/interfaces/DHPublicKey;
invokeinterface javax.crypto.interfaces.DHPublicKey.getY:()Ljava/math/BigInteger;
invokestatic sun.security.ssl.Utilities.toByteArray:(Ljava/math/BigInteger;)[B
astore 1
start local 1 1: aload 0
getfield sun.security.ssl.DHKeyExchange$DHEPossession.publicKey:Ljavax/crypto/interfaces/DHPublicKey;
invokestatic sun.security.util.KeyUtil.getKeySize:(Ljava/security/Key;)I
bipush 7
iadd
iconst_3
iushr
istore 2
start local 2 2: iload 2
ifle 8
aload 1
arraylength
iload 2
if_icmpge 8
3: iload 2
newarray 8
astore 3
start local 3 4: aload 1
iconst_0
5: aload 3
iload 2
aload 1
arraylength
isub
aload 1
arraylength
6: invokestatic java.lang.System.arraycopy:(Ljava/lang/Object;ILjava/lang/Object;II)V
7: aload 3
astore 1
end local 3 8: StackMap locals: byte[] int
StackMap stack:
aload 1
areturn
end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 9 0 this Lsun/security/ssl/DHKeyExchange$DHEPossession;
1 9 1 encoded [B
2 9 2 pSize I
4 8 3 buffer [B
public java.security.PublicKey getPublicKey();
descriptor: ()Ljava/security/PublicKey;
flags: (0x0001) ACC_PUBLIC
Code:
stack=1, locals=1, args_size=1
start local 0 0: aload 0
getfield sun.security.ssl.DHKeyExchange$DHEPossession.publicKey:Ljavax/crypto/interfaces/DHPublicKey;
areturn
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 1 0 this Lsun/security/ssl/DHKeyExchange$DHEPossession;
public sun.security.ssl.NamedGroup getNamedGroup();
descriptor: ()Lsun/security/ssl/NamedGroup;
flags: (0x0001) ACC_PUBLIC
Code:
stack=1, locals=1, args_size=1
start local 0 0: aload 0
getfield sun.security.ssl.DHKeyExchange$DHEPossession.namedGroup:Lsun/security/ssl/NamedGroup;
areturn
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 1 0 this Lsun/security/ssl/DHKeyExchange$DHEPossession;
public java.security.PrivateKey getPrivateKey();
descriptor: ()Ljava/security/PrivateKey;
flags: (0x0001) ACC_PUBLIC
Code:
stack=1, locals=1, args_size=1
start local 0 0: aload 0
getfield sun.security.ssl.DHKeyExchange$DHEPossession.privateKey:Ljava/security/PrivateKey;
areturn
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 1 0 this Lsun/security/ssl/DHKeyExchange$DHEPossession;
}
SourceFile: "DHKeyExchange.java"
NestHost: sun.security.ssl.DHKeyExchange
InnerClasses:
final DHECredentials = sun.security.ssl.DHKeyExchange$DHECredentials of sun.security.ssl.DHKeyExchange
final DHEPossession = sun.security.ssl.DHKeyExchange$DHEPossession of sun.security.ssl.DHKeyExchange