严重 imap_open()允许通过mailbox参数运行任意shell命令
CVE编号
CVE-2018-19518利用情况
漏洞武器化补丁情况
官方补丁披露时间
2018-11-25漏洞描述
UNIX上的University of Washington IMAP Toolkit 2007f ,用于PHP和其他产品中的imap_open(),启动rsh命令(通过c-client / imap4r1.c中的imap_rimap函数和osdep/unix/tcp_unix.c中的tcp_aopen函数 )不阻止参数注入,如果IMAP服务器名称是不可信输入(例如,由Web应用程序的用户输入)并且rsh已被具有不同参数的程序替换,则可能允许远程攻击者执行任意OS命令语义。例如,如果rsh是指向ssh的链接(如Debian和Ubuntu系统上所示),则攻击可以使用包含“-oProxyCommand”参数的IMAP服务器名称。解决建议
建议您更新当前系统或软件至最新版,完成漏洞的修复。受影响软件情况
# | 类型 | 厂商 | 产品 | 版本 | 影响面 | ||||
1 | |||||||||
---|---|---|---|---|---|---|---|---|---|
运行在以下环境 | |||||||||
应用 | php | php | * | From (including) 5.6.0 | Up to (including) 5.6.38 | ||||
运行在以下环境 | |||||||||
应用 | php | php | * | From (including) 7.0.0 | Up to (including) 7.0.32 | ||||
运行在以下环境 | |||||||||
应用 | php | php | * | From (including) 7.1.0 | Up to (including) 7.1.24 | ||||
运行在以下环境 | |||||||||
应用 | php | php | * | From (including) 7.2.0 | Up to (including) 7.2.12 | ||||
运行在以下环境 | |||||||||
应用 | uw-imap_project | uw-imap | 2007f | - | |||||
运行在以下环境 | |||||||||
系统 | alpine_3.7 | php7 | * | Up to (excluding) 7.1.29-r0 | |||||
运行在以下环境 | |||||||||
系统 | amazon_AMI | php56 | * | Up to (excluding) 7.1.25-1.35.amzn1 | |||||
运行在以下环境 | |||||||||
系统 | debian_10 | php7.3 | * | Up to (excluding) 7.3.0-1 | |||||
运行在以下环境 | |||||||||
系统 | debian_11 | uw-imap | * | Up to (excluding) 8:2007f~dfsg-6 | |||||
运行在以下环境 | |||||||||
系统 | debian_12 | uw-imap | * | Up to (excluding) 8:2007f~dfsg-6 | |||||
运行在以下环境 | |||||||||
系统 | debian_sid | uw-imap | * | Up to (excluding) 8:2007f~dfsg-6 | |||||
运行在以下环境 | |||||||||
系统 | fedora_28 | php-common | * | Up to (excluding) 7.2.13-2.fc28 | |||||
运行在以下环境 | |||||||||
系统 | fedora_29 | php-common | * | Up to (excluding) 7.2.13-2.fc29 | |||||
运行在以下环境 | |||||||||
系统 | opensuse_Leap_42.3 | php7-zip | * | Up to (excluding) 5.5.14-109.1 | |||||
运行在以下环境 | |||||||||
系统 | suse_11_SP4 | php53-odbc | * | Up to (excluding) 5.3.17-112.45.1 | |||||
运行在以下环境 | |||||||||
系统 | suse_12 | apache2-mod_php5 | * | Up to (excluding) 5.5.14-109.45 | |||||
运行在以下环境 | |||||||||
系统 | ubuntu_14.04 | php-imap | * | Up to (excluding) 5.4.6-0ubuntu5.1 | |||||
运行在以下环境 | |||||||||
系统 | ubuntu_14.04.6_lts | php-imap | * | Up to (excluding) 5.4.6-0ubuntu5.1 | |||||
运行在以下环境 | |||||||||
系统 | ubuntu_16.04 | uw-imap | * | Up to (excluding) 7.0.33-0ubuntu0.16.04.1 | |||||
运行在以下环境 | |||||||||
系统 | ubuntu_16.04.7_lts | php7.0 | * | Up to (excluding) 7.0.33-0ubuntu0.16.04.1 | |||||
运行在以下环境 | |||||||||
系统 | ubuntu_18.04 | uw-imap | * | Up to (excluding) 8:2007f~dfsg-5ubuntu0.18.04.2 | |||||
运行在以下环境 | |||||||||
系统 | ubuntu_18.04.5_lts | php7.2 | * | Up to (excluding) 7.2.15-0ubuntu0.18.04.1 | |||||
运行在以下环境 | |||||||||
系统 | ubuntu_18.10 | php7.2 | * | Up to (excluding) 7.2.15-0ubuntu0.18.20.1 | |||||
- 攻击路径 远程
- 攻击复杂度 容易
- 权限要求 无需权限
- 影响范围 全局影响
- EXP成熟度 漏洞武器化
- 补丁情况 官方补丁
- 数据保密性 N/A
- 数据完整性 传输被破坏
- 服务器危害 服务器失陷
- 全网数量 N/A
CWE-ID | 漏洞类型 |
CWE-88 | 参数注入或修改 |
Exp相关链接
- https://github.com/ensimag-security/CVE-2018-19518
- https://github.com/vulhub/vulhub/tree/master/php/CVE-2018-19518
- https://gitlab.com/ensimag-security/CVE-2018-19518
- https://raw.githubusercontent.com/rapid7/metasploit-framework/master/modules/exploits/linux/http/php_imap_open_rce.rb
- https://www.exploit-db.com/exploits/45914

版权声明
本站原创文章转载请注明文章出处及链接,谢谢合作!
评论