abstract class com.mongodb.internal.connection.SaslAuthenticator extends com.mongodb.internal.connection.Authenticator
minor version: 0
major version: 59
flags: flags: (0x0420) ACC_SUPER, ACC_ABSTRACT
this_class: com.mongodb.internal.connection.SaslAuthenticator
super_class: com.mongodb.internal.connection.Authenticator
{
void <init>(com.mongodb.internal.connection.MongoCredentialWithCache);
descriptor: (Lcom/mongodb/internal/connection/MongoCredentialWithCache;)V
flags: (0x0000)
Code:
stack=2, locals=2, args_size=2
start local 0 start local 1 0: aload 0
aload 1
invokespecial com.mongodb.internal.connection.Authenticator.<init>:(Lcom/mongodb/internal/connection/MongoCredentialWithCache;)V
1: return
end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 2 0 this Lcom/mongodb/internal/connection/SaslAuthenticator;
0 2 1 credential Lcom/mongodb/internal/connection/MongoCredentialWithCache;
MethodParameters:
Name Flags
credential final
public void authenticate(com.mongodb.internal.connection.InternalConnection, com.mongodb.connection.ConnectionDescription);
descriptor: (Lcom/mongodb/internal/connection/InternalConnection;Lcom/mongodb/connection/ConnectionDescription;)V
flags: (0x0001) ACC_PUBLIC
Code:
stack=5, locals=3, args_size=3
start local 0 start local 1 start local 2 0: aload 0
new com.mongodb.internal.connection.SaslAuthenticator$1
dup
aload 0
aload 1
invokespecial com.mongodb.internal.connection.SaslAuthenticator$1.<init>:(Lcom/mongodb/internal/connection/SaslAuthenticator;Lcom/mongodb/internal/connection/InternalConnection;)V
invokevirtual com.mongodb.internal.connection.SaslAuthenticator.doAsSubject:(Ljava/security/PrivilegedAction;)V
1: return
end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 2 0 this Lcom/mongodb/internal/connection/SaslAuthenticator;
0 2 1 connection Lcom/mongodb/internal/connection/InternalConnection;
0 2 2 connectionDescription Lcom/mongodb/connection/ConnectionDescription;
MethodParameters:
Name Flags
connection final
connectionDescription final
void authenticateAsync(com.mongodb.internal.connection.InternalConnection, com.mongodb.connection.ConnectionDescription, com.mongodb.async.SingleResultCallback<java.lang.Void>);
descriptor: (Lcom/mongodb/internal/connection/InternalConnection;Lcom/mongodb/connection/ConnectionDescription;Lcom/mongodb/async/SingleResultCallback;)V
flags: (0x0000)
Code:
stack=6, locals=5, args_size=4
start local 0 start local 1 start local 2 start local 3 0: aload 0
new com.mongodb.internal.connection.SaslAuthenticator$2
dup
aload 0
aload 1
aload 3
invokespecial com.mongodb.internal.connection.SaslAuthenticator$2.<init>:(Lcom/mongodb/internal/connection/SaslAuthenticator;Lcom/mongodb/internal/connection/InternalConnection;Lcom/mongodb/async/SingleResultCallback;)V
invokevirtual com.mongodb.internal.connection.SaslAuthenticator.doAsSubject:(Ljava/security/PrivilegedAction;)V
1: goto 4
StackMap locals:
StackMap stack: java.lang.Throwable
2: astore 4
start local 4 3: aload 3
aconst_null
aload 4
invokeinterface com.mongodb.async.SingleResultCallback.onResult:(Ljava/lang/Object;Ljava/lang/Throwable;)V
end local 4 4: StackMap locals:
StackMap stack:
return
end local 3 end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 5 0 this Lcom/mongodb/internal/connection/SaslAuthenticator;
0 5 1 connection Lcom/mongodb/internal/connection/InternalConnection;
0 5 2 connectionDescription Lcom/mongodb/connection/ConnectionDescription;
0 5 3 callback Lcom/mongodb/async/SingleResultCallback<Ljava/lang/Void;>;
3 4 4 t Ljava/lang/Throwable;
Exception table:
from to target type
0 1 2 Class java.lang.Throwable
Signature: (Lcom/mongodb/internal/connection/InternalConnection;Lcom/mongodb/connection/ConnectionDescription;Lcom/mongodb/async/SingleResultCallback<Ljava/lang/Void;>;)V
MethodParameters:
Name Flags
connection final
connectionDescription final
callback final
public abstract java.lang.String getMechanismName();
descriptor: ()Ljava/lang/String;
flags: (0x0401) ACC_PUBLIC, ACC_ABSTRACT
protected abstract javax.security.sasl.SaslClient createSaslClient(com.mongodb.ServerAddress);
descriptor: (Lcom/mongodb/ServerAddress;)Ljavax/security/sasl/SaslClient;
flags: (0x0404) ACC_PROTECTED, ACC_ABSTRACT
MethodParameters:
Name Flags
serverAddress
private void throwIfSaslClientIsNull(javax.security.sasl.SaslClient);
descriptor: (Ljavax/security/sasl/SaslClient;)V
flags: (0x0002) ACC_PRIVATE
Code:
stack=8, locals=2, args_size=2
start local 0 start local 1 0: aload 1
ifnonnull 4
1: new com.mongodb.MongoSecurityException
dup
aload 0
invokevirtual com.mongodb.internal.connection.SaslAuthenticator.getMongoCredential:()Lcom/mongodb/MongoCredential;
2: ldc "This JDK does not support the %s SASL mechanism"
iconst_1
anewarray java.lang.Object
dup
iconst_0
aload 0
invokevirtual com.mongodb.internal.connection.SaslAuthenticator.getMechanismName:()Ljava/lang/String;
aastore
invokestatic java.lang.String.format:(Ljava/lang/String;[Ljava/lang/Object;)Ljava/lang/String;
3: invokespecial com.mongodb.MongoSecurityException.<init>:(Lcom/mongodb/MongoCredential;Ljava/lang/String;)V
athrow
4: StackMap locals:
StackMap stack:
return
end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 5 0 this Lcom/mongodb/internal/connection/SaslAuthenticator;
0 5 1 saslClient Ljavax/security/sasl/SaslClient;
MethodParameters:
Name Flags
saslClient final
private javax.security.auth.Subject getSubject();
descriptor: ()Ljavax/security/auth/Subject;
flags: (0x0002) ACC_PRIVATE
Code:
stack=3, locals=1, args_size=1
start local 0 0: aload 0
invokevirtual com.mongodb.internal.connection.SaslAuthenticator.getMongoCredential:()Lcom/mongodb/MongoCredential;
ldc "JAVA_SUBJECT"
aconst_null
invokevirtual com.mongodb.MongoCredential.getMechanismProperty:(Ljava/lang/String;Ljava/lang/Object;)Ljava/lang/Object;
checkcast javax.security.auth.Subject
areturn
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 1 0 this Lcom/mongodb/internal/connection/SaslAuthenticator;
RuntimeVisibleAnnotations:
com.mongodb.lang.Nullable()
private org.bson.BsonDocument sendSaslStart(byte[], com.mongodb.internal.connection.InternalConnection);
descriptor: ([BLcom/mongodb/internal/connection/InternalConnection;)Lorg/bson/BsonDocument;
flags: (0x0002) ACC_PRIVATE
Code:
stack=3, locals=3, args_size=3
start local 0 start local 1 start local 2 0: aload 0
invokevirtual com.mongodb.internal.connection.SaslAuthenticator.getMongoCredential:()Lcom/mongodb/MongoCredential;
invokevirtual com.mongodb.MongoCredential.getSource:()Ljava/lang/String;
aload 0
aload 1
invokevirtual com.mongodb.internal.connection.SaslAuthenticator.createSaslStartCommandDocument:([B)Lorg/bson/BsonDocument;
aload 2
invokestatic com.mongodb.internal.connection.CommandHelper.executeCommand:(Ljava/lang/String;Lorg/bson/BsonDocument;Lcom/mongodb/internal/connection/InternalConnection;)Lorg/bson/BsonDocument;
areturn
end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 1 0 this Lcom/mongodb/internal/connection/SaslAuthenticator;
0 1 1 outToken [B
0 1 2 connection Lcom/mongodb/internal/connection/InternalConnection;
MethodParameters:
Name Flags
outToken final
connection final
private org.bson.BsonDocument sendSaslContinue(org.bson.BsonInt32, byte[], com.mongodb.internal.connection.InternalConnection);
descriptor: (Lorg/bson/BsonInt32;[BLcom/mongodb/internal/connection/InternalConnection;)Lorg/bson/BsonDocument;
flags: (0x0002) ACC_PRIVATE
Code:
stack=4, locals=4, args_size=4
start local 0 start local 1 start local 2 start local 3 0: aload 0
invokevirtual com.mongodb.internal.connection.SaslAuthenticator.getMongoCredential:()Lcom/mongodb/MongoCredential;
invokevirtual com.mongodb.MongoCredential.getSource:()Ljava/lang/String;
aload 0
aload 1
aload 2
invokevirtual com.mongodb.internal.connection.SaslAuthenticator.createSaslContinueDocument:(Lorg/bson/BsonInt32;[B)Lorg/bson/BsonDocument;
aload 3
invokestatic com.mongodb.internal.connection.CommandHelper.executeCommand:(Ljava/lang/String;Lorg/bson/BsonDocument;Lcom/mongodb/internal/connection/InternalConnection;)Lorg/bson/BsonDocument;
areturn
end local 3 end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 1 0 this Lcom/mongodb/internal/connection/SaslAuthenticator;
0 1 1 conversationId Lorg/bson/BsonInt32;
0 1 2 outToken [B
0 1 3 connection Lcom/mongodb/internal/connection/InternalConnection;
MethodParameters:
Name Flags
conversationId final
outToken final
connection final
private void sendSaslStartAsync(byte[], com.mongodb.internal.connection.InternalConnection, com.mongodb.async.SingleResultCallback<org.bson.BsonDocument>);
descriptor: ([BLcom/mongodb/internal/connection/InternalConnection;Lcom/mongodb/async/SingleResultCallback;)V
flags: (0x0002) ACC_PRIVATE
Code:
stack=4, locals=4, args_size=4
start local 0 start local 1 start local 2 start local 3 0: aload 0
invokevirtual com.mongodb.internal.connection.SaslAuthenticator.getMongoCredential:()Lcom/mongodb/MongoCredential;
invokevirtual com.mongodb.MongoCredential.getSource:()Ljava/lang/String;
aload 0
aload 1
invokevirtual com.mongodb.internal.connection.SaslAuthenticator.createSaslStartCommandDocument:([B)Lorg/bson/BsonDocument;
aload 2
1: aload 3
2: invokestatic com.mongodb.internal.connection.CommandHelper.executeCommandAsync:(Ljava/lang/String;Lorg/bson/BsonDocument;Lcom/mongodb/internal/connection/InternalConnection;Lcom/mongodb/async/SingleResultCallback;)V
3: return
end local 3 end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 4 0 this Lcom/mongodb/internal/connection/SaslAuthenticator;
0 4 1 outToken [B
0 4 2 connection Lcom/mongodb/internal/connection/InternalConnection;
0 4 3 callback Lcom/mongodb/async/SingleResultCallback<Lorg/bson/BsonDocument;>;
Signature: ([BLcom/mongodb/internal/connection/InternalConnection;Lcom/mongodb/async/SingleResultCallback<Lorg/bson/BsonDocument;>;)V
MethodParameters:
Name Flags
outToken final
connection final
callback final
private void sendSaslContinueAsync(org.bson.BsonInt32, byte[], com.mongodb.internal.connection.InternalConnection, com.mongodb.async.SingleResultCallback<org.bson.BsonDocument>);
descriptor: (Lorg/bson/BsonInt32;[BLcom/mongodb/internal/connection/InternalConnection;Lcom/mongodb/async/SingleResultCallback;)V
flags: (0x0002) ACC_PRIVATE
Code:
stack=4, locals=5, args_size=5
start local 0 start local 1 start local 2 start local 3 start local 4 0: aload 0
invokevirtual com.mongodb.internal.connection.SaslAuthenticator.getMongoCredential:()Lcom/mongodb/MongoCredential;
invokevirtual com.mongodb.MongoCredential.getSource:()Ljava/lang/String;
aload 0
aload 1
aload 2
invokevirtual com.mongodb.internal.connection.SaslAuthenticator.createSaslContinueDocument:(Lorg/bson/BsonInt32;[B)Lorg/bson/BsonDocument;
aload 3
1: aload 4
2: invokestatic com.mongodb.internal.connection.CommandHelper.executeCommandAsync:(Ljava/lang/String;Lorg/bson/BsonDocument;Lcom/mongodb/internal/connection/InternalConnection;Lcom/mongodb/async/SingleResultCallback;)V
3: return
end local 4 end local 3 end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 4 0 this Lcom/mongodb/internal/connection/SaslAuthenticator;
0 4 1 conversationId Lorg/bson/BsonInt32;
0 4 2 outToken [B
0 4 3 connection Lcom/mongodb/internal/connection/InternalConnection;
0 4 4 callback Lcom/mongodb/async/SingleResultCallback<Lorg/bson/BsonDocument;>;
Signature: (Lorg/bson/BsonInt32;[BLcom/mongodb/internal/connection/InternalConnection;Lcom/mongodb/async/SingleResultCallback<Lorg/bson/BsonDocument;>;)V
MethodParameters:
Name Flags
conversationId final
outToken final
connection final
callback final
private org.bson.BsonDocument createSaslStartCommandDocument(byte[]);
descriptor: ([B)Lorg/bson/BsonDocument;
flags: (0x0002) ACC_PRIVATE
Code:
stack=6, locals=2, args_size=2
start local 0 start local 1 0: new org.bson.BsonDocument
dup
ldc "saslStart"
new org.bson.BsonInt32
dup
iconst_1
invokespecial org.bson.BsonInt32.<init>:(I)V
invokespecial org.bson.BsonDocument.<init>:(Ljava/lang/String;Lorg/bson/BsonValue;)V
ldc "mechanism"
new org.bson.BsonString
dup
aload 0
invokevirtual com.mongodb.internal.connection.SaslAuthenticator.getMechanismName:()Ljava/lang/String;
invokespecial org.bson.BsonString.<init>:(Ljava/lang/String;)V
invokevirtual org.bson.BsonDocument.append:(Ljava/lang/String;Lorg/bson/BsonValue;)Lorg/bson/BsonDocument;
1: ldc "payload"
2: new org.bson.BsonBinary
dup
aload 1
ifnull 3
aload 1
goto 4
StackMap locals: com.mongodb.internal.connection.SaslAuthenticator byte[]
StackMap stack: org.bson.BsonDocument java.lang.String new 2 new 2
3: iconst_0
newarray 8
StackMap locals: com.mongodb.internal.connection.SaslAuthenticator byte[]
StackMap stack: org.bson.BsonDocument java.lang.String new 2 new 2 byte[]
4: invokespecial org.bson.BsonBinary.<init>:([B)V
invokevirtual org.bson.BsonDocument.append:(Ljava/lang/String;Lorg/bson/BsonValue;)Lorg/bson/BsonDocument;
5: areturn
end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 6 0 this Lcom/mongodb/internal/connection/SaslAuthenticator;
0 6 1 outToken [B
MethodParameters:
Name Flags
outToken final
private org.bson.BsonDocument createSaslContinueDocument(org.bson.BsonInt32, byte[]);
descriptor: (Lorg/bson/BsonInt32;[B)Lorg/bson/BsonDocument;
flags: (0x0002) ACC_PRIVATE
Code:
stack=6, locals=3, args_size=3
start local 0 start local 1 start local 2 0: new org.bson.BsonDocument
dup
ldc "saslContinue"
new org.bson.BsonInt32
dup
iconst_1
invokespecial org.bson.BsonInt32.<init>:(I)V
invokespecial org.bson.BsonDocument.<init>:(Ljava/lang/String;Lorg/bson/BsonValue;)V
ldc "conversationId"
aload 1
invokevirtual org.bson.BsonDocument.append:(Ljava/lang/String;Lorg/bson/BsonValue;)Lorg/bson/BsonDocument;
1: ldc "payload"
new org.bson.BsonBinary
dup
aload 2
invokespecial org.bson.BsonBinary.<init>:([B)V
invokevirtual org.bson.BsonDocument.append:(Ljava/lang/String;Lorg/bson/BsonValue;)Lorg/bson/BsonDocument;
2: areturn
end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 3 0 this Lcom/mongodb/internal/connection/SaslAuthenticator;
0 3 1 conversationId Lorg/bson/BsonInt32;
0 3 2 outToken [B
MethodParameters:
Name Flags
conversationId final
outToken final
private void disposeOfSaslClient(javax.security.sasl.SaslClient);
descriptor: (Ljavax/security/sasl/SaslClient;)V
flags: (0x0002) ACC_PRIVATE
Code:
stack=1, locals=2, args_size=2
start local 0 start local 1 0: aload 1
invokeinterface javax.security.sasl.SaslClient.dispose:()V
1: goto 3
StackMap locals:
StackMap stack: javax.security.sasl.SaslException
2: pop
3: StackMap locals:
StackMap stack:
return
end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 4 0 this Lcom/mongodb/internal/connection/SaslAuthenticator;
0 4 1 saslClient Ljavax/security/sasl/SaslClient;
Exception table:
from to target type
0 1 2 Class javax.security.sasl.SaslException
MethodParameters:
Name Flags
saslClient final
private com.mongodb.MongoException wrapException(java.lang.Throwable);
descriptor: (Ljava/lang/Throwable;)Lcom/mongodb/MongoException;
flags: (0x0002) ACC_PRIVATE
Code:
stack=6, locals=2, args_size=2
start local 0 start local 1 0: aload 1
instanceof com.mongodb.MongoInterruptedException
ifeq 2
1: aload 1
checkcast com.mongodb.MongoInterruptedException
areturn
2: StackMap locals:
StackMap stack:
aload 1
instanceof com.mongodb.MongoSecurityException
ifeq 4
3: aload 1
checkcast com.mongodb.MongoSecurityException
areturn
4: StackMap locals:
StackMap stack:
new com.mongodb.MongoSecurityException
dup
aload 0
invokevirtual com.mongodb.internal.connection.SaslAuthenticator.getMongoCredential:()Lcom/mongodb/MongoCredential;
new java.lang.StringBuilder
dup
ldc "Exception authenticating "
invokespecial java.lang.StringBuilder.<init>:(Ljava/lang/String;)V
aload 0
invokevirtual com.mongodb.internal.connection.SaslAuthenticator.getMongoCredential:()Lcom/mongodb/MongoCredential;
invokevirtual java.lang.StringBuilder.append:(Ljava/lang/Object;)Ljava/lang/StringBuilder;
invokevirtual java.lang.StringBuilder.toString:()Ljava/lang/String;
aload 1
invokespecial com.mongodb.MongoSecurityException.<init>:(Lcom/mongodb/MongoCredential;Ljava/lang/String;Ljava/lang/Throwable;)V
areturn
end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 5 0 this Lcom/mongodb/internal/connection/SaslAuthenticator;
0 5 1 t Ljava/lang/Throwable;
MethodParameters:
Name Flags
t final
void doAsSubject(java.security.PrivilegedAction<java.lang.Void>);
descriptor: (Ljava/security/PrivilegedAction;)V
flags: (0x0000)
Code:
stack=2, locals=2, args_size=2
start local 0 start local 1 0: aload 0
invokevirtual com.mongodb.internal.connection.SaslAuthenticator.getSubject:()Ljavax/security/auth/Subject;
ifnonnull 3
1: aload 1
invokeinterface java.security.PrivilegedAction.run:()Ljava/lang/Object;
pop
2: goto 4
3: StackMap locals:
StackMap stack:
aload 0
invokevirtual com.mongodb.internal.connection.SaslAuthenticator.getSubject:()Ljavax/security/auth/Subject;
aload 1
invokestatic javax.security.auth.Subject.doAs:(Ljavax/security/auth/Subject;Ljava/security/PrivilegedAction;)Ljava/lang/Object;
pop
4: StackMap locals:
StackMap stack:
return
end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 5 0 this Lcom/mongodb/internal/connection/SaslAuthenticator;
0 5 1 action Ljava/security/PrivilegedAction<Ljava/lang/Void;>;
Signature: (Ljava/security/PrivilegedAction<Ljava/lang/Void;>;)V
MethodParameters:
Name Flags
action final
}
SourceFile: "SaslAuthenticator.java"
NestMembers:
com.mongodb.internal.connection.SaslAuthenticator$1 com.mongodb.internal.connection.SaslAuthenticator$2 com.mongodb.internal.connection.SaslAuthenticator$2$1 com.mongodb.internal.connection.SaslAuthenticator$Continuator com.mongodb.internal.connection.SaslAuthenticator$Continuator$1
InnerClasses:
com.mongodb.internal.connection.SaslAuthenticator$1
com.mongodb.internal.connection.SaslAuthenticator$2
private final Continuator = com.mongodb.internal.connection.SaslAuthenticator$Continuator of com.mongodb.internal.connection.SaslAuthenticator