MDEV-40027 : Galera Cluster-peer > Donor command execution#5234
MDEV-40027 : Galera Cluster-peer > Donor command execution#5234janlindstrom wants to merge 2 commits into
Conversation
There was a problem hiding this comment.
Code Review
This pull request introduces input validation for the wsrep_sst_auth variable to prevent shell injection, along with corresponding test cases. However, several issues were identified in the review: the shell_char function uses a blacklist approach that is vulnerable to command injection and should be replaced with a strict whitelist; the safe function in the mariabackup script is incorrectly passed the variable name instead of its value; and multiple temporary debug logs (JAN:JAN) need to be removed before merging.
Important
The consumer version of Gemini Code Assist on GitHub is being sunset. Starting June 18, 2026, new organization installations will be blocked, and all code review activity will officially cease on July 17, 2026.
For more details on the timeline and next steps, please review the Help Documentation.
6599821 to
c03f58c
Compare
7312085 to
d53a22a
Compare
An appropriately privileged user (with SUPER privileges) could execute shell commands as the uid of the mariadbd process because the values of the system variable wsrep_sst_auth, which can be modified at runtime, were not properly sanitized when used to construct a shell command. Combined rsync and mariabackup test cases and added test case for incorrect values for wsrep_sst_auth.
Fix potential issue with wsrep_node_address by allowing only correctly constructed address.
d53a22a to
a5a2571
Compare
An appropriately privileged user (with SUPER privileges) could execute shell commands as the uid of the mariadbd process because the values of the system variable wsrep_sst_auth, which can be modified at runtime, were not properly sanitized when used to construct a shell command.