Skip to content

Commit

Permalink
Merge PR #4417 from @ThureinOo - Update SQL injections
Browse files Browse the repository at this point in the history
update: Added some bypass methods used by SQLI Injectors.

---------

Co-authored-by: Nasreddine Bencherchali <8741929+nasbench@users.noreply.github.com>
  • Loading branch information
ThureinOo and nasbench authored Sep 6, 2023
1 parent efe2c9b commit 1e7a5b0
Showing 1 changed file with 28 additions and 29 deletions.
57 changes: 28 additions & 29 deletions rules/web/webserver_generic/web_sql_injection_in_access_logs.yml
Original file line number Diff line number Diff line change
@@ -1,59 +1,58 @@
title: SQL Injection Strings
title: SQL Injection Strings In URI
id: 5513deaf-f49a-46c2-a6c8-3f111b5cb453
status: test
description: Detects SQL Injection attempts via GET requests in access logs
description: Detects potential SQL injection attempts via GET requests in access logs.
references:
- https://www.acunetix.com/blog/articles/exploiting-sql-injection-example/
- https://www.acunetix.com/blog/articles/using-logs-to-investigate-a-web-application-attack/
- https://brightsec.com/blog/sql-injection-payloads/
- https://github.com/payloadbox/sql-injection-payload-list
author: Saw Win Naung, Nasreddine Bencherchali (Nextron Systems)
- https://book.hacktricks.xyz/pentesting-web/sql-injection/mysql-injection
author: Saw Win Naung, Nasreddine Bencherchali (Nextron Systems), Thurein Oo (Yoma Bank)
date: 2020/02/22
modified: 2023/09/01
modified: 2023/09/04
tags:
- attack.initial_access
- attack.t1190
logsource:
category: webserver
detection:
select_method:
selection:
cs-method: 'GET'
keywords:
- '@@version'
- '%271%27%3D%271'
- '=select '
- '=select%20'
- '=select('
- 'UNION SELECT'
- 'UNION%20SELECT'
- 'UNION ALL SELECT'
- 'UNION%20ALL%20SELECT'
- '=select%20'
- 'concat_ws('
- 'CONCAT(0x'
- 'order by '
- 'order%20by%20'
- 'information_schema.tables'
- 'from mysql.innodb_table_stats'
- 'from%20mysql.innodb_table_stats'
- 'group_concat('
- 'table_schema'
- 'select%28sleep%2810%29'
- '@@version'
- "'1'='1"
- '%271%27%3D%271'
- 'SELECTCHAR('
- 'select * '
- 'select%20*%20'
- 'information_schema.tables'
- 'json_arrayagg('
- 'or 1=1#'
- 'or%201=1#'
- 'concat_ws('
- 'order by '
- 'order%20by%20'
- 'select * '
- 'select database()'
- 'select version()'
- 'select%20*%20'
- 'select%20database()'
- 'select%20version()'
filter:
- 'select%28sleep%2810%29'
- 'SELECTCHAR('
- 'table_schema'
- 'UNION ALL SELECT'
- 'UNION SELECT'
- 'UNION%20ALL%20SELECT'
- 'UNION%20SELECT'
- "'1'='1"
filter_main_status:
sc-status: 404
condition: select_method and keywords and not 1 of filter*
fields:
- client_ip
- vhost
- url
- response
condition: selection and keywords and not 1 of filter_main_*
falsepositives:
- Java scripts and CSS Files
- User searches in search boxes of the respective website
Expand Down

0 comments on commit 1e7a5b0

Please sign in to comment.