public class org.bouncycastle.operator.jcajce.JceSymmetricKeyWrapper extends org.bouncycastle.operator.SymmetricKeyWrapper
minor version: 0
major version: 59
flags: flags: (0x0021) ACC_PUBLIC, ACC_SUPER
this_class: org.bouncycastle.operator.jcajce.JceSymmetricKeyWrapper
super_class: org.bouncycastle.operator.SymmetricKeyWrapper
{
private org.bouncycastle.operator.jcajce.OperatorHelper helper;
descriptor: Lorg/bouncycastle/operator/jcajce/OperatorHelper;
flags: (0x0002) ACC_PRIVATE
private java.security.SecureRandom random;
descriptor: Ljava/security/SecureRandom;
flags: (0x0002) ACC_PRIVATE
private javax.crypto.SecretKey wrappingKey;
descriptor: Ljavax/crypto/SecretKey;
flags: (0x0002) ACC_PRIVATE
public void <init>(javax.crypto.SecretKey);
descriptor: (Ljavax/crypto/SecretKey;)V
flags: (0x0001) ACC_PUBLIC
Code:
stack=5, locals=2, args_size=2
start local 0 start local 1 0: aload 0
aload 1
invokestatic org.bouncycastle.operator.jcajce.JceSymmetricKeyWrapper.determineKeyEncAlg:(Ljavax/crypto/SecretKey;)Lorg/bouncycastle/asn1/x509/AlgorithmIdentifier;
invokespecial org.bouncycastle.operator.SymmetricKeyWrapper.<init>:(Lorg/bouncycastle/asn1/x509/AlgorithmIdentifier;)V
1: aload 0
new org.bouncycastle.operator.jcajce.OperatorHelper
dup
new org.bouncycastle.jcajce.util.DefaultJcaJceHelper
dup
invokespecial org.bouncycastle.jcajce.util.DefaultJcaJceHelper.<init>:()V
invokespecial org.bouncycastle.operator.jcajce.OperatorHelper.<init>:(Lorg/bouncycastle/jcajce/util/JcaJceHelper;)V
putfield org.bouncycastle.operator.jcajce.JceSymmetricKeyWrapper.helper:Lorg/bouncycastle/operator/jcajce/OperatorHelper;
2: aload 0
aload 1
putfield org.bouncycastle.operator.jcajce.JceSymmetricKeyWrapper.wrappingKey:Ljavax/crypto/SecretKey;
3: return
end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 4 0 this Lorg/bouncycastle/operator/jcajce/JceSymmetricKeyWrapper;
0 4 1 wrappingKey Ljavax/crypto/SecretKey;
MethodParameters:
Name Flags
wrappingKey
public org.bouncycastle.operator.jcajce.JceSymmetricKeyWrapper setProvider(java.security.Provider);
descriptor: (Ljava/security/Provider;)Lorg/bouncycastle/operator/jcajce/JceSymmetricKeyWrapper;
flags: (0x0001) ACC_PUBLIC
Code:
stack=6, locals=2, args_size=2
start local 0 start local 1 0: aload 0
new org.bouncycastle.operator.jcajce.OperatorHelper
dup
new org.bouncycastle.jcajce.util.ProviderJcaJceHelper
dup
aload 1
invokespecial org.bouncycastle.jcajce.util.ProviderJcaJceHelper.<init>:(Ljava/security/Provider;)V
invokespecial org.bouncycastle.operator.jcajce.OperatorHelper.<init>:(Lorg/bouncycastle/jcajce/util/JcaJceHelper;)V
putfield org.bouncycastle.operator.jcajce.JceSymmetricKeyWrapper.helper:Lorg/bouncycastle/operator/jcajce/OperatorHelper;
1: aload 0
areturn
end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 2 0 this Lorg/bouncycastle/operator/jcajce/JceSymmetricKeyWrapper;
0 2 1 provider Ljava/security/Provider;
MethodParameters:
Name Flags
provider
public org.bouncycastle.operator.jcajce.JceSymmetricKeyWrapper setProvider(java.lang.String);
descriptor: (Ljava/lang/String;)Lorg/bouncycastle/operator/jcajce/JceSymmetricKeyWrapper;
flags: (0x0001) ACC_PUBLIC
Code:
stack=6, locals=2, args_size=2
start local 0 start local 1 0: aload 0
new org.bouncycastle.operator.jcajce.OperatorHelper
dup
new org.bouncycastle.jcajce.util.NamedJcaJceHelper
dup
aload 1
invokespecial org.bouncycastle.jcajce.util.NamedJcaJceHelper.<init>:(Ljava/lang/String;)V
invokespecial org.bouncycastle.operator.jcajce.OperatorHelper.<init>:(Lorg/bouncycastle/jcajce/util/JcaJceHelper;)V
putfield org.bouncycastle.operator.jcajce.JceSymmetricKeyWrapper.helper:Lorg/bouncycastle/operator/jcajce/OperatorHelper;
1: aload 0
areturn
end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 2 0 this Lorg/bouncycastle/operator/jcajce/JceSymmetricKeyWrapper;
0 2 1 providerName Ljava/lang/String;
MethodParameters:
Name Flags
providerName
public org.bouncycastle.operator.jcajce.JceSymmetricKeyWrapper setSecureRandom(java.security.SecureRandom);
descriptor: (Ljava/security/SecureRandom;)Lorg/bouncycastle/operator/jcajce/JceSymmetricKeyWrapper;
flags: (0x0001) ACC_PUBLIC
Code:
stack=2, locals=2, args_size=2
start local 0 start local 1 0: aload 0
aload 1
putfield org.bouncycastle.operator.jcajce.JceSymmetricKeyWrapper.random:Ljava/security/SecureRandom;
1: aload 0
areturn
end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 2 0 this Lorg/bouncycastle/operator/jcajce/JceSymmetricKeyWrapper;
0 2 1 random Ljava/security/SecureRandom;
MethodParameters:
Name Flags
random
public byte[] generateWrappedKey(org.bouncycastle.operator.GenericKey);
descriptor: (Lorg/bouncycastle/operator/GenericKey;)[B
flags: (0x0001) ACC_PUBLIC
Code:
stack=5, locals=5, args_size=2
start local 0 start local 1 0: aload 1
invokestatic org.bouncycastle.operator.jcajce.OperatorUtils.getJceKey:(Lorg/bouncycastle/operator/GenericKey;)Ljava/security/Key;
astore 2
start local 2 1: aload 0
getfield org.bouncycastle.operator.jcajce.JceSymmetricKeyWrapper.helper:Lorg/bouncycastle/operator/jcajce/OperatorHelper;
aload 0
invokevirtual org.bouncycastle.operator.jcajce.JceSymmetricKeyWrapper.getAlgorithmIdentifier:()Lorg/bouncycastle/asn1/x509/AlgorithmIdentifier;
invokevirtual org.bouncycastle.asn1.x509.AlgorithmIdentifier.getAlgorithm:()Lorg/bouncycastle/asn1/ASN1ObjectIdentifier;
invokevirtual org.bouncycastle.operator.jcajce.OperatorHelper.createSymmetricWrapper:(Lorg/bouncycastle/asn1/ASN1ObjectIdentifier;)Ljavax/crypto/Cipher;
astore 3
start local 3 2: aload 3
iconst_3
aload 0
getfield org.bouncycastle.operator.jcajce.JceSymmetricKeyWrapper.wrappingKey:Ljavax/crypto/SecretKey;
aload 0
getfield org.bouncycastle.operator.jcajce.JceSymmetricKeyWrapper.random:Ljava/security/SecureRandom;
invokevirtual javax.crypto.Cipher.init:(ILjava/security/Key;Ljava/security/SecureRandom;)V
3: aload 3
aload 2
invokevirtual javax.crypto.Cipher.wrap:(Ljava/security/Key;)[B
4: areturn
5: StackMap locals: org.bouncycastle.operator.jcajce.JceSymmetricKeyWrapper org.bouncycastle.operator.GenericKey java.security.Key javax.crypto.Cipher
StackMap stack: java.security.GeneralSecurityException
astore 4
start local 4 6: new org.bouncycastle.operator.OperatorException
dup
new java.lang.StringBuilder
dup
ldc "cannot wrap key: "
invokespecial java.lang.StringBuilder.<init>:(Ljava/lang/String;)V
aload 4
invokevirtual java.security.GeneralSecurityException.getMessage:()Ljava/lang/String;
invokevirtual java.lang.StringBuilder.append:(Ljava/lang/String;)Ljava/lang/StringBuilder;
invokevirtual java.lang.StringBuilder.toString:()Ljava/lang/String;
aload 4
invokespecial org.bouncycastle.operator.OperatorException.<init>:(Ljava/lang/String;Ljava/lang/Throwable;)V
athrow
end local 4 end local 3 end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 7 0 this Lorg/bouncycastle/operator/jcajce/JceSymmetricKeyWrapper;
0 7 1 encryptionKey Lorg/bouncycastle/operator/GenericKey;
1 7 2 contentEncryptionKeySpec Ljava/security/Key;
2 7 3 keyEncryptionCipher Ljavax/crypto/Cipher;
6 7 4 e Ljava/security/GeneralSecurityException;
Exception table:
from to target type
2 4 5 Class java.security.GeneralSecurityException
Exceptions:
throws org.bouncycastle.operator.OperatorException
MethodParameters:
Name Flags
encryptionKey
private static org.bouncycastle.asn1.x509.AlgorithmIdentifier determineKeyEncAlg(javax.crypto.SecretKey);
descriptor: (Ljavax/crypto/SecretKey;)Lorg/bouncycastle/asn1/x509/AlgorithmIdentifier;
flags: (0x000a) ACC_PRIVATE, ACC_STATIC
Code:
stack=3, locals=1, args_size=1
start local 0 0: aload 0
invokeinterface javax.crypto.SecretKey.getAlgorithm:()Ljava/lang/String;
aload 0
invokeinterface javax.crypto.SecretKey.getEncoded:()[B
arraylength
bipush 8
imul
invokestatic org.bouncycastle.operator.jcajce.JceSymmetricKeyWrapper.determineKeyEncAlg:(Ljava/lang/String;I)Lorg/bouncycastle/asn1/x509/AlgorithmIdentifier;
areturn
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 1 0 key Ljavax/crypto/SecretKey;
MethodParameters:
Name Flags
key
static org.bouncycastle.asn1.x509.AlgorithmIdentifier determineKeyEncAlg(java.lang.String, int);
descriptor: (Ljava/lang/String;I)Lorg/bouncycastle/asn1/x509/AlgorithmIdentifier;
flags: (0x0008) ACC_STATIC
Code:
stack=7, locals=3, args_size=2
start local 0 start local 1 0: aload 0
ldc "DES"
invokevirtual java.lang.String.startsWith:(Ljava/lang/String;)Z
ifne 1
aload 0
ldc "TripleDES"
invokevirtual java.lang.String.startsWith:(Ljava/lang/String;)Z
ifeq 2
1: StackMap locals:
StackMap stack:
new org.bouncycastle.asn1.x509.AlgorithmIdentifier
dup
getstatic org.bouncycastle.asn1.pkcs.PKCSObjectIdentifiers.id_alg_CMS3DESwrap:Lorg/bouncycastle/asn1/ASN1ObjectIdentifier;
getstatic org.bouncycastle.asn1.DERNull.INSTANCE:Lorg/bouncycastle/asn1/DERNull;
invokespecial org.bouncycastle.asn1.x509.AlgorithmIdentifier.<init>:(Lorg/bouncycastle/asn1/ASN1ObjectIdentifier;Lorg/bouncycastle/asn1/ASN1Encodable;)V
areturn
2: StackMap locals:
StackMap stack:
aload 0
ldc "RC2"
invokevirtual java.lang.String.startsWith:(Ljava/lang/String;)Z
ifeq 6
3: new org.bouncycastle.asn1.x509.AlgorithmIdentifier
dup
new org.bouncycastle.asn1.ASN1ObjectIdentifier
dup
4: ldc "1.2.840.113549.1.9.16.3.7"
invokespecial org.bouncycastle.asn1.ASN1ObjectIdentifier.<init>:(Ljava/lang/String;)V
new org.bouncycastle.asn1.ASN1Integer
dup
ldc 58
invokespecial org.bouncycastle.asn1.ASN1Integer.<init>:(J)V
5: invokespecial org.bouncycastle.asn1.x509.AlgorithmIdentifier.<init>:(Lorg/bouncycastle/asn1/ASN1ObjectIdentifier;Lorg/bouncycastle/asn1/ASN1Encodable;)V
areturn
6: StackMap locals:
StackMap stack:
aload 0
ldc "AES"
invokevirtual java.lang.String.startsWith:(Ljava/lang/String;)Z
ifeq 18
7: iload 1
sipush 128
if_icmpne 10
8: getstatic org.bouncycastle.asn1.nist.NISTObjectIdentifiers.id_aes128_wrap:Lorg/bouncycastle/asn1/ASN1ObjectIdentifier;
astore 2
start local 2 9: goto 17
end local 2 10: StackMap locals:
StackMap stack:
iload 1
sipush 192
if_icmpne 13
11: getstatic org.bouncycastle.asn1.nist.NISTObjectIdentifiers.id_aes192_wrap:Lorg/bouncycastle/asn1/ASN1ObjectIdentifier;
astore 2
start local 2 12: goto 17
end local 2 13: StackMap locals:
StackMap stack:
iload 1
sipush 256
if_icmpne 16
14: getstatic org.bouncycastle.asn1.nist.NISTObjectIdentifiers.id_aes256_wrap:Lorg/bouncycastle/asn1/ASN1ObjectIdentifier;
astore 2
start local 2 15: goto 17
end local 2 16: StackMap locals:
StackMap stack:
new java.lang.IllegalArgumentException
dup
ldc "illegal keysize in AES"
invokespecial java.lang.IllegalArgumentException.<init>:(Ljava/lang/String;)V
athrow
start local 2 17: StackMap locals: org.bouncycastle.asn1.ASN1ObjectIdentifier
StackMap stack:
new org.bouncycastle.asn1.x509.AlgorithmIdentifier
dup
aload 2
invokespecial org.bouncycastle.asn1.x509.AlgorithmIdentifier.<init>:(Lorg/bouncycastle/asn1/ASN1ObjectIdentifier;)V
areturn
end local 2 18: StackMap locals:
StackMap stack:
aload 0
ldc "SEED"
invokevirtual java.lang.String.startsWith:(Ljava/lang/String;)Z
ifeq 22
19: new org.bouncycastle.asn1.x509.AlgorithmIdentifier
dup
20: getstatic org.bouncycastle.asn1.kisa.KISAObjectIdentifiers.id_npki_app_cmsSeed_wrap:Lorg/bouncycastle/asn1/ASN1ObjectIdentifier;
21: invokespecial org.bouncycastle.asn1.x509.AlgorithmIdentifier.<init>:(Lorg/bouncycastle/asn1/ASN1ObjectIdentifier;)V
areturn
22: StackMap locals:
StackMap stack:
aload 0
ldc "Camellia"
invokevirtual java.lang.String.startsWith:(Ljava/lang/String;)Z
ifeq 36
23: iload 1
sipush 128
if_icmpne 26
24: getstatic org.bouncycastle.asn1.ntt.NTTObjectIdentifiers.id_camellia128_wrap:Lorg/bouncycastle/asn1/ASN1ObjectIdentifier;
astore 2
start local 2 25: goto 35
end local 2 26: StackMap locals:
StackMap stack:
iload 1
sipush 192
if_icmpne 29
27: getstatic org.bouncycastle.asn1.ntt.NTTObjectIdentifiers.id_camellia192_wrap:Lorg/bouncycastle/asn1/ASN1ObjectIdentifier;
astore 2
start local 2 28: goto 35
end local 2 29: StackMap locals:
StackMap stack:
iload 1
sipush 256
if_icmpne 32
30: getstatic org.bouncycastle.asn1.ntt.NTTObjectIdentifiers.id_camellia256_wrap:Lorg/bouncycastle/asn1/ASN1ObjectIdentifier;
astore 2
start local 2 31: goto 35
end local 2 32: StackMap locals:
StackMap stack:
new java.lang.IllegalArgumentException
dup
33: ldc "illegal keysize in Camellia"
34: invokespecial java.lang.IllegalArgumentException.<init>:(Ljava/lang/String;)V
athrow
start local 2 35: StackMap locals: org.bouncycastle.asn1.ASN1ObjectIdentifier
StackMap stack:
new org.bouncycastle.asn1.x509.AlgorithmIdentifier
dup
aload 2
invokespecial org.bouncycastle.asn1.x509.AlgorithmIdentifier.<init>:(Lorg/bouncycastle/asn1/ASN1ObjectIdentifier;)V
areturn
end local 2 36: StackMap locals:
StackMap stack:
new java.lang.IllegalArgumentException
dup
ldc "unknown algorithm"
invokespecial java.lang.IllegalArgumentException.<init>:(Ljava/lang/String;)V
athrow
end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 37 0 algorithm Ljava/lang/String;
0 37 1 keySizeInBits I
9 10 2 wrapOid Lorg/bouncycastle/asn1/ASN1ObjectIdentifier;
12 13 2 wrapOid Lorg/bouncycastle/asn1/ASN1ObjectIdentifier;
15 16 2 wrapOid Lorg/bouncycastle/asn1/ASN1ObjectIdentifier;
17 18 2 wrapOid Lorg/bouncycastle/asn1/ASN1ObjectIdentifier;
25 26 2 wrapOid Lorg/bouncycastle/asn1/ASN1ObjectIdentifier;
28 29 2 wrapOid Lorg/bouncycastle/asn1/ASN1ObjectIdentifier;
31 32 2 wrapOid Lorg/bouncycastle/asn1/ASN1ObjectIdentifier;
35 36 2 wrapOid Lorg/bouncycastle/asn1/ASN1ObjectIdentifier;
MethodParameters:
Name Flags
algorithm
keySizeInBits
}
SourceFile: "JceSymmetricKeyWrapper.java"