External risk intelligence

Piwigo Installer Arbitrary Code Execution via Unsanitized POST Parameters

CVE advisorySeverity: CRITICAL (CVSS 9.8)

CVE-2026-35048

Piwigo is a photo gallery software application designed to be deployed as a web-accessible service. Because it is a web application intended for sharing media, installations are commonly deployed on web servers with public-facing interfaces to allow users to view or upload content.

Halo Surface Signal: 4 out of 5 — likely to be public-facing.

External exposure likelihood

Horizon Alert

Summary of the vulnerability and why it matters

A vulnerability has been identified in the Piwigo installer that could allow an unauthenticated attacker to execute arbitrary PHP code. This occurs because the installer improperly handles database configuration parameters, writing them directly into a PHP configuration file without adequate sanitization, especially on newer PHP versions. The potential for code injection means that if our organization uses this software, it could be a target for significant compromise.

  • Code execution risk in Piwigo installer.
  • Affects web applications, commonly exposed externally.
  • Confirm relevance and potential exposure.

Attack Path

How an attacker could exploit the issue

An unauthenticated attacker can compromise a Piwigo installation by sending specially crafted POST requests to the installer. These requests can inject malicious PHP code into the application's database configuration file, which is then executed when any page on the site is accessed, potentially leading to full system compromise.

  • No authentication required.
  • Installer accepts malicious POST parameters.
  • Arbitrary PHP code execution.

Live Threat

Current exploitation, exposure, and threat context

This vulnerability could allow an unauthenticated attacker to execute arbitrary PHP code on a Piwigo installation when it runs on PHP 8+. This occurs because installer database configuration parameters are written directly into a PHP configuration file without sufficient sanitization, bypassing existing protections and enabling code injection.

  • Arbitrary PHP code execution on the server.
  • Exploitation via malicious POST parameters.
  • Compromise of the Piwigo application.

Operational Fix

Recommended remediation, mitigation, and detection steps

The Piwigo installer's vulnerability requires intervention from teams responsible for the application and its underlying infrastructure. The first practical step is to locate all Piwigo installations, assess their accessibility and business criticality, and identify the accountable application owner. Subsequent remediation planning should be risk-based, considering factors like exposure and maintenance windows.

  • Application owners should manage remediation.
  • Verify Piwigo installation reachability.
  • Plan maintenance for risk-based fixes.

Supplementary metadata

Validate whether this threat affects your internet-facing exposure.

Halo Threat Intelligence helps prioritize remediation with Halo Surface Signal and H/A/L/O context. Start exposure validation with a free external attack surface trial.

Frequently asked questions

What is Piwigo?

Piwigo is a web-based photo gallery application used to manage, organize, and share digital image collections. It is designed to be installed on a web server, where it functions as a service that visitors can access to browse or upload media files.

What is the vulnerability in CVE-2026-35048?

This flaw is a form of Improper Input Validation (CWE-20). The software's installer fails to properly sanitize user-provided database configuration data. Because it writes this raw input directly into a PHP file, an attacker can inject malicious code that the server later executes as part of the application.

How can an attacker trigger this bug?

An attacker can exploit this by sending a specially crafted POST request containing malicious code within fields like the database name or user. This process only occurs during installation or configuration. It does not trigger if the installation is already complete and the installer script is removed or inaccessible.

Why does Halo Surface Signal categorize this as external?

Halo Surface Signal identifies this as an external risk because Piwigo is typically deployed as a web-accessible gallery. Since these installations are often intended for public media sharing, they frequently reside on servers reachable over the internet, making them accessible to any remote attacker.

What should I do if I run Piwigo?

You should first locate all instances of Piwigo within your environment and identify the owners responsible for them. Once identified, evaluate the accessibility and criticality of these installations. Coordinate with the relevant teams to plan a maintenance window for applying available security updates.

References