public class org.apache.catalina.realm.MessageDigestCredentialHandler extends org.apache.catalina.realm.DigestCredentialHandlerBase
minor version: 0
major version: 59
flags: flags: (0x0021) ACC_PUBLIC, ACC_SUPER
this_class: org.apache.catalina.realm.MessageDigestCredentialHandler
super_class: org.apache.catalina.realm.DigestCredentialHandlerBase
{
private static final org.apache.juli.logging.Log log;
descriptor: Lorg/apache/juli/logging/Log;
flags: (0x001a) ACC_PRIVATE, ACC_STATIC, ACC_FINAL
public static final int DEFAULT_ITERATIONS;
descriptor: I
flags: (0x0019) ACC_PUBLIC, ACC_STATIC, ACC_FINAL
ConstantValue: 1
private java.nio.charset.Charset encoding;
descriptor: Ljava/nio/charset/Charset;
flags: (0x0002) ACC_PRIVATE
private java.lang.String algorithm;
descriptor: Ljava/lang/String;
flags: (0x0002) ACC_PRIVATE
static void <clinit>();
descriptor: ()V
flags: (0x0008) ACC_STATIC
Code:
stack=1, locals=0, args_size=0
0: ldc Lorg/apache/catalina/realm/MessageDigestCredentialHandler;
invokestatic org.apache.juli.logging.LogFactory.getLog:(Ljava/lang/Class;)Lorg/apache/juli/logging/Log;
putstatic org.apache.catalina.realm.MessageDigestCredentialHandler.log:Lorg/apache/juli/logging/Log;
1: return
LocalVariableTable:
Start End Slot Name Signature
public void <init>();
descriptor: ()V
flags: (0x0001) ACC_PUBLIC
Code:
stack=2, locals=1, args_size=1
start local 0 0: aload 0
invokespecial org.apache.catalina.realm.DigestCredentialHandlerBase.<init>:()V
1: aload 0
getstatic java.nio.charset.StandardCharsets.UTF_8:Ljava/nio/charset/Charset;
putfield org.apache.catalina.realm.MessageDigestCredentialHandler.encoding:Ljava/nio/charset/Charset;
2: aload 0
aconst_null
putfield org.apache.catalina.realm.MessageDigestCredentialHandler.algorithm:Ljava/lang/String;
3: return
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 4 0 this Lorg/apache/catalina/realm/MessageDigestCredentialHandler;
public java.lang.String getEncoding();
descriptor: ()Ljava/lang/String;
flags: (0x0001) ACC_PUBLIC
Code:
stack=1, locals=1, args_size=1
start local 0 0: aload 0
getfield org.apache.catalina.realm.MessageDigestCredentialHandler.encoding:Ljava/nio/charset/Charset;
invokevirtual java.nio.charset.Charset.name:()Ljava/lang/String;
areturn
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 1 0 this Lorg/apache/catalina/realm/MessageDigestCredentialHandler;
public void setEncoding(java.lang.String);
descriptor: (Ljava/lang/String;)V
flags: (0x0001) ACC_PUBLIC
Code:
stack=7, locals=2, args_size=2
start local 0 start local 1 0: aload 1
ifnonnull 3
1: aload 0
getstatic java.nio.charset.StandardCharsets.UTF_8:Ljava/nio/charset/Charset;
putfield org.apache.catalina.realm.MessageDigestCredentialHandler.encoding:Ljava/nio/charset/Charset;
2: goto 7
3: StackMap locals:
StackMap stack:
aload 0
aload 1
invokestatic org.apache.tomcat.util.buf.B2CConverter.getCharset:(Ljava/lang/String;)Ljava/nio/charset/Charset;
putfield org.apache.catalina.realm.MessageDigestCredentialHandler.encoding:Ljava/nio/charset/Charset;
4: goto 7
StackMap locals:
StackMap stack: java.io.UnsupportedEncodingException
5: pop
6: getstatic org.apache.catalina.realm.MessageDigestCredentialHandler.log:Lorg/apache/juli/logging/Log;
getstatic org.apache.catalina.realm.MessageDigestCredentialHandler.sm:Lorg/apache/tomcat/util/res/StringManager;
ldc "mdCredentialHandler.unknownEncoding"
iconst_2
anewarray java.lang.Object
dup
iconst_0
aload 1
aastore
dup
iconst_1
aload 0
getfield org.apache.catalina.realm.MessageDigestCredentialHandler.encoding:Ljava/nio/charset/Charset;
invokevirtual java.nio.charset.Charset.name:()Ljava/lang/String;
aastore
invokevirtual org.apache.tomcat.util.res.StringManager.getString:(Ljava/lang/String;[Ljava/lang/Object;)Ljava/lang/String;
invokeinterface org.apache.juli.logging.Log.error:(Ljava/lang/Object;)V
7: StackMap locals:
StackMap stack:
return
end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 8 0 this Lorg/apache/catalina/realm/MessageDigestCredentialHandler;
0 8 1 encodingName Ljava/lang/String;
Exception table:
from to target type
3 4 5 Class java.io.UnsupportedEncodingException
MethodParameters:
Name Flags
encodingName
public java.lang.String getAlgorithm();
descriptor: ()Ljava/lang/String;
flags: (0x0001) ACC_PUBLIC
Code:
stack=1, locals=1, args_size=1
start local 0 0: aload 0
getfield org.apache.catalina.realm.MessageDigestCredentialHandler.algorithm:Ljava/lang/String;
areturn
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 1 0 this Lorg/apache/catalina/realm/MessageDigestCredentialHandler;
public void setAlgorithm(java.lang.String);
descriptor: (Ljava/lang/String;)V
flags: (0x0001) ACC_PUBLIC
Code:
stack=2, locals=2, args_size=2
start local 0 start local 1 0: aload 1
invokestatic org.apache.tomcat.util.security.ConcurrentMessageDigest.init:(Ljava/lang/String;)V
1: aload 0
aload 1
putfield org.apache.catalina.realm.MessageDigestCredentialHandler.algorithm:Ljava/lang/String;
2: return
end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 3 0 this Lorg/apache/catalina/realm/MessageDigestCredentialHandler;
0 3 1 algorithm Ljava/lang/String;
Exceptions:
throws java.security.NoSuchAlgorithmException
MethodParameters:
Name Flags
algorithm
public boolean matches(java.lang.String, java.lang.String);
descriptor: (Ljava/lang/String;Ljava/lang/String;)Z
flags: (0x0001) ACC_PUBLIC
Code:
stack=6, locals=9, args_size=3
start local 0 start local 1 start local 2 0: aload 1
ifnull 1
aload 2
ifnonnull 2
1: StackMap locals:
StackMap stack:
iconst_0
ireturn
2: StackMap locals:
StackMap stack:
aload 0
invokevirtual org.apache.catalina.realm.MessageDigestCredentialHandler.getAlgorithm:()Ljava/lang/String;
ifnonnull 4
3: aload 2
aload 1
invokevirtual java.lang.String.equals:(Ljava/lang/Object;)Z
ireturn
4: StackMap locals:
StackMap stack:
aload 2
ldc "{MD5}"
invokevirtual java.lang.String.startsWith:(Ljava/lang/String;)Z
ifne 5
aload 2
ldc "{SHA}"
invokevirtual java.lang.String.startsWith:(Ljava/lang/String;)Z
ifeq 10
5: StackMap locals:
StackMap stack:
aload 2
iconst_5
invokevirtual java.lang.String.substring:(I)Ljava/lang/String;
astore 3
start local 3 6: aload 0
invokevirtual org.apache.catalina.realm.MessageDigestCredentialHandler.getAlgorithm:()Ljava/lang/String;
iconst_1
anewarray byte[]
dup
iconst_0
aload 1
getstatic java.nio.charset.StandardCharsets.ISO_8859_1:Ljava/nio/charset/Charset;
invokevirtual java.lang.String.getBytes:(Ljava/nio/charset/Charset;)[B
aastore
7: invokestatic org.apache.tomcat.util.security.ConcurrentMessageDigest.digest:(Ljava/lang/String;[[B)[B
astore 4
start local 4 8: aload 4
invokestatic org.apache.tomcat.util.codec.binary.Base64.encodeBase64String:([B)Ljava/lang/String;
astore 5
start local 5 9: aload 5
aload 3
invokevirtual java.lang.String.equals:(Ljava/lang/Object;)Z
ireturn
end local 5 end local 4 end local 3 10: StackMap locals:
StackMap stack:
aload 2
ldc "{SSHA}"
invokevirtual java.lang.String.startsWith:(Ljava/lang/String;)Z
ifeq 23
11: aload 2
bipush 6
invokevirtual java.lang.String.substring:(I)Ljava/lang/String;
astore 3
start local 3 12: aload 3
invokestatic org.apache.tomcat.util.codec.binary.Base64.decodeBase64:(Ljava/lang/String;)[B
astore 4
start local 4 13: bipush 20
newarray 8
astore 5
start local 5 14: aload 4
iconst_0
aload 5
iconst_0
bipush 20
invokestatic java.lang.System.arraycopy:(Ljava/lang/Object;ILjava/lang/Object;II)V
15: aload 4
arraylength
bipush 20
isub
istore 6
start local 6 16: iload 6
newarray 8
astore 7
start local 7 17: aload 4
bipush 20
aload 7
iconst_0
iload 6
invokestatic java.lang.System.arraycopy:(Ljava/lang/Object;ILjava/lang/Object;II)V
18: aload 0
invokevirtual org.apache.catalina.realm.MessageDigestCredentialHandler.getAlgorithm:()Ljava/lang/String;
iconst_2
anewarray byte[]
dup
iconst_0
19: aload 1
getstatic java.nio.charset.StandardCharsets.ISO_8859_1:Ljava/nio/charset/Charset;
invokevirtual java.lang.String.getBytes:(Ljava/nio/charset/Charset;)[B
aastore
dup
iconst_1
20: aload 7
aastore
21: invokestatic org.apache.tomcat.util.security.ConcurrentMessageDigest.digest:(Ljava/lang/String;[[B)[B
astore 8
start local 8 22: aload 8
aload 5
invokestatic java.util.Arrays.equals:([B[B)Z
ireturn
end local 8 end local 7 end local 6 end local 5 end local 4 end local 3 23: StackMap locals:
StackMap stack:
aload 2
bipush 36
invokevirtual java.lang.String.indexOf:(I)I
iconst_m1
if_icmple 25
24: aload 0
aload 1
aload 2
invokevirtual org.apache.catalina.realm.MessageDigestCredentialHandler.matchesSaltIterationsEncoded:(Ljava/lang/String;Ljava/lang/String;)Z
ireturn
25: StackMap locals:
StackMap stack:
aload 0
aload 1
aconst_null
iconst_1
invokevirtual org.apache.catalina.realm.MessageDigestCredentialHandler.mutate:(Ljava/lang/String;[BI)Ljava/lang/String;
astore 3
start local 3 26: aload 3
ifnonnull 28
27: iconst_0
ireturn
28: StackMap locals: java.lang.String
StackMap stack:
aload 2
aload 3
invokevirtual java.lang.String.equalsIgnoreCase:(Ljava/lang/String;)Z
ireturn
end local 3 end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 29 0 this Lorg/apache/catalina/realm/MessageDigestCredentialHandler;
0 29 1 inputCredentials Ljava/lang/String;
0 29 2 storedCredentials Ljava/lang/String;
6 10 3 base64ServerDigest Ljava/lang/String;
8 10 4 userDigest [B
9 10 5 base64UserDigest Ljava/lang/String;
12 23 3 serverDigestPlusSalt Ljava/lang/String;
13 23 4 serverDigestPlusSaltBytes [B
14 23 5 serverDigestBytes [B
16 23 6 saltLength I
17 23 7 serverSaltBytes [B
22 23 8 userDigestBytes [B
26 29 3 userDigest Ljava/lang/String;
MethodParameters:
Name Flags
inputCredentials
storedCredentials
protected java.lang.String mutate(java.lang.String, byte[], int);
descriptor: (Ljava/lang/String;[BI)Ljava/lang/String;
flags: (0x0004) ACC_PROTECTED
Code:
stack=6, locals=6, args_size=4
start local 0 start local 1 start local 2 start local 3 0: aload 0
getfield org.apache.catalina.realm.MessageDigestCredentialHandler.algorithm:Ljava/lang/String;
ifnonnull 2
1: aload 1
areturn
2: StackMap locals:
StackMap stack:
aload 1
aload 0
getfield org.apache.catalina.realm.MessageDigestCredentialHandler.encoding:Ljava/nio/charset/Charset;
invokevirtual java.lang.String.getBytes:(Ljava/nio/charset/Charset;)[B
astore 4
start local 4 3: aload 2
ifnonnull 6
4: aload 0
getfield org.apache.catalina.realm.MessageDigestCredentialHandler.algorithm:Ljava/lang/String;
iload 3
iconst_1
anewarray byte[]
dup
iconst_0
aload 4
aastore
invokestatic org.apache.tomcat.util.security.ConcurrentMessageDigest.digest:(Ljava/lang/String;I[[B)[B
astore 5
start local 5 5: goto 7
end local 5 6: StackMap locals: byte[]
StackMap stack:
aload 0
getfield org.apache.catalina.realm.MessageDigestCredentialHandler.algorithm:Ljava/lang/String;
iload 3
iconst_2
anewarray byte[]
dup
iconst_0
aload 2
aastore
dup
iconst_1
aload 4
aastore
invokestatic org.apache.tomcat.util.security.ConcurrentMessageDigest.digest:(Ljava/lang/String;I[[B)[B
astore 5
start local 5 7: StackMap locals: byte[]
StackMap stack:
aload 5
invokestatic org.apache.tomcat.util.buf.HexUtils.toHexString:([B)Ljava/lang/String;
areturn
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 8 0 this Lorg/apache/catalina/realm/MessageDigestCredentialHandler;
0 8 1 inputCredentials Ljava/lang/String;
0 8 2 salt [B
0 8 3 iterations I
3 8 4 inputCredentialbytes [B
5 6 5 userDigest [B
7 8 5 userDigest [B
MethodParameters:
Name Flags
inputCredentials
salt
iterations
protected int getDefaultIterations();
descriptor: ()I
flags: (0x0004) ACC_PROTECTED
Code:
stack=1, locals=1, args_size=1
start local 0 0: iconst_1
ireturn
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 1 0 this Lorg/apache/catalina/realm/MessageDigestCredentialHandler;
protected org.apache.juli.logging.Log getLog();
descriptor: ()Lorg/apache/juli/logging/Log;
flags: (0x0004) ACC_PROTECTED
Code:
stack=1, locals=1, args_size=1
start local 0 0: getstatic org.apache.catalina.realm.MessageDigestCredentialHandler.log:Lorg/apache/juli/logging/Log;
areturn
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 1 0 this Lorg/apache/catalina/realm/MessageDigestCredentialHandler;
}
SourceFile: "MessageDigestCredentialHandler.java"