mirror of
https://github.com/sqlmapproject/sqlmap.git
synced 2024-11-22 17:46:37 +03:00
Minor bug fix to parse also MSSQL 2008 R2 signatures
This commit is contained in:
parent
b8e2d60bfa
commit
50f4c4af52
|
@ -47,7 +47,7 @@ def updateMSSQLXML():
|
||||||
|
|
||||||
return
|
return
|
||||||
|
|
||||||
releases = re.findall("class=\"BCC_DV_01DarkBlueTitle\">SQL Server ([\d\.]+) Builds", mssqlVersionsHtmlString, re.I | re.M)
|
releases = re.findall("class=\"BCC_DV_01DarkBlueTitle\">SQL Server\s(.+?)\sBuilds", mssqlVersionsHtmlString, re.I | re.M)
|
||||||
releasesCount = len(releases)
|
releasesCount = len(releases)
|
||||||
|
|
||||||
# Create the minidom document
|
# Create the minidom document
|
||||||
|
@ -78,7 +78,7 @@ def updateMSSQLXML():
|
||||||
stopIdx = mssqlVersionsHtmlString.index("SQL Server %s Builds" % releases[index + 1])
|
stopIdx = mssqlVersionsHtmlString.index("SQL Server %s Builds" % releases[index + 1])
|
||||||
|
|
||||||
mssqlVersionsReleaseString = mssqlVersionsHtmlString[startIdx:stopIdx]
|
mssqlVersionsReleaseString = mssqlVersionsHtmlString[startIdx:stopIdx]
|
||||||
servicepackVersion = re.findall("</td><td>[7\.0|2000|2005|2008]*(.*?)</td><td.*?([\d\.]+)</td>[\r]*\n", mssqlVersionsReleaseString, re.I | re.M)
|
servicepackVersion = re.findall("</td><td>[7\.0|2000|2005|2008|2008 R2]*(.*?)</td><td.*?([\d\.]+)</td>[\r]*\n", mssqlVersionsReleaseString, re.I | re.M)
|
||||||
|
|
||||||
for servicePack, version in servicepackVersion:
|
for servicePack, version in servicepackVersion:
|
||||||
if servicePack.startswith(" "):
|
if servicePack.startswith(" "):
|
||||||
|
@ -97,6 +97,7 @@ def updateMSSQLXML():
|
||||||
servicePack = servicePack.replace("\t", " ")
|
servicePack = servicePack.replace("\t", " ")
|
||||||
servicePack = servicePack.replace("No SP", "0")
|
servicePack = servicePack.replace("No SP", "0")
|
||||||
servicePack = servicePack.replace("RTM", "0")
|
servicePack = servicePack.replace("RTM", "0")
|
||||||
|
servicePack = servicePack.replace("TM", "0")
|
||||||
servicePack = servicePack.replace("SP", "")
|
servicePack = servicePack.replace("SP", "")
|
||||||
servicePack = servicePack.replace("Service Pack", "")
|
servicePack = servicePack.replace("Service Pack", "")
|
||||||
servicePack = servicePack.replace("<a href=\"http:", "")
|
servicePack = servicePack.replace("<a href=\"http:", "")
|
||||||
|
|
Loading…
Reference in New Issue
Block a user