CVE-2025-24375 MySQL K8s charm could leak credentials for root-level user `serverconfig`
An unprivileged user can read temporary files to steal root-level database credentials from the MySQL Kubernetes operator.
- Exploited in the wild
- Not known
- Login needed
- Any signed-in user
- Attackable
- Local or same network only
- Victim action needed
- A user has to click or open something
- Fix
- None listed
What is CVE-2025-24375?
CVE-2025-24375 is a medium-severity vulnerability in canonical mysql-k8s-operator, published on 9 Apr 2025. It can only be exploited from the same machine or local network, and only if a user opens a file or follows a link.
Official description
Charmed MySQL K8s operator is a Charmed Operator for running MySQL on Kubernetes. Before revision 221, the method for calling a SQL DDL or python based mysql-shell scripts can leak database users credentials. The method mysql-operator calls mysql-shell application rely on writing to a temporary script file containing the full URI, with user and password. The file can be read by a unprivileged user during the operator runtime, due it being created with read permissions (0x644). On other cases, when calling mysql cli, for one specific case when creating the operator users, the DDL contains said users credentials, which can be leak through the same mechanism of a temporary file. All versions prior to revision 221 for kubernetes and revision 338 for machine operators.
Weakness: CWE-256
Which versions are affected by CVE-2025-24375?
How do I fix CVE-2025-24375?
No fix has been published for CVE-2025-24375 yet. Limit exposure of the affected software until one is available.
Is CVE-2025-24375 being exploited?
There is no known exploitation of CVE-2025-24375 in the wild and no public exploit code.
Sources
Also known as GHSA-g83v-7694-2hf7.