Create the XMLSecurityDSig object that verifies a signature.
Digests and signatures are computed over canonicalized XML. If the
canonicalization fails, DOMNode::C14N() returns FALSE (on PHP 8, some
XPath failures throw an Error instead), and an XPath transform that
selects nothing yields an empty string. Depending on its version,
xmlseclibs then hashes an empty string: a forged reference only has to
carry the digest of the empty string to validate, whatever the content
of the referenced node. The returned object therefore makes the
canonicalization of the node "ds:SignedInfo" and of each referenced node
throw an exception unless it produces a non-empty string.
This check is deliberately independent of the xmlseclibs version and
must not be removed, even if xmlseclibs performs a similar check.