throw new Exception("Couldn't find signature Element");
}
Element sigElement = (Element) nl.item(0);
XMLSignature signature = new XMLSignature
(sigElement, file.toURI().toString());
SecretKey sk = signature.createSecretKey("secret".getBytes("ASCII"));
System.out.println
("Validation status: " + signature.checkSignatureValue(sk));
}
public void test_generate_hmac_sha1_40() throws Exception {