Code development platform for open source projects from the European Union institutions :large_blue_circle: EU Login authentication by SMS has been phased out. To see alternatives please check here

Skip to content
Snippets Groups Projects
Commit 25ee6b47 authored by Stefanos Doumpoulakis's avatar Stefanos Doumpoulakis
Browse files

fix: check if XML element is signed (#950)

parent 95b4a962
Branches
No related tags found
No related merge requests found
......@@ -434,12 +434,7 @@ namespace TUGraz.VectoHashing
throw new Exception("Invalid structure of input XML!");
}
if (nodes[index].Attributes[XMLNames.Component_ID_Attr] == null) {
return false;
}
var elementToHash = nodes[index].Attributes[XMLNames.Component_ID_Attr].Value;
var nodesDV = parent.SelectNodes(".//*[@URI='#" + elementToHash + "']/*[local-name() = 'DigestValue']");
var nodesDV = parent.SelectNodes("./*[local-name()='Signature']");
return (nodesDV != null && nodesDV.Count > 0);
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment