Espcms V5.6.13.04.22 official UTF8 injection vulnerability 1/N

Source: Internet
Author: User

Espcms V5.6.13.04.22 an injection vulnerability exists in an official UTF8 file, allowing you to obtain the Administrator account and password.
 
Vulnerability file: \ interface \ membermain. php

$ Zipcode = trim ($ this-> fun-> accept ('zipcode', 'P', true, true )); // row 185th $ zipcode = empty ($ zipcode )? 0: $ zipcode ;...... $ db_where = "userid = $ this-> ec_member_username_id AND username = '$ this-> ec_member_username'"; $ db_set = "sex = $ sex, birthday = $ birthday, country = $ country, province = $ province, city = $ city, district = $ district, alias = '$ alias', address =' $ address', zipcode = $ zipcode, tel = '$ tel', mobile =' $ mobile', qq = $ qq, msn = '$ msn' "; $ this-> db-> query ('update '. $ db_table. 'set '. $ db_set. 'where '. $ db_where );


$ Zipcode variables are not included in single quotes, resulting in an SQL injection vulnerability.

In the update statement, in addition to getting the Administrator account password through injection, you can also modify the information of any member, including the password.



The entered SQL statement is as follows:

Die ('update'. $ db_table. 'set'. $ db_set. 'where'. $ db_where)




 

Update the administrator password to the email information.




Solution:

Put variables in single quotes

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.