sqlmapproject/sqlmap · error · NotSupportedError
unsupported authentication plugin '%s'
Error message
unsupported authentication plugin '%s'
What it means
Error "unsupported authentication plugin '%s'" thrown in sqlmapproject/sqlmap.
Source
Thrown at extra/dbwire/mysql.py:270
def _finish_auth(sock, password, plugin, salt):
# read the auth result, handling AuthSwitchRequest (0xfe) and AuthMoreData (0x01) for caching_sha2
while True:
seq, payload = _read_packet(sock)
marker = _u8(payload, 0)
if marker == 0x00: # OK
return
if marker == 0xff: # ERR
raise OperationalError("(remote) %s" % _err_message(payload))
if marker == 0xfe: # AuthSwitchRequest: <plugin name>\x00<salt>
plugin, off = _cstring(payload, 1)
plugin = plugin.decode("ascii", "replace")
salt = payload[off:].rstrip(b"\x00")
if plugin == "mysql_native_password":
data = _scramble_native(password, salt)
elif plugin == "caching_sha2_password":
data = _scramble_sha2(password, salt)
else:
raise NotSupportedError("unsupported authentication plugin '%s'" % plugin)
_send_packet(sock, seq + 1, data)
elif marker == 0x01: # AuthMoreData (caching_sha2)
status = _u8(payload, 1)
if status == 0x03: # fast auth success -> OK packet follows
continue
elif status == 0x04: # full auth required (needs TLS or RSA - not available stdlib-only)
raise NotSupportedError("caching_sha2_password full authentication over a plaintext connection "
"requires RSA/TLS; use a mysql_native_password account for the dependency-free client")
else:
raise OperationalError("unexpected caching_sha2 auth status %d" % status)
else:
raise InterfaceError("unexpected authentication response 0x%02x" % marker)
def connect(host=None, port=3306, user=None, password=None, database=None, connect_timeout=None, **kwargs):
try:
sock = socket.create_connection((host or "localhost", int(port or 3306)), timeout=connect_timeout)
keepalive(sock)
except (socket.error, socket.timeout) as ex:View on GitHub (pinned to 0a35b20e39)
When it happens
Trigger: Thrown at extra/dbwire/mysql.py:270 when the library encounters an invalid state.
Common situations: See trigger scenarios.
Understand the failure class
- Authentication and authorization failures — expired tokens, bad credentials, and missing scopes.
AI-assisted analysis of sqlmapproject/sqlmap@0a35b20e39 (2026-08-26).
Data as JSON: /api/errors/d40f141941f9e3d4.
Report an issue: GitHub.