Piwigo
Piwigo: SQL injection in upgrade authentication allows unauthenticated upgrade authorization bypass (PHP 8+)
Piwigo is a full featured open source photo gallery application for the web. Prior to 16.4.0, check_upgrade_access_rights() in admin/include/functions_upgrade.php conditionally escapes the submitted username only when the removed get_magic_quotes_gpc function exists, so PHP 8 and later concatenate an unauthenticated username directly into the upgrade authentication SQL query. When database upgrades are pending, a crafted query result can satisfy the status and password checks, set PHPWG_IN_UPGRADE, and authorize upgrade execution without valid administrator credentials. This can cause unauthorized database integrity changes and service disruption. This vulnerability is fixed in 16.4.0.
Affected versions and mitigation
From the CVE record and the vendor's references.Affected
- < 16.4.0
Fixed in 16.4.0
Mitigation
Upgrade Piwigo to 16.4.0 or later.
References
- Vendor advisory github.com/Piwigo/Piwigo/security/advisories/G…
- Patch github.com/Piwigo/Piwigo/commit/1ff9d04534feb5…
- Patch github.com/Piwigo/Piwigo/commit/2cfa7a3d194c8b…
1 more
- Release notes github.com/Piwigo/Piwigo/releases/tag/16.4.0
Timeline
Days relative to CVE publicationNo public PoC found yet; not in CISA KEV.
PoC repositories
Found on GitHub.No PoC repositories found yet.