public class org.apache.tomcat.util.net.jsse.PEMFile
minor version: 0
major version: 59
flags: flags: (0x0021) ACC_PUBLIC, ACC_SUPER
this_class: org.apache.tomcat.util.net.jsse.PEMFile
super_class: java.lang.Object
{
private static final org.apache.tomcat.util.res.StringManager sm;
descriptor: Lorg/apache/tomcat/util/res/StringManager;
flags: (0x001a) ACC_PRIVATE, ACC_STATIC, ACC_FINAL
private static final byte[] OID_EC_PUBLIC_KEY;
descriptor: [B
flags: (0x001a) ACC_PRIVATE, ACC_STATIC, ACC_FINAL
private java.lang.String filename;
descriptor: Ljava/lang/String;
flags: (0x0002) ACC_PRIVATE
private java.util.List<java.security.cert.X509Certificate> certificates;
descriptor: Ljava/util/List;
flags: (0x0002) ACC_PRIVATE
Signature: Ljava/util/List<Ljava/security/cert/X509Certificate;>;
private java.security.PrivateKey privateKey;
descriptor: Ljava/security/PrivateKey;
flags: (0x0002) ACC_PRIVATE
static void <clinit>();
descriptor: ()V
flags: (0x0008) ACC_STATIC
Code:
stack=4, locals=0, args_size=0
0: ldc Lorg/apache/tomcat/util/net/jsse/PEMFile;
invokestatic org.apache.tomcat.util.res.StringManager.getManager:(Ljava/lang/Class;)Lorg/apache/tomcat/util/res/StringManager;
putstatic org.apache.tomcat.util.net.jsse.PEMFile.sm:Lorg/apache/tomcat/util/res/StringManager;
1: bipush 9
newarray 8
dup
iconst_0
bipush 6
bastore
dup
iconst_1
bipush 7
bastore
dup
iconst_2
bipush 42
bastore
dup
iconst_3
bipush -122
bastore
dup
iconst_4
bipush 72
bastore
dup
iconst_5
bipush -50
bastore
dup
bipush 6
bipush 61
bastore
dup
bipush 7
iconst_2
bastore
dup
bipush 8
iconst_1
bastore
2: putstatic org.apache.tomcat.util.net.jsse.PEMFile.OID_EC_PUBLIC_KEY:[B
3: return
LocalVariableTable:
Start End Slot Name Signature
public static java.lang.String toPEM(java.security.cert.X509Certificate);
descriptor: (Ljava/security/cert/X509Certificate;)Ljava/lang/String;
flags: (0x0009) ACC_PUBLIC, ACC_STATIC
Code:
stack=3, locals=3, args_size=1
start local 0 0: new java.lang.StringBuilder
dup
invokespecial java.lang.StringBuilder.<init>:()V
astore 1
start local 1 1: aload 1
ldc "-----BEGIN CERTIFICATE-----"
invokevirtual java.lang.StringBuilder.append:(Ljava/lang/String;)Ljava/lang/StringBuilder;
pop
2: aload 1
invokestatic java.lang.System.lineSeparator:()Ljava/lang/String;
invokevirtual java.lang.StringBuilder.append:(Ljava/lang/String;)Ljava/lang/StringBuilder;
pop
3: new org.apache.tomcat.util.codec.binary.Base64
dup
bipush 64
invokespecial org.apache.tomcat.util.codec.binary.Base64.<init>:(I)V
astore 2
start local 2 4: aload 1
aload 2
aload 0
invokevirtual java.security.cert.X509Certificate.getEncoded:()[B
invokevirtual org.apache.tomcat.util.codec.binary.Base64.encodeAsString:([B)Ljava/lang/String;
invokevirtual java.lang.StringBuilder.append:(Ljava/lang/String;)Ljava/lang/StringBuilder;
pop
5: aload 1
ldc "-----END CERTIFICATE-----"
invokevirtual java.lang.StringBuilder.append:(Ljava/lang/String;)Ljava/lang/StringBuilder;
pop
6: aload 1
invokevirtual java.lang.StringBuilder.toString:()Ljava/lang/String;
areturn
end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 7 0 certificate Ljava/security/cert/X509Certificate;
1 7 1 result Ljava/lang/StringBuilder;
4 7 2 b64 Lorg/apache/tomcat/util/codec/binary/Base64;
Exceptions:
throws java.security.cert.CertificateEncodingException
MethodParameters:
Name Flags
certificate
public java.util.List<java.security.cert.X509Certificate> getCertificates();
descriptor: ()Ljava/util/List;
flags: (0x0001) ACC_PUBLIC
Code:
stack=1, locals=1, args_size=1
start local 0 0: aload 0
getfield org.apache.tomcat.util.net.jsse.PEMFile.certificates:Ljava/util/List;
areturn
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 1 0 this Lorg/apache/tomcat/util/net/jsse/PEMFile;
Signature: ()Ljava/util/List<Ljava/security/cert/X509Certificate;>;
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 org.apache.tomcat.util.net.jsse.PEMFile.privateKey:Ljava/security/PrivateKey;
areturn
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 1 0 this Lorg/apache/tomcat/util/net/jsse/PEMFile;
public void <init>(java.lang.String);
descriptor: (Ljava/lang/String;)V
flags: (0x0001) ACC_PUBLIC
Code:
stack=3, locals=2, args_size=2
start local 0 start local 1 0: aload 0
aload 1
aconst_null
invokespecial org.apache.tomcat.util.net.jsse.PEMFile.<init>:(Ljava/lang/String;Ljava/lang/String;)V
1: return
end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 2 0 this Lorg/apache/tomcat/util/net/jsse/PEMFile;
0 2 1 filename Ljava/lang/String;
Exceptions:
throws java.io.IOException, java.security.GeneralSecurityException
MethodParameters:
Name Flags
filename
public void <init>(java.lang.String, java.lang.String);
descriptor: (Ljava/lang/String;Ljava/lang/String;)V
flags: (0x0001) ACC_PUBLIC
Code:
stack=4, locals=3, args_size=3
start local 0 start local 1 start local 2 0: aload 0
aload 1
aload 2
aconst_null
invokespecial org.apache.tomcat.util.net.jsse.PEMFile.<init>:(Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;)V
1: return
end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 2 0 this Lorg/apache/tomcat/util/net/jsse/PEMFile;
0 2 1 filename Ljava/lang/String;
0 2 2 password Ljava/lang/String;
Exceptions:
throws java.io.IOException, java.security.GeneralSecurityException
MethodParameters:
Name Flags
filename
password
public void <init>(java.lang.String, java.lang.String, java.lang.String);
descriptor: (Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;)V
flags: (0x0001) ACC_PUBLIC
Code:
stack=6, locals=11, args_size=4
start local 0 start local 1 start local 2 start local 3 0: aload 0
invokespecial java.lang.Object.<init>:()V
1: aload 0
new java.util.ArrayList
dup
invokespecial java.util.ArrayList.<init>:()V
putfield org.apache.tomcat.util.net.jsse.PEMFile.certificates:Ljava/util/List;
2: aload 0
aload 1
putfield org.apache.tomcat.util.net.jsse.PEMFile.filename:Ljava/lang/String;
3: new java.util.ArrayList
dup
invokespecial java.util.ArrayList.<init>:()V
astore 4
start local 4 4: aconst_null
astore 5
aconst_null
astore 6
5: invokestatic org.apache.tomcat.util.file.ConfigFileLoader.getSource:()Lorg/apache/tomcat/util/file/ConfigurationSource;
aload 1
invokeinterface org.apache.tomcat.util.file.ConfigurationSource.getResource:(Ljava/lang/String;)Lorg/apache/tomcat/util/file/ConfigurationSource$Resource;
invokevirtual org.apache.tomcat.util.file.ConfigurationSource$Resource.getInputStream:()Ljava/io/InputStream;
astore 7
start local 7 6: new java.io.BufferedReader
dup
new java.io.InputStreamReader
dup
aload 7
getstatic java.nio.charset.StandardCharsets.US_ASCII:Ljava/nio/charset/Charset;
invokespecial java.io.InputStreamReader.<init>:(Ljava/io/InputStream;Ljava/nio/charset/Charset;)V
invokespecial java.io.BufferedReader.<init>:(Ljava/io/Reader;)V
7: astore 8
start local 8 8: aconst_null
astore 9
start local 9 9: goto 24
start local 10 10: StackMap locals: org.apache.tomcat.util.net.jsse.PEMFile java.lang.String java.lang.String java.lang.String java.util.List java.lang.Throwable java.lang.Throwable java.io.InputStream java.io.BufferedReader org.apache.tomcat.util.net.jsse.PEMFile$Part java.lang.String
StackMap stack:
aload 10
ldc "-----BEGIN "
invokevirtual java.lang.String.startsWith:(Ljava/lang/String;)Z
ifeq 18
11: new org.apache.tomcat.util.net.jsse.PEMFile$Part
dup
aload 0
invokespecial org.apache.tomcat.util.net.jsse.PEMFile$Part.<init>:(Lorg/apache/tomcat/util/net/jsse/PEMFile;)V
astore 9
12: aload 9
aload 10
ldc "-----BEGIN "
invokevirtual java.lang.String.length:()I
13: aload 10
invokevirtual java.lang.String.length:()I
ldc "-----"
invokevirtual java.lang.String.length:()I
isub
14: invokevirtual java.lang.String.substring:(II)Ljava/lang/String;
15: invokevirtual java.lang.String.trim:()Ljava/lang/String;
16: putfield org.apache.tomcat.util.net.jsse.PEMFile$Part.type:Ljava/lang/String;
17: goto 24
StackMap locals:
StackMap stack:
18: aload 10
ldc "-----END "
invokevirtual java.lang.String.startsWith:(Ljava/lang/String;)Z
ifeq 22
19: aload 4
aload 9
invokeinterface java.util.List.add:(Ljava/lang/Object;)Z
pop
20: aconst_null
astore 9
21: goto 24
StackMap locals:
StackMap stack:
22: aload 9
ifnull 24
aload 10
ldc ":"
invokevirtual java.lang.String.contains:(Ljava/lang/CharSequence;)Z
ifne 24
aload 10
ldc " "
invokevirtual java.lang.String.startsWith:(Ljava/lang/String;)Z
ifne 24
23: aload 9
dup
getfield org.apache.tomcat.util.net.jsse.PEMFile$Part.content:Ljava/lang/String;
new java.lang.StringBuilder
dup_x1
swap
invokestatic java.lang.String.valueOf:(Ljava/lang/Object;)Ljava/lang/String;
invokespecial java.lang.StringBuilder.<init>:(Ljava/lang/String;)V
aload 10
invokevirtual java.lang.StringBuilder.append:(Ljava/lang/String;)Ljava/lang/StringBuilder;
invokevirtual java.lang.StringBuilder.toString:()Ljava/lang/String;
putfield org.apache.tomcat.util.net.jsse.PEMFile$Part.content:Ljava/lang/String;
end local 10 24: StackMap locals:
StackMap stack:
aload 8
invokevirtual java.io.BufferedReader.readLine:()Ljava/lang/String;
dup
astore 10
start local 10 25: ifnonnull 10
end local 10 end local 9 end local 8 26: aload 7
ifnull 32
aload 7
invokevirtual java.io.InputStream.close:()V
goto 32
StackMap locals: org.apache.tomcat.util.net.jsse.PEMFile java.lang.String java.lang.String java.lang.String java.util.List java.lang.Throwable java.lang.Throwable java.io.InputStream
StackMap stack: java.lang.Throwable
27: astore 5
aload 7
ifnull 28
aload 7
invokevirtual java.io.InputStream.close:()V
end local 7 StackMap locals:
StackMap stack:
28: aload 5
athrow
StackMap locals:
StackMap stack: java.lang.Throwable
29: astore 6
aload 5
ifnonnull 30
aload 6
astore 5
goto 31
StackMap locals:
StackMap stack:
30: aload 5
aload 6
if_acmpeq 31
aload 5
aload 6
invokevirtual java.lang.Throwable.addSuppressed:(Ljava/lang/Throwable;)V
StackMap locals:
StackMap stack:
31: aload 5
athrow
32: StackMap locals:
StackMap stack:
aload 4
invokeinterface java.util.List.iterator:()Ljava/util/Iterator;
astore 6
goto 50
StackMap locals: org.apache.tomcat.util.net.jsse.PEMFile java.lang.String java.lang.String java.lang.String java.util.List top java.util.Iterator
StackMap stack:
33: aload 6
invokeinterface java.util.Iterator.next:()Ljava/lang/Object;
checkcast org.apache.tomcat.util.net.jsse.PEMFile$Part
astore 5
start local 5 34: aload 5
getfield org.apache.tomcat.util.net.jsse.PEMFile$Part.type:Ljava/lang/String;
dup
astore 7
invokevirtual java.lang.String.hashCode:()I
lookupswitch { // 6
-2076506627: 35
-283732602: 36
-189606537: 37
-170985982: 38
957721984: 39
2121838594: 40
default: 50
}
StackMap locals: org.apache.tomcat.util.net.jsse.PEMFile java.lang.String java.lang.String java.lang.String java.util.List org.apache.tomcat.util.net.jsse.PEMFile$Part java.util.Iterator java.lang.String
StackMap stack:
35: aload 7
ldc "X509 CERTIFICATE"
invokevirtual java.lang.String.equals:(Ljava/lang/Object;)Z
ifne 49
goto 50
StackMap locals:
StackMap stack:
36: aload 7
ldc "ENCRYPTED PRIVATE KEY"
invokevirtual java.lang.String.equals:(Ljava/lang/Object;)Z
ifne 45
goto 50
StackMap locals:
StackMap stack:
37: aload 7
ldc "CERTIFICATE"
invokevirtual java.lang.String.equals:(Ljava/lang/Object;)Z
ifne 49
goto 50
StackMap locals:
StackMap stack:
38: aload 7
ldc "PRIVATE KEY"
invokevirtual java.lang.String.equals:(Ljava/lang/Object;)Z
ifne 41
goto 50
StackMap locals:
StackMap stack:
39: aload 7
ldc "EC PRIVATE KEY"
invokevirtual java.lang.String.equals:(Ljava/lang/Object;)Z
ifne 43
goto 50
StackMap locals:
StackMap stack:
40: aload 7
ldc "RSA PRIVATE KEY"
invokevirtual java.lang.String.equals:(Ljava/lang/Object;)Z
ifne 47
goto 50
41: StackMap locals:
StackMap stack:
aload 0
aload 5
aconst_null
aload 3
getstatic org.apache.tomcat.util.net.jsse.PEMFile$Format.PKCS8:Lorg/apache/tomcat/util/net/jsse/PEMFile$Format;
invokevirtual org.apache.tomcat.util.net.jsse.PEMFile$Part.toPrivateKey:(Ljava/lang/String;Ljava/lang/String;Lorg/apache/tomcat/util/net/jsse/PEMFile$Format;)Ljava/security/PrivateKey;
putfield org.apache.tomcat.util.net.jsse.PEMFile.privateKey:Ljava/security/PrivateKey;
42: goto 50
43: StackMap locals:
StackMap stack:
aload 0
aload 5
aconst_null
ldc "EC"
getstatic org.apache.tomcat.util.net.jsse.PEMFile$Format.RFC5915:Lorg/apache/tomcat/util/net/jsse/PEMFile$Format;
invokevirtual org.apache.tomcat.util.net.jsse.PEMFile$Part.toPrivateKey:(Ljava/lang/String;Ljava/lang/String;Lorg/apache/tomcat/util/net/jsse/PEMFile$Format;)Ljava/security/PrivateKey;
putfield org.apache.tomcat.util.net.jsse.PEMFile.privateKey:Ljava/security/PrivateKey;
44: goto 50
45: StackMap locals:
StackMap stack:
aload 0
aload 5
aload 2
aload 3
getstatic org.apache.tomcat.util.net.jsse.PEMFile$Format.PKCS8:Lorg/apache/tomcat/util/net/jsse/PEMFile$Format;
invokevirtual org.apache.tomcat.util.net.jsse.PEMFile$Part.toPrivateKey:(Ljava/lang/String;Ljava/lang/String;Lorg/apache/tomcat/util/net/jsse/PEMFile$Format;)Ljava/security/PrivateKey;
putfield org.apache.tomcat.util.net.jsse.PEMFile.privateKey:Ljava/security/PrivateKey;
46: goto 50
47: StackMap locals:
StackMap stack:
aload 0
aload 5
aconst_null
aload 3
getstatic org.apache.tomcat.util.net.jsse.PEMFile$Format.PKCS1:Lorg/apache/tomcat/util/net/jsse/PEMFile$Format;
invokevirtual org.apache.tomcat.util.net.jsse.PEMFile$Part.toPrivateKey:(Ljava/lang/String;Ljava/lang/String;Lorg/apache/tomcat/util/net/jsse/PEMFile$Format;)Ljava/security/PrivateKey;
putfield org.apache.tomcat.util.net.jsse.PEMFile.privateKey:Ljava/security/PrivateKey;
48: goto 50
49: StackMap locals:
StackMap stack:
aload 0
getfield org.apache.tomcat.util.net.jsse.PEMFile.certificates:Ljava/util/List;
aload 5
invokevirtual org.apache.tomcat.util.net.jsse.PEMFile$Part.toCertificate:()Ljava/security/cert/X509Certificate;
invokeinterface java.util.List.add:(Ljava/lang/Object;)Z
pop
end local 5 50: StackMap locals: org.apache.tomcat.util.net.jsse.PEMFile java.lang.String java.lang.String java.lang.String java.util.List top java.util.Iterator
StackMap stack:
aload 6
invokeinterface java.util.Iterator.hasNext:()Z
ifne 33
51: return
end local 4 end local 3 end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 52 0 this Lorg/apache/tomcat/util/net/jsse/PEMFile;
0 52 1 filename Ljava/lang/String;
0 52 2 password Ljava/lang/String;
0 52 3 keyAlgorithm Ljava/lang/String;
4 52 4 parts Ljava/util/List<Lorg/apache/tomcat/util/net/jsse/PEMFile$Part;>;
6 28 7 inputStream Ljava/io/InputStream;
8 26 8 reader Ljava/io/BufferedReader;
9 26 9 part Lorg/apache/tomcat/util/net/jsse/PEMFile$Part;
10 24 10 line Ljava/lang/String;
25 26 10 line Ljava/lang/String;
34 50 5 part Lorg/apache/tomcat/util/net/jsse/PEMFile$Part;
Exception table:
from to target type
6 26 27 any
5 29 29 any
Exceptions:
throws java.io.IOException, java.security.GeneralSecurityException
MethodParameters:
Name Flags
filename
password
keyAlgorithm
}
SourceFile: "PEMFile.java"
NestMembers:
org.apache.tomcat.util.net.jsse.PEMFile$Format org.apache.tomcat.util.net.jsse.PEMFile$Part
InnerClasses:
public Resource = org.apache.tomcat.util.file.ConfigurationSource$Resource of org.apache.tomcat.util.file.ConfigurationSource
private final Format = org.apache.tomcat.util.net.jsse.PEMFile$Format of org.apache.tomcat.util.net.jsse.PEMFile
private Part = org.apache.tomcat.util.net.jsse.PEMFile$Part of org.apache.tomcat.util.net.jsse.PEMFile