Skip to content

Commit

Permalink
Merge branch 'master' of github.com:sqlmapproject/sqlmap
Browse files Browse the repository at this point in the history
  • Loading branch information
bdamele committed Mar 3, 2015
2 parents 37ca0a9 + 3347fc2 commit e13bbe2
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
4 changes: 3 additions & 1 deletion lib/request/connect.py
Original file line number Diff line number Diff line change
Expand Up @@ -332,7 +332,9 @@ def getPage(**kwargs):
if HTTP_HEADER.ACCEPT not in headers:
headers[HTTP_HEADER.ACCEPT] = HTTP_ACCEPT_HEADER_VALUE

headers[HTTP_HEADER.ACCEPT_ENCODING] = HTTP_ACCEPT_ENCODING_HEADER_VALUE if kb.pageCompress else "identity"
if HTTP_HEADER.ACCEPT_ENCODING not in headers:
headers[HTTP_HEADER.ACCEPT_ENCODING] = HTTP_ACCEPT_ENCODING_HEADER_VALUE if kb.pageCompress else "identity"

headers[HTTP_HEADER.HOST] = host or getHostHeader(url)

if post is not None and HTTP_HEADER.CONTENT_TYPE not in headers:
Expand Down
3 changes: 2 additions & 1 deletion lib/request/httpshandler.py
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,8 @@ def create_sock():
break
else:
sock.close()
except (ssl.SSLError, socket.error), errMsg:
except (ssl.SSLError, socket.error, httplib.BadStatusLine), errMsg:
self._tunnel_host = None
logger.debug("SSL connection error occurred ('%s')" % errMsg)

if not success:
Expand Down

0 comments on commit e13bbe2

Please sign in to comment.