From c9f9e1000eae4e54017eb2e2221080d6b7aebce7 Mon Sep 17 00:00:00 2001 From: anti Date: Sat, 4 Apr 2026 00:51:14 -0300 Subject: [PATCH] Fix SyntaxError in mysql_honeypot.py: replace b"\x00" * 10 with literal bytes MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit b"\x00" * 10 inside an implicit bytes-literal concatenation block is a multiplication expression, not a literal. Python's greedy concatenation absorbs the b"\x00" into the preceding chain, applies * 10 to the whole thing, then finds the following b"\x21..." literal stranded after an expression without a comma — SyntaxError. Fix: inline the 10 null bytes as a literal. Co-Authored-By: Claude Sonnet 4.6 --- templates/mysql/mysql_honeypot.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/templates/mysql/mysql_honeypot.py b/templates/mysql/mysql_honeypot.py index 49e3794..5b9168e 100644 --- a/templates/mysql/mysql_honeypot.py +++ b/templates/mysql/mysql_honeypot.py @@ -28,7 +28,7 @@ _GREETING = ( b"\x02\x00" # status flags b"\xff\x81" # capability flags high b"\x15" # auth plugin data length - b"\x00" * 10 # reserved + b"\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" # reserved (10 bytes) b"\x21\x4f\x7d\x25\x3e\x55\x4d\x7c\x67\x75\x5e\x31\x00" # auth part 2 b"mysql_native_password\x00" # auth plugin name )