public class NativeAuthenticationProvider extends java.lang.Object implements AuthenticationProvider<NativePacketPayload>
Modifier and Type | Field and Description |
---|---|
protected static int |
AUTH_411_OVERHEAD |
protected java.lang.String |
seed |
Constructor and Description |
---|
NativeAuthenticationProvider() |
Modifier and Type | Method and Description |
---|---|
void |
changeUser(ServerSession serverSession,
java.lang.String userName,
java.lang.String password,
java.lang.String database)
Re-authenticates as the given user and password
|
void |
connect(ServerSession sessState,
java.lang.String user,
java.lang.String password,
java.lang.String database)
Initialize communications with the MySQL server.
|
java.lang.String |
getEncodingForHandshake()
Get the Java encoding to be used for the handshake
response.
|
ExceptionInterceptor |
getExceptionInterceptor() |
void |
init(Protocol<NativePacketPayload> prot,
PropertySet propSet,
ExceptionInterceptor excInterceptor) |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getCharsetForHandshake
protected static final int AUTH_411_OVERHEAD
protected java.lang.String seed
public void init(Protocol<NativePacketPayload> prot, PropertySet propSet, ExceptionInterceptor excInterceptor)
init
in interface AuthenticationProvider<NativePacketPayload>
public void connect(ServerSession sessState, java.lang.String user, java.lang.String password, java.lang.String database)
connect
in interface AuthenticationProvider<NativePacketPayload>
sessState
- The session state object. It's intended to be updated from the handshakeuser
- user namepassword
- passworddatabase
- database namepublic java.lang.String getEncodingForHandshake()
getEncodingForHandshake
in interface AuthenticationProvider<NativePacketPayload>
public ExceptionInterceptor getExceptionInterceptor()
public void changeUser(ServerSession serverSession, java.lang.String userName, java.lang.String password, java.lang.String database)
changeUser
in interface AuthenticationProvider<NativePacketPayload>
serverSession
- current ServerSession
userName
- user namepassword
- passworddatabase
- database name