MySQLPacketHandshakeResponse41 class

Representa o pacote de resposta ao handshake (versão 41) do protocolo MySQL.

Esse pacote é enviado pelo cliente como resposta ao handshake inicial do servidor. Ele contém informações como:

  • capabilityFlags: Flags de capacidades do cliente.
  • maxPacketSize: Tamanho máximo do pacote suportado.
  • characterSet: Conjunto de caracteres utilizado na conexão.
  • authResponse: Dados de autenticação calculados (por exemplo, usando sha1 ou sha256).
  • authPluginName: Nome do plugin de autenticação a ser utilizado.
  • username: Nome do usuário conectado.
  • database (opcional): Nome do banco de dados a ser utilizado, se informado.
Inheritance

Constructors

MySQLPacketHandshakeResponse41.new({required int capabilityFlags, required int maxPacketSize, required int characterSet, required Uint8List authResponse, required String authPluginName, required String username, String? database})
Construtor da classe.
MySQLPacketHandshakeResponse41.createWithCachingSha2Password({required String username, required String password, required MySQLPacketInitialHandshake initialHandshakePayload})
Cria uma resposta de handshake utilizando o método caching_sha2_password para autenticação.
factory
MySQLPacketHandshakeResponse41.createWithNativePassword({required String username, required String password, required MySQLPacketInitialHandshake initialHandshakePayload})
Cria uma resposta de handshake utilizando o método nativo de autenticação (mysql_native_password).
factory

Properties

authPluginName String
getter/setter pair
authResponse Uint8List
getter/setter pair
capabilityFlags int
getter/setter pair
characterSet int
getter/setter pair
database String?
getter/setter pair
hashCode int
The hash code for this object.
no setterinherited
maxPacketSize int
getter/setter pair
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
username String
getter/setter pair

Methods

encode() Uint8List
Codifica o pacote de handshake response em um Uint8List para envio ao servidor.
override
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited