WeGIA
CVE-2025-62360
CRITICAL
Attack ChainAIDerived
Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain
-
AccessAuthenticate to WeGIA instance
-
ExploitPOST crafted id_dependente parameter
-
ExecutionTrigger unsanitized SQL injection
-
ImpactExfiltrate or tamper with database records
Vulnerability Assessment
| Weakness |
CWE
OWASP Top 10:2025
A05:2025 - Injection
ASVS 5.0
V1 - Encoding and Sanitization Parameterized queries, prepared statements
MITRE ATT&CK
2 techniques across 2 tactics: Initial Access, Persistence The technique list with ATT&CK links and the kill-chain view is part of the Basic plan and up. |
| Exploitation Conditions | Exploitation requires an authenticated session to WeGIA: the endpoint /html/funcionario/dependente_documento.php checks $_SESSION['usuario'] and includes permissao.php before processing, so an attacker needs valid credentials or a hijacked session (consistent with CVSS PR:H/PR:L, not PR:N). Given that gate, no further special configuration is needed - any WeGIA deployment prior to 3.5.1 is affected in its default state, and the attacker simply sends a POST request with a malicious id_dependente value. The main limiting factors are the authentication requirement and the product's very small deployment base; there is no user-interaction requirement (UI:N) and attack complexity is low (AC:L). |
| Impact | This is a genuine high-severity SQL injection (CWE-89) with strong source-code confirmation: the patch diff shows the id_dependente value was taken directly from $_POST and interpolated into the query string, and the fix replaces it with filter_input() plus a bound PDO prepared statement - so the flaw is real and unambiguous. However, the signals point to a serious-but-not-emergency priority rather than a mass-exploitation event. The provided CVSS 4.0 vector (9.4) uses PR:H and marks subsequent-system impact (SC/SI/SA:H) as High, but the patched code only gates the endpoint behind a logged-in session ($_SESSION['usuario']) and a permissao.php check - that implies an authenticated low-privilege user, not a high-privilege operator, and there is no evidence of a scope change affecting a separate system, so the vendor vector likely overstates both PR and subsequent impact. Publicly available exploit code exists (Exploit-DB 52483) which raises practical risk, but the CVE is NOT in CISA KEV and EPSS is only 0.89% (58th percentile), indicating no observed widespread exploitation. Net: confirmed, easily exploitable post-authentication database compromise, but constrained by the authentication requirement and the niche footprint of the product, so this is a prompt-patch item rather than a drop-everything emergency. |
| Exploit ScenarioDerived | An authenticated WeGIA user (or an attacker who has obtained any valid session) submits a crafted id_dependente value in a POST request to /html/funcionario/dependente_documento.php, injecting arbitrary SQL that the application concatenates directly into its query. Public exploit code is available (Exploit-DB 52483), making reliable extraction, modification, or destruction of database contents straightforward. Because CVSS is AV:N/AC:L, this requires only network access and a single well-formed request with no special timing or race conditions. |
Get an e-mail when this CVE is exploited, patched or re-scored. Free account.
Alert meAnalysisAIv1 – Oct 08, 2026
SQL injection in WeGIA prior to 3.5.1 allows an authenticated remote attacker to execute arbitrary SQL statements through the id_dependente POST parameter of the /html/funcionario/dependente_documento.php endpoint, fully compromising the confidentiality, integrity, and availability of the underlying database. The endpoint enforces an authenticated session ($_SESSION['usuario'] plus permissao.php), so valid credentials or a hijacked session are required, but no user interaction or special configuration is needed and the attack complexity is low. Publicly available exploit code exists, including an Exploit-DB entry and GitHub security advisories, and EPSS estimates roughly a 0.9% probability of exploitation in the near term (58th percentile); the vulnerability is fixed in WeGIA 3.5.1.
RemediationAI
Vendor-released patch: upgrade WeGIA to 3.5.1, which replaces the concatenated query in /html/funcionario/dependente_documento.php with filter_input() integer validation and a bound PDO prepared statement (fix commit https://github.com/LabRedesCefetRJ/WeGIA/commit/7abbffd3915a64b97dde01954222fc0fbd804f70); see advisories https://github.com/LabRedesCefetRJ/WeGIA/security/advisories/GHSA-m4j6-q5m4-x24g and https://github.com/LabRedesCefetRJ/WeGIA/security/advisories/GHSA-mwvv-q9gh-gwxm. If immediate upgrade is not possible, apply compensating controls with their trade-offs in mind: restrict network access to the /html/funcionario/ directory (ideally to trusted administrative hosts) so the endpoint cannot be reached by lower-privileged or external users, accepting that this may break legitimate remote staff workflows; enforce the permissao.php role checks strictly and audit who currently holds dependente/document permissions, revoking unnecessary accounts, since the flaw still requires an authenticated session; deploy a WAF rule blocking non-integer or SQL-metacharacter content in POST parameter id_dependente on that path, understanding that WAF coverage is a partial and bypassable mitigation; and because exploitation yields full database read/write, review web and MySQL logs for anomalous POSTs to dependente_documento.php and rotate database credentials and any user passwords that may have been exposed. There is no evidence of active exploitation in CISA KEV at time of analysis, but publicly available exploit code exists, so treat exposure reduction and patching as time-sensitive.
Affects your stack
Find out whether the stacks and servers you run are on an affected version.
Checking this CVE against your own stacks and servers is part of the Basic plan and up.
Technical ContextAI · show details
WeGIA is a PHP web application (Web Manager for Institutions) aimed at Portuguese-speaking users, and CVE-2025-62360 is a classic CWE-89 SQL injection rooted in unsafe string interpolation. In versions before 3.5.1, html/funcionario/dependente_documento.php read the raw $_POST['id_dependente'] value and concatenated it directly into the query "SELECT doc.nome_docdependente AS descricao, ddoc.data, ddoc.id_doc FROM funcionario_dependentes_docs ddoc LEFT JOIN funcionario_docdependentes doc ON doc.id_docdependentes = ddoc.id_docdependentes WHERE ddoc.id_dependente=$id_dependente;", which was then passed to $pdo->query(). Because the value was never bound as a parameter or type-checked, an attacker could break out of the intended integer comparison and inject arbitrary SQL against the PDO/MySQL back end, with results returned to the attacker as JSON via json_encode(). The upstream fix (commit 7abbffd3915a64b97dde01954222fc0fbd804f70) replaces the concatenation with filter_input(INPUT_POST, 'id_dependente', FILTER_SANITIZE_NUMBER_INT) validation plus a PDO prepared statement using bindParam(':idDependente', ...), and also adds session status checks, session_regenerate_id(), and exception handling through Util::tratarException(); the CWE-89 diagnosis is therefore confirmed directly by the patch diff. The affected CPE is cpe:2.3:a:wegia:wegia:*:*:*:*:*:*:*:* (all releases prior to 3.5.1).
Know when Wegia gets its next vulnerability
- Watch products and get an email when something new is published
- Check this CVE against your own stack and servers
- Exploit and PoC references, threat intelligence from 22 sources
No credit card · 7-day full trial
Severity by source
CVSS:4.0/AV:N/AC:L/AT:N/PR:H/UI:N/VC:H/VI:H/VA:H/SC:H/SI:H/SA:H
Network-reachable endpoint with a single crafted request (AV:N/AC:L), but the code requires an authenticated session so PR:L not PR:N; full DB confidentiality, integrity and availability impact with no scope change (S:N).
Primary rating from Vendor (github).
CVSS VectorVendor: github
DescriptionCVE.org
WeGIA is an open source Web Manager for Institutions with a focus on Portuguese language users.Prior to 3.5.1, a SQL Injection vulnerability was identified in the /html/funcionario/dependente_documento.php endpoint, specifically in the id_dependente parameter. This vulnerability allows attackers to execute arbitrary SQL commands, compromising the confidentiality, integrity, and availability of the database. This vulnerability is fixed in 3.5.1.
Executive ViewAI
A critical SQL injection flaw in WeGIA, the platform used to manage municipal records, exposes the underlying database to full compromise of confidentiality, integrity, and availability; publicly available exploit code exists, raising the likelihood that the technique will be reused against unpatched deployments. Because WeGIA typically stores citizen, employee, and dependent records, a successful attack could result in mass data exposure, unauthorized record alteration or deletion, and regulatory notification obligations for the affected municipality. Leadership should treat remediation as urgent for any instance still running a version earlier than 3.5.1.
Apply vendor patch.
Threat Intelligence Overview
How this decision was reached
The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.
What every action level means
SSVC AssessmentENISA
Priority Score
Attack Technique
SQL injection exploits the way applications construct database queries by mixing user input directly into SQL statements.
Affected Products (CPE)CVE.org
Critical OS Command Injection vulnerability in WeGIA (a web management system for charitable institutions) versions prio
WeGIA is a Web manager for charitable institutions. Rated critical severity (CVSS 10.0), this vulnerability is remotely
WeGIA is an open source Web Manager for Institutions with a focus on Portuguese language users. Rated critical severity
WeGIA is an open source web manager with a focus on the Portuguese language and charitable institutions. Rated critical
WeGIA is a Web manager for charitable institutions. Rated critical severity (CVSS 10.0), this vulnerability is remotely
WeGIA is a web manager for charitable institutions. Rated critical severity (CVSS 10.0), this vulnerability is remotely
WeGIA is an open source Web Manager for Institutions with a focus on Portuguese language users. Rated critical severity
WeGIA is an open source Web Manager for Institutions with a focus on Portuguese language users. Rated critical severity
WeGIA is an open source Web Manager for Institutions with a focus on Portuguese language users. Rated critical severity
WeGIA is an open source Web Manager for Institutions with a focus on Portuguese language users. Rated critical severity
WeGIA is an open source Web Manager for Institutions with a focus on Portuguese language users. Rated critical severity
WeGIA is an open source Web Manager for Institutions with a focus on Portuguese language users. Rated critical severity
NVD
CVE.org
EPSS
Exploit-DB
GitHub