Skip to content

Commit 33f8309

Browse files
authored
Merge pull request #41 from liquidpele/liquidpele-patch-1
Replace & with & in input for XML parser
2 parents 568be58 + 7a55ebf commit 33f8309

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

djangosaml2/utils.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ def get_location(http_info):
5151
def get_hidden_form_inputs(html):
5252
""" Extracts name/value pairs from hidden input tags in an html form."""
5353
pairs = dict()
54-
tree = ElementTree.fromstring(html, forbid_dtd=True)
54+
tree = ElementTree.fromstring(html.replace('&', '&'), forbid_dtd=True)
5555
# python 2.6 doesn't have iter
5656
if hasattr(tree, 'iter'):
5757
node_iter = tree.iter()

0 commit comments

Comments
 (0)