public class org.sonatype.plexus.components.cipher.PBECipher
minor version: 0
major version: 59
flags: flags: (0x0021) ACC_PUBLIC, ACC_SUPER
this_class: org.sonatype.plexus.components.cipher.PBECipher
super_class: java.lang.Object
{
protected static final java.lang.String STRING_ENCODING;
descriptor: Ljava/lang/String;
flags: (0x001c) ACC_PROTECTED, ACC_STATIC, ACC_FINAL
ConstantValue: "UTF8"
protected static final int SPICE_SIZE;
descriptor: I
flags: (0x001c) ACC_PROTECTED, ACC_STATIC, ACC_FINAL
ConstantValue: 16
protected static final int SALT_SIZE;
descriptor: I
flags: (0x001c) ACC_PROTECTED, ACC_STATIC, ACC_FINAL
ConstantValue: 8
protected static final int CHUNK_SIZE;
descriptor: I
flags: (0x001c) ACC_PROTECTED, ACC_STATIC, ACC_FINAL
ConstantValue: 16
protected static final byte WIPER;
descriptor: B
flags: (0x001c) ACC_PROTECTED, ACC_STATIC, ACC_FINAL
ConstantValue: 0
protected static final java.lang.String DIGEST_ALG;
descriptor: Ljava/lang/String;
flags: (0x001c) ACC_PROTECTED, ACC_STATIC, ACC_FINAL
ConstantValue: "SHA-256"
protected static final java.lang.String KEY_ALG;
descriptor: Ljava/lang/String;
flags: (0x001c) ACC_PROTECTED, ACC_STATIC, ACC_FINAL
ConstantValue: "AES"
protected static final java.lang.String CIPHER_ALG;
descriptor: Ljava/lang/String;
flags: (0x001c) ACC_PROTECTED, ACC_STATIC, ACC_FINAL
ConstantValue: "AES/CBC/PKCS5Padding"
protected static int PBE_ITERATIONS;
descriptor: I
flags: (0x000c) ACC_PROTECTED, ACC_STATIC
protected java.security.MessageDigest _digester;
descriptor: Ljava/security/MessageDigest;
flags: (0x0004) ACC_PROTECTED
protected java.security.SecureRandom _secureRandom;
descriptor: Ljava/security/SecureRandom;
flags: (0x0004) ACC_PROTECTED
protected boolean _onLinux;
descriptor: Z
flags: (0x0004) ACC_PROTECTED
static void <clinit>();
descriptor: ()V
flags: (0x0008) ACC_STATIC
Code:
stack=1, locals=0, args_size=0
0: sipush 1000
putstatic org.sonatype.plexus.components.cipher.PBECipher.PBE_ITERATIONS:I
return
LocalVariableTable:
Start End Slot Name Signature
public void <init>();
descriptor: ()V
flags: (0x0001) ACC_PUBLIC
Code:
stack=3, locals=2, args_size=1
start local 0 0: aload 0
invokespecial java.lang.Object.<init>:()V
1: aload 0
iconst_0
putfield org.sonatype.plexus.components.cipher.PBECipher._onLinux:Z
2: aload 0
ldc "SHA-256"
invokestatic java.security.MessageDigest.getInstance:(Ljava/lang/String;)Ljava/security/MessageDigest;
putfield org.sonatype.plexus.components.cipher.PBECipher._digester:Ljava/security/MessageDigest;
3: ldc "os.name"
ldc "blah"
invokestatic java.lang.System.getProperty:(Ljava/lang/String;Ljava/lang/String;)Ljava/lang/String;
invokevirtual java.lang.String.toLowerCase:()Ljava/lang/String;
ldc "linux"
invokevirtual java.lang.String.indexOf:(Ljava/lang/String;)I
iconst_m1
if_icmpeq 5
4: aload 0
iconst_1
putfield org.sonatype.plexus.components.cipher.PBECipher._onLinux:Z
5: StackMap locals: org.sonatype.plexus.components.cipher.PBECipher
StackMap stack:
aload 0
getfield org.sonatype.plexus.components.cipher.PBECipher._onLinux:Z
ifeq 8
6: ldc "securerandom.source"
ldc "file:/dev/./urandom"
invokestatic java.lang.System.setProperty:(Ljava/lang/String;Ljava/lang/String;)Ljava/lang/String;
pop
7: goto 12
8: StackMap locals:
StackMap stack:
aload 0
new java.security.SecureRandom
dup
invokespecial java.security.SecureRandom.<init>:()V
putfield org.sonatype.plexus.components.cipher.PBECipher._secureRandom:Ljava/security/SecureRandom;
9: goto 12
10: StackMap locals:
StackMap stack: java.security.NoSuchAlgorithmException
astore 1
start local 1 11: new org.sonatype.plexus.components.cipher.PlexusCipherException
dup
aload 1
invokespecial org.sonatype.plexus.components.cipher.PlexusCipherException.<init>:(Ljava/lang/Throwable;)V
athrow
end local 1 12: StackMap locals:
StackMap stack:
return
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 13 0 this Lorg/sonatype/plexus/components/cipher/PBECipher;
11 12 1 e Ljava/security/NoSuchAlgorithmException;
Exception table:
from to target type
2 9 10 Class java.security.NoSuchAlgorithmException
Exceptions:
throws org.sonatype.plexus.components.cipher.PlexusCipherException
private byte[] getSalt(int);
descriptor: (I)[B
flags: (0x0002) ACC_PRIVATE
Code:
stack=4, locals=4, args_size=2
start local 0 start local 1 0: aconst_null
astore 2
start local 2 1: aload 0
getfield org.sonatype.plexus.components.cipher.PBECipher._secureRandom:Ljava/security/SecureRandom;
ifnull 5
2: aload 0
getfield org.sonatype.plexus.components.cipher.PBECipher._secureRandom:Ljava/security/SecureRandom;
invokestatic java.lang.System.currentTimeMillis:()J
invokevirtual java.security.SecureRandom.setSeed:(J)V
3: aload 0
getfield org.sonatype.plexus.components.cipher.PBECipher._secureRandom:Ljava/security/SecureRandom;
iload 1
invokevirtual java.security.SecureRandom.generateSeed:(I)[B
astore 2
4: goto 8
5: StackMap locals: byte[]
StackMap stack:
iload 1
newarray 8
astore 2
6: new java.util.Random
dup
invokestatic java.lang.System.currentTimeMillis:()J
invokespecial java.util.Random.<init>:(J)V
astore 3
start local 3 7: aload 3
aload 2
invokevirtual java.util.Random.nextBytes:([B)V
end local 3 8: StackMap locals:
StackMap stack:
aload 2
areturn
end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 9 0 this Lorg/sonatype/plexus/components/cipher/PBECipher;
0 9 1 sz I
1 9 2 res [B
7 8 3 r Ljava/util/Random;
Exceptions:
throws java.security.NoSuchAlgorithmException, java.security.NoSuchProviderException
MethodParameters:
Name Flags
sz final
public java.lang.String encrypt64(java.lang.String, java.lang.String);
descriptor: (Ljava/lang/String;Ljava/lang/String;)Ljava/lang/String;
flags: (0x0001) ACC_PUBLIC
Code:
stack=5, locals=13, args_size=3
start local 0 start local 1 start local 2 0: aload 1
ldc "UTF8"
invokevirtual java.lang.String.getBytes:(Ljava/lang/String;)[B
astore 3
start local 3 1: aload 0
bipush 8
invokevirtual org.sonatype.plexus.components.cipher.PBECipher.getSalt:(I)[B
astore 4
start local 4 2: aload 0
getfield org.sonatype.plexus.components.cipher.PBECipher._secureRandom:Ljava/security/SecureRandom;
ifnull 4
3: new java.security.SecureRandom
dup
invokespecial java.security.SecureRandom.<init>:()V
aload 4
invokevirtual java.security.SecureRandom.nextBytes:([B)V
4: StackMap locals: byte[] byte[]
StackMap stack:
aload 0
aload 2
ldc "UTF8"
invokevirtual java.lang.String.getBytes:(Ljava/lang/String;)[B
aload 4
iconst_1
invokevirtual org.sonatype.plexus.components.cipher.PBECipher.createCipher:([B[BI)Ljavax/crypto/Cipher;
astore 5
start local 5 5: aload 5
aload 3
invokevirtual javax.crypto.Cipher.doFinal:([B)[B
astore 6
start local 6 6: aload 6
arraylength
istore 7
start local 7 7: bipush 16
bipush 8
iload 7
iadd
iconst_1
iadd
bipush 16
irem
isub
i2b
istore 8
start local 8 8: bipush 8
iload 7
iadd
iload 8
iadd
iconst_1
iadd
istore 9
start local 9 9: aload 0
iload 9
invokevirtual org.sonatype.plexus.components.cipher.PBECipher.getSalt:(I)[B
astore 10
start local 10 10: aload 4
iconst_0
aload 10
iconst_0
bipush 8
invokestatic java.lang.System.arraycopy:(Ljava/lang/Object;ILjava/lang/Object;II)V
11: aload 10
bipush 8
iload 8
bastore
12: aload 6
iconst_0
aload 10
bipush 9
iload 7
invokestatic java.lang.System.arraycopy:(Ljava/lang/Object;ILjava/lang/Object;II)V
13: aload 10
invokestatic org.sonatype.plexus.components.cipher.Base64.encodeBase64:([B)[B
astore 11
start local 11 14: new java.lang.String
dup
aload 11
ldc "UTF8"
invokespecial java.lang.String.<init>:([BLjava/lang/String;)V
astore 12
start local 12 15: aload 12
16: areturn
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 17: StackMap locals: org.sonatype.plexus.components.cipher.PBECipher java.lang.String java.lang.String
StackMap stack: java.lang.Exception
astore 3
start local 3 18: new org.sonatype.plexus.components.cipher.PlexusCipherException
dup
aload 3
invokespecial org.sonatype.plexus.components.cipher.PlexusCipherException.<init>:(Ljava/lang/Throwable;)V
athrow
end local 3 end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 19 0 this Lorg/sonatype/plexus/components/cipher/PBECipher;
0 19 1 clearText Ljava/lang/String;
0 19 2 password Ljava/lang/String;
1 17 3 clearBytes [B
2 17 4 salt [B
5 17 5 cipher Ljavax/crypto/Cipher;
6 17 6 encryptedBytes [B
7 17 7 len I
8 17 8 padLen B
9 17 9 totalLen I
10 17 10 allEncryptedBytes [B
14 17 11 encryptedTextBytes [B
15 17 12 encryptedText Ljava/lang/String;
18 19 3 e Ljava/lang/Exception;
Exception table:
from to target type
0 16 17 Class java.lang.Exception
Exceptions:
throws org.sonatype.plexus.components.cipher.PlexusCipherException
MethodParameters:
Name Flags
clearText final
password final
public java.lang.String decrypt64(java.lang.String, java.lang.String);
descriptor: (Ljava/lang/String;Ljava/lang/String;)Ljava/lang/String;
flags: (0x0001) ACC_PUBLIC
Code:
stack=5, locals=11, args_size=3
start local 0 start local 1 start local 2 0: aload 1
invokevirtual java.lang.String.getBytes:()[B
invokestatic org.sonatype.plexus.components.cipher.Base64.decodeBase64:([B)[B
astore 3
start local 3 1: aload 3
arraylength
istore 4
start local 4 2: bipush 8
newarray 8
astore 5
start local 5 3: aload 3
iconst_0
aload 5
iconst_0
bipush 8
invokestatic java.lang.System.arraycopy:(Ljava/lang/Object;ILjava/lang/Object;II)V
4: aload 3
bipush 8
baload
istore 6
start local 6 5: iload 4
bipush 8
isub
iconst_1
isub
iload 6
isub
newarray 8
astore 7
start local 7 6: aload 3
bipush 9
aload 7
iconst_0
aload 7
arraylength
invokestatic java.lang.System.arraycopy:(Ljava/lang/Object;ILjava/lang/Object;II)V
7: aload 0
aload 2
ldc "UTF8"
invokevirtual java.lang.String.getBytes:(Ljava/lang/String;)[B
aload 5
iconst_2
invokevirtual org.sonatype.plexus.components.cipher.PBECipher.createCipher:([B[BI)Ljavax/crypto/Cipher;
astore 8
start local 8 8: aload 8
aload 7
invokevirtual javax.crypto.Cipher.doFinal:([B)[B
astore 9
start local 9 9: new java.lang.String
dup
aload 9
ldc "UTF8"
invokespecial java.lang.String.<init>:([BLjava/lang/String;)V
astore 10
start local 10 10: aload 10
11: 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 12: StackMap locals:
StackMap stack: java.lang.Exception
astore 3
start local 3 13: new org.sonatype.plexus.components.cipher.PlexusCipherException
dup
aload 3
invokespecial org.sonatype.plexus.components.cipher.PlexusCipherException.<init>:(Ljava/lang/Throwable;)V
athrow
end local 3 end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 14 0 this Lorg/sonatype/plexus/components/cipher/PBECipher;
0 14 1 encryptedText Ljava/lang/String;
0 14 2 password Ljava/lang/String;
1 12 3 allEncryptedBytes [B
2 12 4 totalLen I
3 12 5 salt [B
5 12 6 padLen B
6 12 7 encryptedBytes [B
8 12 8 cipher Ljavax/crypto/Cipher;
9 12 9 clearBytes [B
10 12 10 clearText Ljava/lang/String;
13 14 3 e Ljava/lang/Exception;
Exception table:
from to target type
0 11 12 Class java.lang.Exception
Exceptions:
throws org.sonatype.plexus.components.cipher.PlexusCipherException
MethodParameters:
Name Flags
encryptedText final
password final
private javax.crypto.Cipher createCipher(byte[], byte[], int);
descriptor: ([B[BI)Ljavax/crypto/Cipher;
flags: (0x0002) ACC_PRIVATE
Code:
stack=6, locals=10, args_size=4
start local 0 start local 1 start local 2 start local 3 0: aload 0
getfield org.sonatype.plexus.components.cipher.PBECipher._digester:Ljava/security/MessageDigest;
invokevirtual java.security.MessageDigest.reset:()V
1: bipush 32
newarray 8
astore 4
start local 4 2: aload 2
ifnull 3
aload 2
arraylength
ifne 4
3: StackMap locals: byte[]
StackMap stack:
aconst_null
astore 2
4: StackMap locals:
StackMap stack:
iconst_0
istore 6
start local 6 5: goto 20
6: StackMap locals: org.sonatype.plexus.components.cipher.PBECipher byte[] byte[] int byte[] top int
StackMap stack:
aload 0
getfield org.sonatype.plexus.components.cipher.PBECipher._digester:Ljava/security/MessageDigest;
aload 1
invokevirtual java.security.MessageDigest.update:([B)V
7: aload 2
ifnull 9
8: aload 0
getfield org.sonatype.plexus.components.cipher.PBECipher._digester:Ljava/security/MessageDigest;
aload 2
iconst_0
bipush 8
invokevirtual java.security.MessageDigest.update:([BII)V
9: StackMap locals:
StackMap stack:
aload 0
getfield org.sonatype.plexus.components.cipher.PBECipher._digester:Ljava/security/MessageDigest;
invokevirtual java.security.MessageDigest.digest:()[B
astore 5
start local 5 10: aload 4
arraylength
iload 6
isub
istore 7
start local 7 11: aload 5
arraylength
iload 7
if_icmple 15
12: iload 7
newarray 8
astore 8
start local 8 13: aload 5
iconst_0
aload 8
iconst_0
aload 8
arraylength
invokestatic java.lang.System.arraycopy:(Ljava/lang/Object;ILjava/lang/Object;II)V
14: aload 8
astore 5
end local 8 15: StackMap locals: org.sonatype.plexus.components.cipher.PBECipher byte[] byte[] int byte[] byte[] int int
StackMap stack:
aload 5
iconst_0
aload 4
iload 6
aload 5
arraylength
invokestatic java.lang.System.arraycopy:(Ljava/lang/Object;ILjava/lang/Object;II)V
16: iload 6
aload 5
arraylength
iadd
istore 6
17: iload 6
aload 4
arraylength
if_icmpge 20
18: aload 0
getfield org.sonatype.plexus.components.cipher.PBECipher._digester:Ljava/security/MessageDigest;
invokevirtual java.security.MessageDigest.reset:()V
19: aload 0
getfield org.sonatype.plexus.components.cipher.PBECipher._digester:Ljava/security/MessageDigest;
aload 5
invokevirtual java.security.MessageDigest.update:([B)V
end local 7 end local 5 20: StackMap locals: org.sonatype.plexus.components.cipher.PBECipher byte[] byte[] int byte[] top int
StackMap stack:
iload 6
aload 4
arraylength
if_icmplt 6
21: bipush 16
newarray 8
astore 7
start local 7 22: bipush 16
newarray 8
astore 8
start local 8 23: aload 4
iconst_0
aload 7
iconst_0
aload 7
arraylength
invokestatic java.lang.System.arraycopy:(Ljava/lang/Object;ILjava/lang/Object;II)V
24: aload 4
aload 7
arraylength
aload 8
iconst_0
aload 8
arraylength
invokestatic java.lang.System.arraycopy:(Ljava/lang/Object;ILjava/lang/Object;II)V
25: ldc "AES/CBC/PKCS5Padding"
invokestatic javax.crypto.Cipher.getInstance:(Ljava/lang/String;)Ljavax/crypto/Cipher;
astore 9
start local 9 26: aload 9
iload 3
new javax.crypto.spec.SecretKeySpec
dup
aload 7
ldc "AES"
invokespecial javax.crypto.spec.SecretKeySpec.<init>:([BLjava/lang/String;)V
new javax.crypto.spec.IvParameterSpec
dup
aload 8
invokespecial javax.crypto.spec.IvParameterSpec.<init>:([B)V
invokevirtual javax.crypto.Cipher.init:(ILjava/security/Key;Ljava/security/spec/AlgorithmParameterSpec;)V
27: aload 9
areturn
end local 9 end local 8 end local 7 end local 6 end local 4 end local 3 end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 28 0 this Lorg/sonatype/plexus/components/cipher/PBECipher;
0 28 1 pwdAsBytes [B
0 28 2 salt [B
0 28 3 mode I
2 28 4 keyAndIv [B
10 20 5 result [B
5 28 6 currentPos I
11 20 7 stillNeed I
13 15 8 b [B
22 28 7 key [B
23 28 8 iv [B
26 28 9 cipher Ljavax/crypto/Cipher;
Exceptions:
throws java.security.NoSuchAlgorithmException, javax.crypto.NoSuchPaddingException, java.security.InvalidKeyException, java.security.InvalidAlgorithmParameterException
MethodParameters:
Name Flags
pwdAsBytes final
salt
mode final
}
SourceFile: "PBECipher.java"