public class sun.security.util.Password
minor version: 0
major version: 59
flags: flags: (0x0021) ACC_PUBLIC, ACC_SUPER
this_class: sun.security.util.Password
super_class: java.lang.Object
{
private static volatile java.nio.charset.CharsetEncoder enc;
descriptor: Ljava/nio/charset/CharsetEncoder;
flags: (0x004a) ACC_PRIVATE, ACC_STATIC, ACC_VOLATILE
public void <init>();
descriptor: ()V
flags: (0x0001) ACC_PUBLIC
Code:
stack=1, locals=1, args_size=1
start local 0 0: aload 0
invokespecial java.lang.Object.<init>:()V
return
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 1 0 this Lsun/security/util/Password;
public static char[] readPassword(java.io.InputStream);
descriptor: (Ljava/io/InputStream;)[C
flags: (0x0009) ACC_PUBLIC, ACC_STATIC
Code:
stack=5, locals=13, args_size=1
start local 0 0: aconst_null
astore 1
start local 1 1: aconst_null
astore 2
start local 2 2: aconst_null
astore 3
start local 3 3: aload 0
getstatic java.lang.System.in:Ljava/io/InputStream;
if_acmpne 13
invokestatic java.lang.System.console:()Ljava/io/Console;
dup
astore 3
ifnull 13
4: aload 3
invokevirtual java.io.Console.readPassword:()[C
astore 1
5: aload 1
ifnull 11
aload 1
arraylength
ifne 11
6: aload 1
ifnull 8
7: aload 1
bipush 32
invokestatic java.util.Arrays.fill:([CC)V
8: StackMap locals: char[] byte[] java.io.Console
StackMap stack:
aload 2
ifnull 10
9: aload 2
iconst_0
invokestatic java.util.Arrays.fill:([BB)V
10: StackMap locals:
StackMap stack:
aconst_null
areturn
11: StackMap locals:
StackMap stack:
aload 1
invokestatic sun.security.util.Password.convertToBytes:([C)[B
astore 2
12: new java.io.ByteArrayInputStream
dup
aload 2
invokespecial java.io.ByteArrayInputStream.<init>:([B)V
astore 0
13: StackMap locals:
StackMap stack:
sipush 128
newarray 5
dup
astore 4
start local 4 14: astore 5
start local 5 15: aload 5
arraylength
istore 6
start local 6 16: iconst_0
istore 7
start local 7 17: iconst_0
istore 9
start local 9 18: goto 38
19: StackMap locals: java.io.InputStream char[] byte[] java.io.Console char[] char[] int int top int
StackMap stack:
aload 0
invokevirtual java.io.InputStream.read:()I
dup
istore 8
start local 8 20: lookupswitch { // 3
-1: 21
10: 21
13: 23
default: 31
}
21: StackMap locals: java.io.InputStream char[] byte[] java.io.Console char[] char[] int int int int
StackMap stack:
iconst_1
istore 9
22: goto 38
23: StackMap locals:
StackMap stack:
aload 0
invokevirtual java.io.InputStream.read:()I
istore 10
start local 10 24: iload 10
bipush 10
if_icmpeq 29
iload 10
iconst_m1
if_icmpeq 29
25: aload 0
instanceof java.io.PushbackInputStream
ifne 27
26: new java.io.PushbackInputStream
dup
aload 0
invokespecial java.io.PushbackInputStream.<init>:(Ljava/io/InputStream;)V
astore 0
27: StackMap locals: int
StackMap stack:
aload 0
checkcast java.io.PushbackInputStream
iload 10
invokevirtual java.io.PushbackInputStream.unread:(I)V
28: goto 31
29: StackMap locals:
StackMap stack:
iconst_1
istore 9
30: goto 38
end local 10 31: StackMap locals:
StackMap stack:
iinc 6 -1
iload 6
ifge 37
32: iload 7
sipush 128
iadd
newarray 5
astore 5
33: aload 5
arraylength
iload 7
isub
iconst_1
isub
istore 6
34: aload 4
iconst_0
aload 5
iconst_0
iload 7
invokestatic java.lang.System.arraycopy:(Ljava/lang/Object;ILjava/lang/Object;II)V
35: aload 4
bipush 32
invokestatic java.util.Arrays.fill:([CC)V
36: aload 5
astore 4
37: StackMap locals:
StackMap stack:
aload 5
iload 7
iinc 7 1
iload 8
i2c
castore
end local 8 38: StackMap locals: java.io.InputStream char[] byte[] java.io.Console char[] char[] int int top int
StackMap stack:
iload 9
ifeq 19
39: iload 7
ifne 45
40: aload 1
ifnull 42
41: aload 1
bipush 32
invokestatic java.util.Arrays.fill:([CC)V
42: StackMap locals:
StackMap stack:
aload 2
ifnull 44
43: aload 2
iconst_0
invokestatic java.util.Arrays.fill:([BB)V
44: StackMap locals:
StackMap stack:
aconst_null
areturn
45: StackMap locals:
StackMap stack:
iload 7
newarray 5
astore 10
start local 10 46: aload 5
iconst_0
aload 10
iconst_0
iload 7
invokestatic java.lang.System.arraycopy:(Ljava/lang/Object;ILjava/lang/Object;II)V
47: aload 5
bipush 32
invokestatic java.util.Arrays.fill:([CC)V
48: aload 10
astore 12
49: aload 1
ifnull 51
50: aload 1
bipush 32
invokestatic java.util.Arrays.fill:([CC)V
51: StackMap locals: java.io.InputStream char[] byte[] java.io.Console char[] char[] int int top int char[] top char[]
StackMap stack:
aload 2
ifnull 53
52: aload 2
iconst_0
invokestatic java.util.Arrays.fill:([BB)V
53: StackMap locals:
StackMap stack:
aload 12
areturn
end local 10 end local 9 end local 7 end local 6 end local 5 end local 4 end local 3 54: StackMap locals: java.io.InputStream char[] byte[]
StackMap stack: java.lang.Throwable
astore 11
55: aload 1
ifnull 57
56: aload 1
bipush 32
invokestatic java.util.Arrays.fill:([CC)V
57: StackMap locals: java.io.InputStream char[] byte[] top top top top top top top top java.lang.Throwable
StackMap stack:
aload 2
ifnull 59
58: aload 2
iconst_0
invokestatic java.util.Arrays.fill:([BB)V
59: StackMap locals:
StackMap stack:
aload 11
athrow
end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 60 0 in Ljava/io/InputStream;
1 60 1 consoleEntered [C
2 60 2 consoleBytes [B
3 54 3 con Ljava/io/Console;
14 54 4 lineBuffer [C
15 54 5 buf [C
16 54 6 room I
17 54 7 offset I
20 38 8 c I
18 54 9 done Z
24 31 10 c2 I
46 54 10 ret [C
Exception table:
from to target type
2 6 54 any
11 40 54 any
45 49 54 any
Exceptions:
throws java.io.IOException
MethodParameters:
Name Flags
in
private static byte[] convertToBytes(char[]);
descriptor: ([C)[B
flags: (0x000a) ACC_PRIVATE, ACC_STATIC
Code:
stack=4, locals=4, args_size=1
start local 0 0: getstatic sun.security.util.Password.enc:Ljava/nio/charset/CharsetEncoder;
ifnonnull 12
1: ldc Lsun/security/util/Password;
dup
astore 1
monitorenter
2: invokestatic sun.misc.SharedSecrets.getJavaIOAccess:()Lsun/misc/JavaIOAccess;
3: invokeinterface sun.misc.JavaIOAccess.charset:()Ljava/nio/charset/Charset;
4: invokevirtual java.nio.charset.Charset.newEncoder:()Ljava/nio/charset/CharsetEncoder;
5: getstatic java.nio.charset.CodingErrorAction.REPLACE:Ljava/nio/charset/CodingErrorAction;
invokevirtual java.nio.charset.CharsetEncoder.onMalformedInput:(Ljava/nio/charset/CodingErrorAction;)Ljava/nio/charset/CharsetEncoder;
6: getstatic java.nio.charset.CodingErrorAction.REPLACE:Ljava/nio/charset/CodingErrorAction;
invokevirtual java.nio.charset.CharsetEncoder.onUnmappableCharacter:(Ljava/nio/charset/CodingErrorAction;)Ljava/nio/charset/CharsetEncoder;
7: putstatic sun.security.util.Password.enc:Ljava/nio/charset/CharsetEncoder;
8: aload 1
monitorexit
9: goto 12
StackMap locals: char[] java.lang.Class
StackMap stack: java.lang.Throwable
10: aload 1
monitorexit
11: athrow
12: StackMap locals:
StackMap stack:
getstatic sun.security.util.Password.enc:Ljava/nio/charset/CharsetEncoder;
invokevirtual java.nio.charset.CharsetEncoder.maxBytesPerChar:()F
aload 0
arraylength
i2f
fmul
f2i
newarray 8
astore 1
start local 1 13: aload 1
invokestatic java.nio.ByteBuffer.wrap:([B)Ljava/nio/ByteBuffer;
astore 2
start local 2 14: getstatic sun.security.util.Password.enc:Ljava/nio/charset/CharsetEncoder;
dup
astore 3
monitorenter
15: getstatic sun.security.util.Password.enc:Ljava/nio/charset/CharsetEncoder;
invokevirtual java.nio.charset.CharsetEncoder.reset:()Ljava/nio/charset/CharsetEncoder;
aload 0
invokestatic java.nio.CharBuffer.wrap:([C)Ljava/nio/CharBuffer;
aload 2
iconst_1
invokevirtual java.nio.charset.CharsetEncoder.encode:(Ljava/nio/CharBuffer;Ljava/nio/ByteBuffer;Z)Ljava/nio/charset/CoderResult;
pop
16: aload 3
monitorexit
17: goto 20
StackMap locals: char[] byte[] java.nio.ByteBuffer java.nio.charset.CharsetEncoder
StackMap stack: java.lang.Throwable
18: aload 3
monitorexit
19: athrow
20: StackMap locals:
StackMap stack:
aload 2
invokevirtual java.nio.ByteBuffer.position:()I
aload 1
arraylength
if_icmpge 22
21: aload 1
aload 2
invokevirtual java.nio.ByteBuffer.position:()I
bipush 10
bastore
22: StackMap locals:
StackMap stack:
aload 1
areturn
end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 23 0 pass [C
13 23 1 ba [B
14 23 2 bb Ljava/nio/ByteBuffer;
Exception table:
from to target type
2 9 10 any
10 11 10 any
15 17 18 any
18 19 18 any
MethodParameters:
Name Flags
pass
}
SourceFile: "Password.java"