Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit bdd819d

Browse files
committed
Improvement of a between.py tamper script
1 parent 605d73c commit bdd819d

1 file changed

Lines changed: 3 additions & 1 deletion

File tree

tamper/between.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,8 @@
55
See the file 'doc/COPYING' for copying permission
66
"""
77

8+
import re
9+
810
from lib.core.enums import PRIORITY
911

1012
__priority__ = PRIORITY.HIGHEST
@@ -54,7 +56,7 @@ def tamper(payload, headers=None):
5456

5557
elif payload[i] == ">" and not doublequote and not quote:
5658
retVal += " " if i > 0 and not payload[i-1].isspace() else ""
57-
retVal += "NOT BETWEEN 0 AND"
59+
retVal += "NOT BETWEEN %s AND" % ('0' if re.search(r"\A[^\w]*\d", payload[i+1:]) else "NULL")
5860
retVal += " " if i < len(payload) - 1 and not payload[i+1:i+2].isspace() else ""
5961

6062
continue

0 commit comments

Comments
 (0)