CVE-2019-11039
📋 TL;DR
This vulnerability in PHP's iconv_mime_decode_headers() function allows attackers to trigger an integer overflow leading to out-of-bounds memory reads. This can cause information disclosure or application crashes. It affects PHP applications running vulnerable versions that process MIME headers.
💻 Affected Systems
- PHP
📦 What is this software?
Leap by Opensuse
Leap by Opensuse
Php by Php
Php by Php
Php by Php
⚠️ Risk & Real-World Impact
Worst Case
Remote code execution through memory corruption leading to complete system compromise, though this requires specific memory layout conditions.
Likely Case
Information disclosure through memory reads (potentially exposing sensitive data) or denial of service through application crashes.
If Mitigated
Limited impact with proper input validation and memory protection mechanisms in place.
🎯 Exploit Status
Exploitation requires triggering the vulnerable function with specially crafted MIME headers.
🛠️ Fix & Mitigation
✅ Official Fix
Patch Version: PHP 7.1.30, 7.2.19, 7.3.6 or later
Vendor Advisory: https://bugs.php.net/bug.php?id=78069
Restart Required: Yes
Instructions:
1. Update PHP to patched version using your package manager (apt-get upgrade php, yum update php, etc.) 2. Restart web server (apache2 restart, systemctl restart nginx) 3. Verify PHP version with php -v
🔧 Temporary Workarounds
Disable vulnerable function
allDisable or avoid using iconv_mime_decode_headers() function in application code
Input validation
allImplement strict input validation for MIME headers before processing
🧯 If You Can't Patch
- Implement WAF rules to block malicious MIME headers
- Isolate vulnerable systems behind reverse proxies with input filtering
🔍 How to Verify
Check if Vulnerable:
Check PHP version with php -v and compare against affected versions
Check Version:
php -v | grep "PHP"
Verify Fix Applied:
Verify PHP version is 7.1.30+, 7.2.19+, or 7.3.6+
📡 Detection & Monitoring
Log Indicators:
- Application crashes in PHP error logs
- Unusual memory access patterns
Network Indicators:
- Malformed MIME headers in HTTP requests
SIEM Query:
source="php_error.log" AND ("segmentation fault" OR "out of bounds" OR "memory corruption")
🔗 References
- http://lists.opensuse.org/opensuse-security-announce/2019-07/msg00029.html
- https://access.redhat.com/errata/RHSA-2019:2519
- https://access.redhat.com/errata/RHSA-2019:3299
- https://bugs.php.net/bug.php?id=78069
- https://seclists.org/bugtraq/2019/Sep/35
- https://seclists.org/bugtraq/2019/Sep/38
- https://www.debian.org/security/2019/dsa-4527
- https://www.debian.org/security/2019/dsa-4529
- http://lists.opensuse.org/opensuse-security-announce/2019-07/msg00029.html
- https://access.redhat.com/errata/RHSA-2019:2519
- https://access.redhat.com/errata/RHSA-2019:3299
- https://bugs.php.net/bug.php?id=78069
- https://seclists.org/bugtraq/2019/Sep/35
- https://seclists.org/bugtraq/2019/Sep/38
- https://www.debian.org/security/2019/dsa-4527
- https://www.debian.org/security/2019/dsa-4529