2626from lib .core .enums import PAYLOAD
2727from lib .core .enums import PLACE
2828from lib .core .exception import sqlmapNoneDataException
29- from lib .core .settings import FROM_TABLE
29+ from lib .core .settings import FROM_DUMMY_TABLE
3030from lib .core .settings import PAYLOAD_DELIMITER
3131from lib .core .settings import URI_INJECTION_MARK_CHAR
3232from lib .core .unescaper import unescaper
@@ -559,7 +559,7 @@ def forgeInbandQuery(self, query, position, count, comment, prefix, suffix, char
559559
560560 if limited :
561561 inbandQuery += "," .join (char if _ != position else '(SELECT %s)' % query for _ in xrange (0 , count ))
562- inbandQuery += FROM_TABLE .get (Backend .getIdentifiedDbms (), "" )
562+ inbandQuery += FROM_DUMMY_TABLE .get (Backend .getIdentifiedDbms (), "" )
563563 inbandQuery = self .suffixQuery (inbandQuery , comment , suffix )
564564
565565 return inbandQuery
@@ -576,8 +576,8 @@ def forgeInbandQuery(self, query, position, count, comment, prefix, suffix, char
576576 intoRegExp = intoRegExp .group (1 )
577577 query = query [:query .index (intoRegExp )]
578578
579- if Backend .getIdentifiedDbms () in FROM_TABLE and inbandQuery .endswith (FROM_TABLE [Backend .getIdentifiedDbms ()]):
580- inbandQuery = inbandQuery [:- len (FROM_TABLE [Backend .getIdentifiedDbms ()])]
579+ if Backend .getIdentifiedDbms () in FROM_DUMMY_TABLE and inbandQuery .endswith (FROM_TABLE [Backend .getIdentifiedDbms ()]):
580+ inbandQuery = inbandQuery [:- len (FROM_DUMMY_TABLE [Backend .getIdentifiedDbms ()])]
581581
582582 for element in xrange (0 , count ):
583583 if element > 0 :
@@ -596,9 +596,9 @@ def forgeInbandQuery(self, query, position, count, comment, prefix, suffix, char
596596 conditionIndex = query .index (" FROM " )
597597 inbandQuery += query [conditionIndex :]
598598
599- if Backend .getIdentifiedDbms () in FROM_TABLE :
599+ if Backend .getIdentifiedDbms () in FROM_DUMMY_TABLE :
600600 if " FROM " not in inbandQuery or "(CASE " in inbandQuery or "(IIF" in inbandQuery :
601- inbandQuery += FROM_TABLE [Backend .getIdentifiedDbms ()]
601+ inbandQuery += FROM_DUMMY_TABLE [Backend .getIdentifiedDbms ()]
602602
603603 if intoRegExp :
604604 inbandQuery += intoRegExp
@@ -615,8 +615,8 @@ def forgeInbandQuery(self, query, position, count, comment, prefix, suffix, char
615615 else :
616616 inbandQuery += char
617617
618- if Backend .getIdentifiedDbms () in FROM_TABLE :
619- inbandQuery += FROM_TABLE [Backend .getIdentifiedDbms ()]
618+ if Backend .getIdentifiedDbms () in FROM_DUMMY_TABLE :
619+ inbandQuery += FROM_DUMMY_TABLE [Backend .getIdentifiedDbms ()]
620620
621621 inbandQuery = self .suffixQuery (inbandQuery , comment , suffix )
622622
@@ -747,8 +747,8 @@ def forgeCaseStatement(self, expression):
747747 if Backend .getIdentifiedDbms () is not None and hasattr (queries [Backend .getIdentifiedDbms ()], "case" ):
748748 caseExpression = queries [Backend .getIdentifiedDbms ()].case .query % expression
749749
750- if "(IIF" not in caseExpression and Backend .getIdentifiedDbms () in FROM_TABLE and not caseExpression .upper ().endswith (FROM_TABLE [Backend .getIdentifiedDbms ()]):
751- caseExpression += FROM_TABLE [Backend .getIdentifiedDbms ()]
750+ if "(IIF" not in caseExpression and Backend .getIdentifiedDbms () in FROM_DUMMY_TABLE and not caseExpression .upper ().endswith (FROM_TABLE [Backend .getIdentifiedDbms ()]):
751+ caseExpression += FROM_DUMMY_TABLE [Backend .getIdentifiedDbms ()]
752752
753753 return caseExpression
754754
0 commit comments