|
21 | 21 | from lib.core.data import kb |
22 | 22 | from lib.core.data import logger |
23 | 23 | from lib.core.exception import SqlmapNoneDataException |
| 24 | +from lib.core.exception import SqlmapSilentQuitException |
24 | 25 | from lib.core.settings import DEFAULT_PAGE_ENCODING |
| 26 | +from lib.core.settings import DEV_EMAIL_ADDRESS |
25 | 27 | from lib.core.settings import DIFF_TOLERANCE |
26 | 28 | from lib.core.settings import HTML_TITLE_REGEX |
27 | 29 | from lib.core.settings import LOWER_RATIO_BOUND |
|
35 | 37 | from thirdparty import six |
36 | 38 |
|
37 | 39 | def comparison(page, headers, code=None, getRatioValue=False, pageLength=None): |
38 | | - _ = _adjust(_comparison(page, headers, code, getRatioValue, pageLength), getRatioValue) |
39 | | - return _ |
| 40 | + try: |
| 41 | + _ = _adjust(_comparison(page, headers, code, getRatioValue, pageLength), getRatioValue) |
| 42 | + return _ |
| 43 | + except: |
| 44 | + warnMsg = "there was a KNOWN issue inside the internals regarding the difflib/comparison of pages. " |
| 45 | + warnMsg += "Please report details privately via e-mail to '%s'" % DEV_EMAIL_ADDRESS |
| 46 | + logger.critical(warnMsg) |
| 47 | + raise SqlmapSilentQuitException |
40 | 48 |
|
41 | 49 | def _adjust(condition, getRatioValue): |
42 | 50 | if not any((conf.string, conf.notString, conf.regexp, conf.code)): |
|
0 commit comments