---
name: rt-exploit-mysql
description: "MySQL security assessment skill for authorized configuration review, privilege analysis, exposure validation, SQL injection impact scoping, logging, backup posture, and remediation."
---

# rt-exploit-mysql - MySQL Assessment

## Overview

MySQL findings usually combine application-layer injection, excessive database privileges, weak network exposure, insecure backups, or missing encryption. This skill keeps validation scoped and evidence minimal.

## Prerequisites

- Database host/port or application endpoint in scope.
- Approved account or application test role.
- Data sampling limits.
- Permission for configuration review if direct DB access is provided.

## Assessment Areas

| Area | Checks |
|---|---|
| Exposure | Public listener, firewall rules, allowed source networks. |
| Authentication | Root remote login, weak/shared users, password policy. |
| Privileges | FILE, SUPER, CREATE USER, GRANT OPTION, broad schema rights. |
| Transport | TLS requirement and certificate posture. |
| Application Queries | Parameterization and stored procedure usage. |
| Backups | Public dumps, weak storage permissions, retention. |
| Logging | Audit logs, slow query logs, failed login visibility. |

## Workflow

1. Confirm whether testing is direct database review or app-mediated.
2. Inventory version, exposure, and account privileges.
3. Validate injection impact with approved test data only.
4. Review whether application role can access unnecessary schemas.
5. Review sensitive data handling and backup locations.
6. Convert issues into least-privilege and query-safety recommendations.

## Evidence

Capture version, privilege summaries, endpoint proof, redacted query behavior, and screenshots. Do not dump production tables.

## Remediation

- Parameterized queries.
- Least-privilege application users.
- Disable remote root access.
- Enforce TLS for database connections.
- Restrict network access.
- Protect and encrypt backups.
- Add database activity monitoring.

