We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 37547a8 + e605fc7 commit 8a99308Copy full SHA for 8a99308
lib/xml_security.rb
@@ -94,7 +94,7 @@ def validate_doc(base64_cert, soft = true)
94
95
hashed_element = document.at_xpath("//*[@ID='#{uri[1..-1]}']")
96
canon_algorithm = canon_algorithm REXML::XPath.first(ref, '//ds:CanonicalizationMethod', 'ds' => DSIG)
97
- canon_hashed_element = hashed_element.canonicalize(canon_algorithm, inclusive_namespaces).gsub('&','&')
+ canon_hashed_element = hashed_element.canonicalize(canon_algorithm, inclusive_namespaces).gsub(/&(?!amp;)/,'&')
98
99
digest_algorithm = algorithm(REXML::XPath.first(ref, "//ds:DigestMethod"))
100
0 commit comments