CVE-2026-39323
Critical SQL Injection in ChurchCRM PropertyTypeEditor.php Allows Data Manipulation
Publication date: 2026-04-07
Last updated on: 2026-04-09
Assigner: GitHub, Inc.
Description
Description
CVSS Scores
EPSS Scores
| Probability: | |
| Percentile: |
Meta Information
Affected Vendors & Products
| Vendor | Product | Version / Range |
|---|---|---|
| churchcrm | churchcrm | to 7.1.0 (exc) |
| churchcrm | churchcrm | to 7.0.5 (inc) |
Helpful Resources
Exploitability
| CWE ID | Description |
|---|---|
| CWE-89 | The product constructs all or part of an SQL command using externally-influenced input from an upstream component, but it does not neutralize or incorrectly neutralizes special elements that could modify the intended SQL command when it is sent to a downstream component. Without sufficient removal or quoting of SQL syntax in user-controllable inputs, the generated SQL query can cause those inputs to be interpreted as SQL instead of ordinary user data. |
Attack-Flow Graph
AI Powered Q&A
How does this vulnerability affect compliance with common standards and regulations (like GDPR, HIPAA)?:
This SQL injection vulnerability allows authenticated users with specific permissions to execute arbitrary SQL commands, including data exfiltration, modification, and deletion. Such unauthorized access and manipulation of sensitive data can lead to breaches of confidentiality and integrity.
Because the vulnerability enables potential exposure and alteration of sensitive personal or organizational data, it can negatively impact compliance with common standards and regulations such as GDPR and HIPAA, which require protection of data confidentiality, integrity, and availability.
Failure to remediate this vulnerability could result in unauthorized data disclosure or modification, leading to regulatory non-compliance, legal penalties, and reputational damage.
Can you explain this vulnerability to me?
This vulnerability is a critical SQL injection issue in ChurchCRM's PropertyTypeEditor.php file prior to version 7.1.0. It occurs because the POST parameters "Name" and "Description" are sanitized only by removing HTML tags (using strip_tags()) but are then directly concatenated into SQL queries without proper escaping of SQL special characters.
As a result, authenticated users with the "Manage Properties" permission can inject arbitrary SQL commands. These commands can lead to unauthorized data exfiltration, modification, and deletion within the database.
The injected malicious data persists in the database and is reflected across multiple application pages without proper output encoding, increasing the risk of data exposure.
The root cause is misuse of a sanitization function intended for preventing cross-site scripting (XSS), not SQL injection, leading to improper neutralization of SQL special elements.
How can this vulnerability impact me? :
This vulnerability can have severe impacts including unauthorized access to sensitive data, data modification, and data deletion within the ChurchCRM database.
An attacker with "Manage Properties" permission can execute arbitrary SQL commands, potentially extracting confidential information such as admin credentials.
Because the injected data persists and is reflected across multiple pages without proper encoding, it can lead to widespread data integrity issues and exposure.
How can this vulnerability be detected on my network or system? Can you suggest some commands?
This vulnerability can be detected by checking for the presence of vulnerable ChurchCRM versions (7.0.5 and earlier) and by inspecting the PropertyTypeEditor.php file for unsafe usage of InputUtils::sanitizeText() on the 'Name' and 'Description' POST parameters without proper SQL escaping.
To detect exploitation attempts or test for the vulnerability, you can monitor HTTP POST requests to PropertyTypeEditor.php containing suspicious SQL injection payloads in the 'Name' or 'Description' parameters.
- Use network monitoring tools (e.g., Wireshark, tcpdump) to capture POST requests to PropertyTypeEditor.php and search for SQL injection patterns.
- On the server, grep the source code for the vulnerable function usage: `grep -n 'InputUtils::sanitizeText' PropertyTypeEditor.php` and verify if it is used without SQL escaping.
- Check the ChurchCRM version installed by running: `grep 'version' path/to/ChurchCRM/version.php` or similar to confirm if it is older than 7.1.0.
- Look for suspicious database entries in the propertytype_prt table that contain injected SQL payloads or unexpected data patterns.
What immediate steps should I take to mitigate this vulnerability?
Immediate mitigation steps include upgrading ChurchCRM to version 7.1.0 or later, where the vulnerability is fixed.
If upgrading immediately is not possible, apply a quick fix by replacing the unsafe sanitization function InputUtils::sanitizeText() with InputUtils::legacyFilterInput(), which properly escapes SQL inputs.
- Replace code lines: `$sName = InputUtils::sanitizeText($_POST['Name']);` and `$sDescription = InputUtils::sanitizeText($_POST['Description']);`
- With: `$sName = InputUtils::legacyFilterInput($_POST['Name'], 'string');` and `$sDescription = InputUtils::legacyFilterInput($_POST['Description'], 'string');`
For a more robust and recommended fix, refactor the code to use prepared statements with parameterized queries to eliminate SQL injection risks entirely.
Additionally, restrict the 'Manage Properties' permission to trusted users only, as the vulnerability requires authenticated users with this permission.