summaryrefslogtreecommitdiffstats
path: root/module
diff options
context:
space:
mode:
authorGravatar Nitzo <nitzo2001@yahoo.com> 2016-02-28 02:33:31 +0100
committerGravatar Nitzo <nitzo2001@yahoo.com> 2016-02-28 02:33:31 +0100
commit891c684b09654c7f80079eef0938e212c9265c98 (patch)
tree9a7d3ff07a6bd887a5e9d2bb04ca70e32314f3d7 /module
parent[ReCaptcha] fix #2364 (diff)
downloadpyload-891c684b09654c7f80079eef0938e212c9265c98.tar.xz
[misc] parse_html_form(): ignore comments
Diffstat (limited to 'module')
-rw-r--r--module/plugins/internal/misc.py5
1 files changed, 3 insertions, 2 deletions
diff --git a/module/plugins/internal/misc.py b/module/plugins/internal/misc.py
index d49896233..bcd9e2d9b 100644
--- a/module/plugins/internal/misc.py
+++ b/module/plugins/internal/misc.py
@@ -38,7 +38,7 @@ except ImportError:
class misc(object):
__name__ = "misc"
__type__ = "plugin"
- __version__ = "0.27"
+ __version__ = "0.28"
__status__ = "stable"
__pattern__ = r'^unmatchable$'
@@ -752,7 +752,8 @@ def parse_html_form(attr_str, html, input_names={}):
inputs = {}
action = parse_html_tag_attr_value("action", form.group('TAG'))
- for inputtag in re.finditer(r'(<(input|textarea).*?>)([^<]*(?=</\2)|)', form.group('CONTENT'), re.I | re.S):
+ for inputtag in re.finditer(r'(<(input|textarea).*?>)([^<]*(?=</\2)|)',
+ re.sub(r'<!--.+-->', "", form.group('CONTENT'), 0 , re.I | re.S), re.I | re.S):
name = parse_html_tag_attr_value("name", inputtag.group(1))
if name:
value = parse_html_tag_attr_value("value", inputtag.group(1))