final class com.sun.crypto.provider.KeyProtector
minor version: 0
major version: 59
flags: flags: (0x0030) ACC_FINAL, ACC_SUPER
this_class: com.sun.crypto.provider.KeyProtector
super_class: java.lang.Object
{
private static final java.lang.String PBE_WITH_MD5_AND_DES3_CBC_OID;
descriptor: Ljava/lang/String;
flags: (0x001a) ACC_PRIVATE, ACC_STATIC, ACC_FINAL
ConstantValue: "1.3.6.1.4.1.42.2.19.1"
private static final java.lang.String KEY_PROTECTOR_OID;
descriptor: Ljava/lang/String;
flags: (0x001a) ACC_PRIVATE, ACC_STATIC, ACC_FINAL
ConstantValue: "1.3.6.1.4.1.42.2.17.1.1"
private static final int MAX_ITERATION_COUNT;
descriptor: I
flags: (0x001a) ACC_PRIVATE, ACC_STATIC, ACC_FINAL
ConstantValue: 5000000
private static final int ITERATION_COUNT;
descriptor: I
flags: (0x001a) ACC_PRIVATE, ACC_STATIC, ACC_FINAL
ConstantValue: 200000
private static final int SALT_LEN;
descriptor: I
flags: (0x001a) ACC_PRIVATE, ACC_STATIC, ACC_FINAL
ConstantValue: 20
private static final int DIGEST_LEN;
descriptor: I
flags: (0x001a) ACC_PRIVATE, ACC_STATIC, ACC_FINAL
ConstantValue: 20
private char[] password;
descriptor: [C
flags: (0x0002) ACC_PRIVATE
private static final java.security.Provider PROV;
descriptor: Ljava/security/Provider;
flags: (0x001a) ACC_PRIVATE, ACC_STATIC, ACC_FINAL
static void <clinit>();
descriptor: ()V
flags: (0x0008) ACC_STATIC
Code:
stack=1, locals=0, args_size=0
0: ldc "SunJCE"
invokestatic java.security.Security.getProvider:(Ljava/lang/String;)Ljava/security/Provider;
putstatic com.sun.crypto.provider.KeyProtector.PROV:Ljava/security/Provider;
return
LocalVariableTable:
Start End Slot Name Signature
void <init>(char[]);
descriptor: ([C)V
flags: (0x0000)
Code:
stack=3, locals=2, args_size=2
start local 0 start local 1 0: aload 0
invokespecial java.lang.Object.<init>:()V
1: aload 1
ifnonnull 3
2: new java.lang.IllegalArgumentException
dup
ldc "password can't be null"
invokespecial java.lang.IllegalArgumentException.<init>:(Ljava/lang/String;)V
athrow
3: StackMap locals: com.sun.crypto.provider.KeyProtector char[]
StackMap stack:
aload 0
aload 1
putfield com.sun.crypto.provider.KeyProtector.password:[C
4: return
end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 5 0 this Lcom/sun/crypto/provider/KeyProtector;
0 5 1 password [C
MethodParameters:
Name Flags
password
byte[] protect(java.security.PrivateKey);
descriptor: (Ljava/security/PrivateKey;)[B
flags: (0x0000)
Code:
stack=5, locals=11, args_size=2
start local 0 start local 1 0: bipush 8
newarray 8
astore 2
start local 2 1: getstatic com.sun.crypto.provider.SunJCE.RANDOM:Ljava/security/SecureRandom;
aload 2
invokevirtual java.security.SecureRandom.nextBytes:([B)V
2: new javax.crypto.spec.PBEParameterSpec
dup
aload 2
ldc 200000
invokespecial javax.crypto.spec.PBEParameterSpec.<init>:([BI)V
astore 3
start local 3 3: new javax.crypto.spec.PBEKeySpec
dup
aload 0
getfield com.sun.crypto.provider.KeyProtector.password:[C
invokespecial javax.crypto.spec.PBEKeySpec.<init>:([C)V
astore 4
start local 4 4: new com.sun.crypto.provider.PBEKey
dup
aload 4
ldc "PBEWithMD5AndTripleDES"
invokespecial com.sun.crypto.provider.PBEKey.<init>:(Ljavax/crypto/spec/PBEKeySpec;Ljava/lang/String;)V
astore 5
start local 5 5: aload 4
invokevirtual javax.crypto.spec.PBEKeySpec.clearPassword:()V
6: new com.sun.crypto.provider.PBEWithMD5AndTripleDESCipher
dup
invokespecial com.sun.crypto.provider.PBEWithMD5AndTripleDESCipher.<init>:()V
astore 6
start local 6 7: aload 6
iconst_1
aload 5
aload 3
aconst_null
invokevirtual com.sun.crypto.provider.PBEWithMD5AndTripleDESCipher.engineInit:(ILjava/security/Key;Ljava/security/spec/AlgorithmParameterSpec;Ljava/security/SecureRandom;)V
8: aload 1
invokeinterface java.security.PrivateKey.getEncoded:()[B
astore 7
start local 7 9: aload 6
aload 7
iconst_0
aload 7
arraylength
invokevirtual com.sun.crypto.provider.PBEWithMD5AndTripleDESCipher.engineDoFinal:([BII)[B
astore 8
start local 8 10: ldc "PBE"
getstatic com.sun.crypto.provider.KeyProtector.PROV:Ljava/security/Provider;
invokestatic java.security.AlgorithmParameters.getInstance:(Ljava/lang/String;Ljava/security/Provider;)Ljava/security/AlgorithmParameters;
11: astore 9
start local 9 12: aload 9
aload 3
invokevirtual java.security.AlgorithmParameters.init:(Ljava/security/spec/AlgorithmParameterSpec;)V
13: new sun.security.x509.AlgorithmId
dup
14: new sun.security.util.ObjectIdentifier
dup
ldc "1.3.6.1.4.1.42.2.19.1"
invokespecial sun.security.util.ObjectIdentifier.<init>:(Ljava/lang/String;)V
aload 9
15: invokespecial sun.security.x509.AlgorithmId.<init>:(Lsun/security/util/ObjectIdentifier;Ljava/security/AlgorithmParameters;)V
astore 10
start local 10 16: new com.sun.crypto.provider.EncryptedPrivateKeyInfo
dup
aload 10
aload 8
invokespecial com.sun.crypto.provider.EncryptedPrivateKeyInfo.<init>:(Lsun/security/x509/AlgorithmId;[B)V
invokevirtual com.sun.crypto.provider.EncryptedPrivateKeyInfo.getEncoded:()[B
areturn
end local 10 end local 9 end local 8 end local 7 end local 6 end local 5 end local 4 end local 3 end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 17 0 this Lcom/sun/crypto/provider/KeyProtector;
0 17 1 key Ljava/security/PrivateKey;
1 17 2 salt [B
3 17 3 pbeSpec Ljavax/crypto/spec/PBEParameterSpec;
4 17 4 pbeKeySpec Ljavax/crypto/spec/PBEKeySpec;
5 17 5 sKey Ljavax/crypto/SecretKey;
7 17 6 cipher Lcom/sun/crypto/provider/PBEWithMD5AndTripleDESCipher;
9 17 7 plain [B
10 17 8 encrKey [B
12 17 9 pbeParams Ljava/security/AlgorithmParameters;
16 17 10 encrAlg Lsun/security/x509/AlgorithmId;
Exceptions:
throws java.lang.Exception
MethodParameters:
Name Flags
key
java.security.Key recover(com.sun.crypto.provider.EncryptedPrivateKeyInfo);
descriptor: (Lcom/sun/crypto/provider/EncryptedPrivateKeyInfo;)Ljava/security/Key;
flags: (0x0000)
Code:
stack=5, locals=10, args_size=2
start local 0 start local 1 0: aload 1
invokevirtual com.sun.crypto.provider.EncryptedPrivateKeyInfo.getAlgorithm:()Lsun/security/x509/AlgorithmId;
invokevirtual sun.security.x509.AlgorithmId.getOID:()Lsun/security/util/ObjectIdentifier;
invokevirtual sun.security.util.ObjectIdentifier.toString:()Ljava/lang/String;
astore 3
start local 3 1: aload 3
ldc "1.3.6.1.4.1.42.2.19.1"
invokevirtual java.lang.String.equals:(Ljava/lang/Object;)Z
ifne 4
2: aload 3
ldc "1.3.6.1.4.1.42.2.17.1.1"
invokevirtual java.lang.String.equals:(Ljava/lang/Object;)Z
ifne 4
3: new java.security.UnrecoverableKeyException
dup
ldc "Unsupported encryption algorithm"
invokespecial java.security.UnrecoverableKeyException.<init>:(Ljava/lang/String;)V
athrow
4: StackMap locals: com.sun.crypto.provider.KeyProtector com.sun.crypto.provider.EncryptedPrivateKeyInfo top java.lang.String
StackMap stack:
aload 3
ldc "1.3.6.1.4.1.42.2.17.1.1"
invokevirtual java.lang.String.equals:(Ljava/lang/Object;)Z
ifeq 7
5: aload 0
aload 1
invokevirtual com.sun.crypto.provider.EncryptedPrivateKeyInfo.getEncryptedData:()[B
invokevirtual com.sun.crypto.provider.KeyProtector.recover:([B)[B
astore 2
start local 2 6: goto 25
end local 2 7: StackMap locals:
StackMap stack:
aload 1
invokevirtual com.sun.crypto.provider.EncryptedPrivateKeyInfo.getAlgorithm:()Lsun/security/x509/AlgorithmId;
invokevirtual sun.security.x509.AlgorithmId.getEncodedParams:()[B
8: astore 4
start local 4 9: ldc "PBE"
invokestatic java.security.AlgorithmParameters.getInstance:(Ljava/lang/String;)Ljava/security/AlgorithmParameters;
10: astore 5
start local 5 11: aload 5
aload 4
invokevirtual java.security.AlgorithmParameters.init:([B)V
12: aload 5
ldc Ljavax/crypto/spec/PBEParameterSpec;
invokevirtual java.security.AlgorithmParameters.getParameterSpec:(Ljava/lang/Class;)Ljava/security/spec/AlgorithmParameterSpec;
checkcast javax.crypto.spec.PBEParameterSpec
13: astore 6
start local 6 14: aload 6
invokevirtual javax.crypto.spec.PBEParameterSpec.getIterationCount:()I
ldc 5000000
if_icmple 16
15: new java.io.IOException
dup
ldc "PBE iteration count too large"
invokespecial java.io.IOException.<init>:(Ljava/lang/String;)V
athrow
16: StackMap locals: byte[] java.security.AlgorithmParameters javax.crypto.spec.PBEParameterSpec
StackMap stack:
new javax.crypto.spec.PBEKeySpec
dup
aload 0
getfield com.sun.crypto.provider.KeyProtector.password:[C
invokespecial javax.crypto.spec.PBEKeySpec.<init>:([C)V
astore 7
start local 7 17: new com.sun.crypto.provider.PBEKey
dup
aload 7
ldc "PBEWithMD5AndTripleDES"
invokespecial com.sun.crypto.provider.PBEKey.<init>:(Ljavax/crypto/spec/PBEKeySpec;Ljava/lang/String;)V
18: astore 8
start local 8 19: aload 7
invokevirtual javax.crypto.spec.PBEKeySpec.clearPassword:()V
20: new com.sun.crypto.provider.PBEWithMD5AndTripleDESCipher
dup
invokespecial com.sun.crypto.provider.PBEWithMD5AndTripleDESCipher.<init>:()V
astore 9
start local 9 21: aload 9
iconst_2
aload 8
aload 6
aconst_null
invokevirtual com.sun.crypto.provider.PBEWithMD5AndTripleDESCipher.engineInit:(ILjava/security/Key;Ljava/security/spec/AlgorithmParameterSpec;Ljava/security/SecureRandom;)V
22: aload 9
aload 1
invokevirtual com.sun.crypto.provider.EncryptedPrivateKeyInfo.getEncryptedData:()[B
iconst_0
23: aload 1
invokevirtual com.sun.crypto.provider.EncryptedPrivateKeyInfo.getEncryptedData:()[B
arraylength
24: invokevirtual com.sun.crypto.provider.PBEWithMD5AndTripleDESCipher.engineDoFinal:([BII)[B
astore 2
end local 9 end local 8 end local 7 end local 6 end local 5 end local 4 start local 2 25: StackMap locals: com.sun.crypto.provider.KeyProtector com.sun.crypto.provider.EncryptedPrivateKeyInfo byte[] java.lang.String
StackMap stack:
new sun.security.x509.AlgorithmId
dup
26: new com.sun.crypto.provider.PrivateKeyInfo
dup
aload 2
invokespecial com.sun.crypto.provider.PrivateKeyInfo.<init>:([B)V
invokevirtual com.sun.crypto.provider.PrivateKeyInfo.getAlgorithm:()Lsun/security/x509/AlgorithmId;
invokevirtual sun.security.x509.AlgorithmId.getOID:()Lsun/security/util/ObjectIdentifier;
27: invokespecial sun.security.x509.AlgorithmId.<init>:(Lsun/security/util/ObjectIdentifier;)V
28: invokevirtual sun.security.x509.AlgorithmId.getName:()Ljava/lang/String;
29: astore 4
start local 4 30: aload 4
invokestatic java.security.KeyFactory.getInstance:(Ljava/lang/String;)Ljava/security/KeyFactory;
astore 5
start local 5 31: aload 5
new java.security.spec.PKCS8EncodedKeySpec
dup
aload 2
invokespecial java.security.spec.PKCS8EncodedKeySpec.<init>:([B)V
invokevirtual java.security.KeyFactory.generatePrivate:(Ljava/security/spec/KeySpec;)Ljava/security/PrivateKey;
32: areturn
end local 5 end local 4 end local 3 end local 2 33: StackMap locals: com.sun.crypto.provider.KeyProtector com.sun.crypto.provider.EncryptedPrivateKeyInfo
StackMap stack: java.security.NoSuchAlgorithmException
astore 3
start local 3 34: aload 3
athrow
end local 3 35: StackMap locals:
StackMap stack: java.io.IOException
astore 3
start local 3 36: new java.security.UnrecoverableKeyException
dup
aload 3
invokevirtual java.io.IOException.getMessage:()Ljava/lang/String;
invokespecial java.security.UnrecoverableKeyException.<init>:(Ljava/lang/String;)V
athrow
end local 3 37: StackMap locals:
StackMap stack: java.security.GeneralSecurityException
astore 3
start local 3 38: new java.security.UnrecoverableKeyException
dup
aload 3
invokevirtual java.security.GeneralSecurityException.getMessage:()Ljava/lang/String;
invokespecial java.security.UnrecoverableKeyException.<init>:(Ljava/lang/String;)V
athrow
end local 3 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 39 0 this Lcom/sun/crypto/provider/KeyProtector;
0 39 1 encrInfo Lcom/sun/crypto/provider/EncryptedPrivateKeyInfo;
6 7 2 plain [B
25 33 2 plain [B
1 33 3 encrAlg Ljava/lang/String;
9 25 4 encodedParams [B
11 25 5 pbeParams Ljava/security/AlgorithmParameters;
14 25 6 pbeSpec Ljavax/crypto/spec/PBEParameterSpec;
17 25 7 pbeKeySpec Ljavax/crypto/spec/PBEKeySpec;
19 25 8 sKey Ljavax/crypto/SecretKey;
21 25 9 cipher Lcom/sun/crypto/provider/PBEWithMD5AndTripleDESCipher;
30 33 4 oidName Ljava/lang/String;
31 33 5 kFac Ljava/security/KeyFactory;
34 35 3 ex Ljava/security/NoSuchAlgorithmException;
36 37 3 ioe Ljava/io/IOException;
38 39 3 gse Ljava/security/GeneralSecurityException;
Exception table:
from to target type
0 32 33 Class java.security.NoSuchAlgorithmException
0 32 35 Class java.io.IOException
0 32 37 Class java.security.GeneralSecurityException
Exceptions:
throws java.security.UnrecoverableKeyException, java.security.NoSuchAlgorithmException
MethodParameters:
Name Flags
encrInfo
private byte[] recover(byte[]);
descriptor: ([B)[B
flags: (0x0002) ACC_PRIVATE
Code:
stack=6, locals=14, args_size=2
start local 0 start local 1 0: ldc "SHA"
invokestatic java.security.MessageDigest.getInstance:(Ljava/lang/String;)Ljava/security/MessageDigest;
astore 8
start local 8 1: bipush 20
newarray 8
astore 9
start local 9 2: aload 1
iconst_0
aload 9
iconst_0
bipush 20
invokestatic java.lang.System.arraycopy:(Ljava/lang/Object;ILjava/lang/Object;II)V
3: aload 1
arraylength
bipush 20
isub
bipush 20
isub
istore 7
start local 7 4: iload 7
bipush 20
idiv
istore 5
start local 5 5: iload 7
bipush 20
irem
ifeq 7
6: iinc 5 1
7: StackMap locals: com.sun.crypto.provider.KeyProtector byte[] top top top int top int java.security.MessageDigest byte[]
StackMap stack:
iload 7
newarray 8
astore 10
start local 10 8: aload 1
bipush 20
aload 10
iconst_0
iload 7
invokestatic java.lang.System.arraycopy:(Ljava/lang/Object;ILjava/lang/Object;II)V
9: aload 10
arraylength
newarray 8
astore 11
start local 11 10: aload 0
getfield com.sun.crypto.provider.KeyProtector.password:[C
arraylength
iconst_2
imul
newarray 8
astore 12
start local 12 11: iconst_0
istore 2
start local 2 12: iconst_0
istore 3
start local 3 13: goto 17
14: StackMap locals: com.sun.crypto.provider.KeyProtector byte[] int int top int top int java.security.MessageDigest byte[] byte[] byte[] byte[]
StackMap stack:
aload 12
iload 3
iinc 3 1
aload 0
getfield com.sun.crypto.provider.KeyProtector.password:[C
iload 2
caload
bipush 8
ishr
i2b
bastore
15: aload 12
iload 3
iinc 3 1
aload 0
getfield com.sun.crypto.provider.KeyProtector.password:[C
iload 2
caload
i2b
bastore
16: iinc 2 1
StackMap locals:
StackMap stack:
17: iload 2
aload 0
getfield com.sun.crypto.provider.KeyProtector.password:[C
arraylength
if_icmplt 14
18: iconst_0
istore 2
iconst_0
istore 6
start local 6 19: aload 9
astore 4
start local 4 20: goto 34
21: StackMap locals: com.sun.crypto.provider.KeyProtector byte[] int int byte[] int int int java.security.MessageDigest byte[] byte[] byte[] byte[]
StackMap stack:
aload 8
aload 12
invokevirtual java.security.MessageDigest.update:([B)V
22: aload 8
aload 4
invokevirtual java.security.MessageDigest.update:([B)V
23: aload 8
invokevirtual java.security.MessageDigest.digest:()[B
astore 4
24: aload 8
invokevirtual java.security.MessageDigest.reset:()V
25: iload 2
iload 5
iconst_1
isub
if_icmpge 30
26: aload 4
iconst_0
aload 11
iload 6
27: aload 4
arraylength
28: invokestatic java.lang.System.arraycopy:(Ljava/lang/Object;ILjava/lang/Object;II)V
29: goto 33
30: StackMap locals:
StackMap stack:
aload 4
iconst_0
aload 11
iload 6
31: aload 11
arraylength
iload 6
isub
32: invokestatic java.lang.System.arraycopy:(Ljava/lang/Object;ILjava/lang/Object;II)V
33: StackMap locals:
StackMap stack:
iinc 2 1
iinc 6 20
34: StackMap locals:
StackMap stack:
iload 2
iload 5
35: if_icmplt 21
36: aload 10
arraylength
newarray 8
astore 13
start local 13 37: iconst_0
istore 2
goto 40
38: StackMap locals: byte[]
StackMap stack:
aload 13
iload 2
aload 10
iload 2
baload
aload 11
iload 2
baload
ixor
i2b
bastore
39: iinc 2 1
StackMap locals:
StackMap stack:
40: iload 2
aload 13
arraylength
if_icmplt 38
41: aload 8
aload 12
invokevirtual java.security.MessageDigest.update:([B)V
42: aload 12
iconst_0
invokestatic java.util.Arrays.fill:([BB)V
43: aconst_null
astore 12
44: aload 8
aload 13
invokevirtual java.security.MessageDigest.update:([B)V
45: aload 8
invokevirtual java.security.MessageDigest.digest:()[B
astore 4
46: aload 8
invokevirtual java.security.MessageDigest.reset:()V
47: iconst_0
istore 2
goto 51
48: StackMap locals:
StackMap stack:
aload 4
iload 2
baload
aload 1
bipush 20
iload 7
iadd
iload 2
iadd
baload
if_icmpeq 50
49: new java.security.UnrecoverableKeyException
dup
ldc "Cannot recover key"
invokespecial java.security.UnrecoverableKeyException.<init>:(Ljava/lang/String;)V
athrow
50: StackMap locals:
StackMap stack:
iinc 2 1
StackMap locals:
StackMap stack:
51: iload 2
aload 4
arraylength
if_icmplt 48
52: aload 13
areturn
end local 13 end local 12 end local 11 end local 10 end local 9 end local 8 end local 7 end local 6 end local 5 end local 4 end local 3 end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 53 0 this Lcom/sun/crypto/provider/KeyProtector;
0 53 1 protectedKey [B
12 53 2 i I
13 53 3 j I
20 53 4 digest [B
5 53 5 numRounds I
19 53 6 xorOffset I
4 53 7 encrKeyLen I
1 53 8 md Ljava/security/MessageDigest;
2 53 9 salt [B
8 53 10 encrKey [B
10 53 11 xorKey [B
11 53 12 passwdBytes [B
37 53 13 plainKey [B
Exceptions:
throws java.security.UnrecoverableKeyException, java.security.NoSuchAlgorithmException
MethodParameters:
Name Flags
protectedKey
javax.crypto.SealedObject seal(java.security.Key);
descriptor: (Ljava/security/Key;)Ljavax/crypto/SealedObject;
flags: (0x0000)
Code:
stack=5, locals=8, args_size=2
start local 0 start local 1 0: bipush 8
newarray 8
astore 2
start local 2 1: getstatic com.sun.crypto.provider.SunJCE.RANDOM:Ljava/security/SecureRandom;
aload 2
invokevirtual java.security.SecureRandom.nextBytes:([B)V
2: new javax.crypto.spec.PBEParameterSpec
dup
aload 2
ldc 200000
invokespecial javax.crypto.spec.PBEParameterSpec.<init>:([BI)V
astore 3
start local 3 3: new javax.crypto.spec.PBEKeySpec
dup
aload 0
getfield com.sun.crypto.provider.KeyProtector.password:[C
invokespecial javax.crypto.spec.PBEKeySpec.<init>:([C)V
astore 4
start local 4 4: new com.sun.crypto.provider.PBEKey
dup
aload 4
ldc "PBEWithMD5AndTripleDES"
invokespecial com.sun.crypto.provider.PBEKey.<init>:(Ljavax/crypto/spec/PBEKeySpec;Ljava/lang/String;)V
astore 5
start local 5 5: aload 4
invokevirtual javax.crypto.spec.PBEKeySpec.clearPassword:()V
6: new com.sun.crypto.provider.PBEWithMD5AndTripleDESCipher
dup
invokespecial com.sun.crypto.provider.PBEWithMD5AndTripleDESCipher.<init>:()V
astore 7
start local 7 7: new com.sun.crypto.provider.CipherForKeyProtector
dup
aload 7
getstatic com.sun.crypto.provider.KeyProtector.PROV:Ljava/security/Provider;
8: ldc "PBEWithMD5AndTripleDES"
9: invokespecial com.sun.crypto.provider.CipherForKeyProtector.<init>:(Ljavax/crypto/CipherSpi;Ljava/security/Provider;Ljava/lang/String;)V
astore 6
start local 6 10: aload 6
iconst_1
aload 5
aload 3
invokevirtual javax.crypto.Cipher.init:(ILjava/security/Key;Ljava/security/spec/AlgorithmParameterSpec;)V
11: new com.sun.crypto.provider.SealedObjectForKeyProtector
dup
aload 1
aload 6
invokespecial com.sun.crypto.provider.SealedObjectForKeyProtector.<init>:(Ljava/io/Serializable;Ljavax/crypto/Cipher;)V
areturn
end local 7 end local 6 end local 5 end local 4 end local 3 end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 12 0 this Lcom/sun/crypto/provider/KeyProtector;
0 12 1 key Ljava/security/Key;
1 12 2 salt [B
3 12 3 pbeSpec Ljavax/crypto/spec/PBEParameterSpec;
4 12 4 pbeKeySpec Ljavax/crypto/spec/PBEKeySpec;
5 12 5 sKey Ljavax/crypto/SecretKey;
10 12 6 cipher Ljavax/crypto/Cipher;
7 12 7 cipherSpi Lcom/sun/crypto/provider/PBEWithMD5AndTripleDESCipher;
Exceptions:
throws java.lang.Exception
MethodParameters:
Name Flags
key
java.security.Key unseal(javax.crypto.SealedObject);
descriptor: (Ljavax/crypto/SealedObject;)Ljava/security/Key;
flags: (0x0000)
Code:
stack=5, locals=9, args_size=2
start local 0 start local 1 0: new javax.crypto.spec.PBEKeySpec
dup
aload 0
getfield com.sun.crypto.provider.KeyProtector.password:[C
invokespecial javax.crypto.spec.PBEKeySpec.<init>:([C)V
astore 2
start local 2 1: new com.sun.crypto.provider.PBEKey
dup
aload 2
ldc "PBEWithMD5AndTripleDES"
invokespecial com.sun.crypto.provider.PBEKey.<init>:(Ljavax/crypto/spec/PBEKeySpec;Ljava/lang/String;)V
astore 3
start local 3 2: aload 2
invokevirtual javax.crypto.spec.PBEKeySpec.clearPassword:()V
3: aconst_null
astore 4
start local 4 4: aload 1
instanceof com.sun.crypto.provider.SealedObjectForKeyProtector
ifne 7
5: new com.sun.crypto.provider.SealedObjectForKeyProtector
dup
aload 1
invokespecial com.sun.crypto.provider.SealedObjectForKeyProtector.<init>:(Ljavax/crypto/SealedObject;)V
astore 4
6: goto 8
7: StackMap locals: javax.crypto.spec.PBEKeySpec javax.crypto.SecretKey com.sun.crypto.provider.SealedObjectForKeyProtector
StackMap stack:
aload 1
checkcast com.sun.crypto.provider.SealedObjectForKeyProtector
astore 4
8: StackMap locals:
StackMap stack:
aload 4
invokevirtual com.sun.crypto.provider.SealedObjectForKeyProtector.getParameters:()Ljava/security/AlgorithmParameters;
astore 5
start local 5 9: aload 5
ifnonnull 11
10: new java.security.UnrecoverableKeyException
dup
ldc "Cannot get algorithm parameters"
invokespecial java.security.UnrecoverableKeyException.<init>:(Ljava/lang/String;)V
athrow
11: StackMap locals: java.security.AlgorithmParameters
StackMap stack:
aload 5
ldc Ljavax/crypto/spec/PBEParameterSpec;
invokevirtual java.security.AlgorithmParameters.getParameterSpec:(Ljava/lang/Class;)Ljava/security/spec/AlgorithmParameterSpec;
checkcast javax.crypto.spec.PBEParameterSpec
astore 6
start local 6 12: goto 15
end local 6 StackMap locals:
StackMap stack: java.security.spec.InvalidParameterSpecException
13: pop
14: new java.io.IOException
dup
ldc "Invalid PBE algorithm parameters"
invokespecial java.io.IOException.<init>:(Ljava/lang/String;)V
athrow
start local 6 15: StackMap locals: javax.crypto.spec.PBEParameterSpec
StackMap stack:
aload 6
invokevirtual javax.crypto.spec.PBEParameterSpec.getIterationCount:()I
ldc 5000000
if_icmple 17
16: new java.io.IOException
dup
ldc "PBE iteration count too large"
invokespecial java.io.IOException.<init>:(Ljava/lang/String;)V
athrow
17: StackMap locals:
StackMap stack:
new com.sun.crypto.provider.PBEWithMD5AndTripleDESCipher
dup
invokespecial com.sun.crypto.provider.PBEWithMD5AndTripleDESCipher.<init>:()V
astore 7
start local 7 18: new com.sun.crypto.provider.CipherForKeyProtector
dup
aload 7
getstatic com.sun.crypto.provider.KeyProtector.PROV:Ljava/security/Provider;
19: ldc "PBEWithMD5AndTripleDES"
20: invokespecial com.sun.crypto.provider.CipherForKeyProtector.<init>:(Ljavax/crypto/CipherSpi;Ljava/security/Provider;Ljava/lang/String;)V
astore 8
start local 8 21: aload 8
iconst_2
aload 3
aload 5
invokevirtual javax.crypto.Cipher.init:(ILjava/security/Key;Ljava/security/AlgorithmParameters;)V
22: aload 4
aload 8
invokevirtual com.sun.crypto.provider.SealedObjectForKeyProtector.getKey:(Ljavax/crypto/Cipher;)Ljava/security/Key;
23: areturn
end local 8 end local 7 end local 6 end local 5 end local 4 end local 3 end local 2 24: StackMap locals: com.sun.crypto.provider.KeyProtector javax.crypto.SealedObject
StackMap stack: java.security.NoSuchAlgorithmException
astore 2
start local 2 25: aload 2
athrow
end local 2 26: StackMap locals:
StackMap stack: java.io.IOException
astore 2
start local 2 27: new java.security.UnrecoverableKeyException
dup
aload 2
invokevirtual java.io.IOException.getMessage:()Ljava/lang/String;
invokespecial java.security.UnrecoverableKeyException.<init>:(Ljava/lang/String;)V
athrow
end local 2 28: StackMap locals:
StackMap stack: java.lang.ClassNotFoundException
astore 2
start local 2 29: new java.security.UnrecoverableKeyException
dup
aload 2
invokevirtual java.lang.ClassNotFoundException.getMessage:()Ljava/lang/String;
invokespecial java.security.UnrecoverableKeyException.<init>:(Ljava/lang/String;)V
athrow
end local 2 30: StackMap locals:
StackMap stack: java.security.GeneralSecurityException
astore 2
start local 2 31: new java.security.UnrecoverableKeyException
dup
aload 2
invokevirtual java.security.GeneralSecurityException.getMessage:()Ljava/lang/String;
invokespecial java.security.UnrecoverableKeyException.<init>:(Ljava/lang/String;)V
athrow
end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 32 0 this Lcom/sun/crypto/provider/KeyProtector;
0 32 1 so Ljavax/crypto/SealedObject;
1 24 2 pbeKeySpec Ljavax/crypto/spec/PBEKeySpec;
2 24 3 skey Ljavax/crypto/SecretKey;
4 24 4 soForKeyProtector Lcom/sun/crypto/provider/SealedObjectForKeyProtector;
9 24 5 params Ljava/security/AlgorithmParameters;
12 13 6 pbeSpec Ljavax/crypto/spec/PBEParameterSpec;
15 24 6 pbeSpec Ljavax/crypto/spec/PBEParameterSpec;
18 24 7 cipherSpi Lcom/sun/crypto/provider/PBEWithMD5AndTripleDESCipher;
21 24 8 cipher Ljavax/crypto/Cipher;
25 26 2 ex Ljava/security/NoSuchAlgorithmException;
27 28 2 ioe Ljava/io/IOException;
29 30 2 cnfe Ljava/lang/ClassNotFoundException;
31 32 2 gse Ljava/security/GeneralSecurityException;
Exception table:
from to target type
11 12 13 Class java.security.spec.InvalidParameterSpecException
0 23 24 Class java.security.NoSuchAlgorithmException
0 23 26 Class java.io.IOException
0 23 28 Class java.lang.ClassNotFoundException
0 23 30 Class java.security.GeneralSecurityException
Exceptions:
throws java.security.NoSuchAlgorithmException, java.security.UnrecoverableKeyException
MethodParameters:
Name Flags
so
}
SourceFile: "KeyProtector.java"