Overprivileged Database Users
Creating database users with excessive privileges violates the principle of least privilege. When application users have ALL PRIVILEGES or administrative access, SQL injection attacks can cause much more damage including dropping databases, accessing other applications' data, or executing system commands.
Preview example – SQL
-- VULNERABLE: Overprivileged database user
CREATE USER 'app_user'@'%' IDENTIFIED BY 'simple_password';
GRANT ALL PRIVILEGES ON *.* TO 'app_user'@'%';
-- This user can access ALL databases and perform ANY operation
-- SQL injection can now DROP databases, read other apps' data, etc.