mirror of
https://github.com/sqlmapproject/sqlmap.git
synced 2025-04-29 05:13:47 +03:00
Merge branch 'master' of github.com:sqlmapproject/sqlmap
This commit is contained in:
commit
f52d81c834
|
@ -245,7 +245,7 @@ def decodePage(page, contentEncoding, contentType):
|
||||||
# e.g. ’…™
|
# e.g. ’…™
|
||||||
if "&#" in page:
|
if "&#" in page:
|
||||||
page = re.sub('&#(\d+);', lambda _: unichr(int(_.group(1))), page)
|
page = re.sub('&#(\d+);', lambda _: unichr(int(_.group(1))), page)
|
||||||
|
|
||||||
# e.g. ζ
|
# e.g. ζ
|
||||||
page = re.sub('&([^;]+);', lambda _: unichr(htmlEntities[_.group(1)]) if htmlEntities.get(_.group(1), 0) > 255 else _.group(0), page)
|
page = re.sub('&([^;]+);', lambda _: unichr(htmlEntities[_.group(1)]) if htmlEntities.get(_.group(1), 0) > 255 else _.group(0), page)
|
||||||
|
|
||||||
|
|
|
@ -5,7 +5,7 @@ Copyright (c) 2006-2012 sqlmap developers (http://sqlmap.org/)
|
||||||
See the file 'doc/COPYING' for copying permission
|
See the file 'doc/COPYING' for copying permission
|
||||||
"""
|
"""
|
||||||
|
|
||||||
import argparse
|
import optparse
|
||||||
import os
|
import os
|
||||||
import sys
|
import sys
|
||||||
import threading
|
import threading
|
||||||
|
@ -210,12 +210,12 @@ if __name__ == "__main__":
|
||||||
Standalone REST-JSON API wrapper function
|
Standalone REST-JSON API wrapper function
|
||||||
"""
|
"""
|
||||||
|
|
||||||
parser = argparse.ArgumentParser()
|
parser = optparse.OptionParser()
|
||||||
parser.add_argument("-s", "--server", help="Act as a REST-JSON API server", default=RESTAPI_SERVER_PORT, action="store_true", required=False)
|
parser.add_option("-s", "--server", help="Act as a REST-JSON API server", default=RESTAPI_SERVER_PORT, action="store_true")
|
||||||
parser.add_argument("-c", "--client", help="Act as a REST-JSON API client", default=RESTAPI_SERVER_PORT, action="store_true", required=False)
|
parser.add_option("-c", "--client", help="Act as a REST-JSON API client", default=RESTAPI_SERVER_PORT, action="store_true")
|
||||||
parser.add_argument("-H", "--host", help="Host of the REST-JSON API server", default="0.0.0.0", action="store", required=False)
|
parser.add_option("-H", "--host", help="Host of the REST-JSON API server", default="0.0.0.0", action="store")
|
||||||
parser.add_argument("-p", "--port", help="Port of the the REST-JSON API server", default=RESTAPI_SERVER_PORT, action="store", required=False)
|
parser.add_option("-p", "--port", help="Port of the the REST-JSON API server", default=RESTAPI_SERVER_PORT, action="store")
|
||||||
args = parser.parse_args()
|
(args, _) = parser.parse_args()
|
||||||
|
|
||||||
if args.server is True:
|
if args.server is True:
|
||||||
restAPIrun(args.host, args.port)
|
restAPIrun(args.host, args.port)
|
||||||
|
|
|
@ -83,7 +83,7 @@ def tamper(payload, **kwargs):
|
||||||
retVal += random.choice(blanks)
|
retVal += random.choice(blanks)
|
||||||
|
|
||||||
continue
|
continue
|
||||||
|
|
||||||
retVal += payload[i]
|
retVal += payload[i]
|
||||||
|
|
||||||
return retVal
|
return retVal
|
||||||
|
|
Loading…
Reference in New Issue
Block a user