REDHAT-BUG-2552733: High severity PgBouncer PgBouncer vulnerability
Improper authentication in PgBouncer 1.17.0 through 1.26.0 allows a remote attacker who knows the password of a user listed in authfile to log in as any other user that authenticates using SCRAM, including PgBouncer admin users and backend superusers. A second StartupMessage sent during SCRAM authentication against a non-existent database is not rejected and switches the user being logged in as, while the SCRAM exchange is still verified against the keys of the first user.
Affected Software
Event History
Frequently Asked Questions
Which deployments are exposed to this issue?
PgBouncer versions 1.17.0 through 1.26.0 are affected where a user listed in auth_file can authenticate with a known password and another account uses SCRAM authentication. Potential target accounts include PgBouncer administrators and backend superusers when they authenticate using SCRAM.
What does an attacker need before attempting exploitation?
The attacker needs the password for any user listed in PgBouncer's auth_file. They can then use a second StartupMessage during SCRAM authentication against a non-existent database to switch the identity being logged in as.
How can I assess whether a suspected login may indicate exploitation?
Review SCRAM authentication activity for connections involving a non-existent database and a second StartupMessage during the authentication exchange. The issue can result in a login under a different user identity than the account whose SCRAM keys were used for verification.