Patch for known NCHAR/UNION-query SQLi problems

This commit is contained in:
Miroslav Stampar
2020-12-01 12:16:15 +01:00
parent c6557e2b45
commit 78ba33737e
4 changed files with 13 additions and 1 deletions

View File

@@ -499,6 +499,9 @@ class Agent(object):
if suffix:
nulledCastedField += suffix
if not kb.nchar:
nulledCastedField = re.sub(r"( AS )N(CHAR|VARCHAR)", r"\g<1>\g<2>", nulledCastedField)
return nulledCastedField
def nullCastConcatFields(self, fields):