From 9340bf59fb0bbfbe809d0825d4d7a33fd62e2e6d Mon Sep 17 00:00:00 2001 From: Bernardo Damele Date: Mon, 29 Dec 2008 18:46:43 +0000 Subject: [PATCH] Updated Microsoft SQL Server signature XML file. Minor layout adjustments to --update output messages/diff --- lib/core/update.py | 12 ++++-------- xml/banner/mssql.xml | 42 +++++++++++++++++++++++++++++++++++++++++- 2 files changed, 45 insertions(+), 9 deletions(-) diff --git a/lib/core/update.py b/lib/core/update.py index 4fcad8cc9..d187c1888 100644 --- a/lib/core/update.py +++ b/lib/core/update.py @@ -28,6 +28,7 @@ import difflib import os import re import shutil +import sys import tempfile import urlparse import zipfile @@ -188,13 +189,8 @@ def __updateMSSQLXML(): logger.info(infoMsg) # Compare the old XML file with the new one - differ = difflib.Differ() - differences = list(differ.compare(oldMssqlXmlList, newMssqlXmlList)) - - # Show only the different lines - for line in differences: - if line.startswith("-") or line.startswith("+") or line.startswith("?"): - print line.strip("\n") + diff = difflib.unified_diff(oldMssqlXmlList, newMssqlXmlList, "%s.bak" % paths.MSSQL_XML, paths.MSSQL_XML) + sys.stdout.writelines(diff) else: infoMsg = "no new Microsoft SQL Server versions since the " infoMsg += "last update" @@ -262,7 +258,7 @@ def __updateSqlmap(): logger.info(infoMsg) elif sqlmapNewestVersion < VERSION: - infoMsg = "if you are running a version of sqlmap more updated than " + infoMsg = "you are running a version of sqlmap more updated than " infoMsg += "the latest stable version (%s)" % sqlmapNewestVersion logger.info(infoMsg) diff --git a/xml/banner/mssql.xml b/xml/banner/mssql.xml index 0170109ef..c3c3984d8 100644 --- a/xml/banner/mssql.xml +++ b/xml/banner/mssql.xml @@ -6,7 +6,7 @@ 10.00.1750 - 0+Q956718 + +Q956718 @@ -43,6 +43,30 @@ + + + 9.00.4035 + + + +3 + + + + + 9.00.3301 + + + 2+Q958735 + + + + + 9.00.3295 + + + 2+Q959132 + + 9.00.3294 @@ -51,6 +75,14 @@ 2+Q956854 + + + 9.00.3291 + + + 2+Q956889 + + 9.00.3282 @@ -67,6 +99,14 @@ 2+Q954607 + + + 9.00.3261 + + + 2+Q955754 + + 9.00.3260