[MXS-2630] mysqldump rejected by maxscale (Query could not be tokenized) Created: 2019-08-13  Updated: 2020-04-07  Resolved: 2020-03-03

Status: Closed
Project: MariaDB MaxScale
Component/s: dbfwfilter, qc_sqlite
Affects Version/s: 2.3.11
Fix Version/s: N/A

Type: Bug Priority: Major
Reporter: Thies Meincke Assignee: Johan Wikman
Resolution: Won't Fix Votes: 0
Labels: None
Environment:

maxscale: SLES 12.4
Clients: SLES 12.4, Mint 19


Sprint: MXS-SPRINT-101

 Description   

mysqldump from clients rejected by maxscale when dbfwfilter is active:

mysqldump -p -u ***** -h ***** testdb1 > testdb1.dump
Enter password:
mysqldump: Couldn't execute '/!40100 SET @@SQL_MODE='' */': Access denied for user 'r***'@'****': Query could not be tokenized and will hence be rejected. Please ensure that the SQL syntax is correct. (1141)

maxscale-log:
2019-08-13 09:21:20 info : (17) Parsing the query failed, cannot report query type: /*!40100 SET @@SQL_MODE='' */

mysqldump works if dbfwfilter is not used by maxscale



 Comments   
Comment by Johan Wikman [ 2020-03-03 ]

The MaxScale parser detects but does not handle MariaDB version specific comment such as

/!40100 SET @@SQL_MODE='' */

but treats them as regular comments. Further, as the parser does not know what the actual effect of that comment will be, it marks the statement as having at most been partially parsed.

The firewall rejects all statements that have not been fully parsed as otherwise that could be used for bypassing the firewall rules.

Generated at Thu Feb 08 04:15:32 UTC 2024 using Jira 8.20.16#820016-sha1:9d11dbea5f4be3d4cc21f03a88dd11d8c8687422.