@@ -179,7 +179,6 @@ def checkSqlInjection(place, parameter, value):
179179 logger .debug (debugMsg )
180180 continue
181181
182-
183182 # Skip DBMS-specific test if it does not match either the
184183 # previously identified or the user's provided DBMS (either
185184 # from program switch or from parsed error message(s))
@@ -250,11 +249,11 @@ def checkSqlInjection(place, parameter, value):
250249
251250 if clause != [0 ] and injection .clause and injection .clause != [0 ] and not clauseMatch :
252251 debugMsg = "skipping test '%s' because the clauses " % title
253- debugMsg += "differs from the clause already identified"
252+ debugMsg += "differ from the clause already identified"
254253 logger .debug (debugMsg )
255254 continue
256255
257- # Skip test if the user provided custom character
256+ # Skip test if the user provided custom character (for UNION-based payloads)
258257 if conf .uChar is not None and ("random number" in title or "(NULL)" in title ):
259258 debugMsg = "skipping test '%s' because the user " % title
260259 debugMsg += "provided a specific character, %s" % conf .uChar
@@ -314,22 +313,23 @@ def checkSqlInjection(place, parameter, value):
314313 # Parse boundary's <prefix>, <suffix> and <ptype>
315314 prefix = boundary .prefix if boundary .prefix else ""
316315 suffix = boundary .suffix if boundary .suffix else ""
316+ ptype = boundary .ptype
317317
318318 # Options --prefix/--suffix have a higher priority (if set by user)
319319 prefix = conf .prefix if conf .prefix is not None else prefix
320320 suffix = conf .suffix if conf .suffix is not None else suffix
321321 comment = None if conf .suffix is not None else comment
322322
323- ptype = boundary .ptype
324-
325323 # If the previous injections succeeded, we know which prefix,
326324 # suffix and parameter type to use for further tests, no
327325 # need to cycle through the boundaries for the following tests
328326 condBound = (injection .prefix is not None and injection .suffix is not None )
329327 condBound &= (injection .prefix != prefix or injection .suffix != suffix )
330328 condType = injection .ptype is not None and injection .ptype != ptype
331329
332- if condBound or condType :
330+ # If the payload is an inline query test for it regardless
331+ # of previously identified injection types
332+ if stype != PAYLOAD .TECHNIQUE .QUERY and (condBound or condType ):
333333 continue
334334
335335 # For each test's <where>
0 commit comments