List of usage examples for javax.xml.crypto URIReferenceException getCause
public Throwable getCause()
From source file:at.gv.egiz.bku.slcommands.impl.CreateXMLSignatureCommandImpl.java
/** * Signs the signature./*ww w. j a v a2 s . c o m*/ * @param commandContext TODO * * @throws SLCommandException * if signing the signature fails * @throws SLViewerException */ private void signXMLSignature(SLCommandContext commandContext) throws SLCommandException, SLViewerException { try { signature.sign(commandContext.getSTAL(), keyboxIdentifier); } catch (MarshalException e) { log.error("Failed to marshall XMLSignature.", e); throw new SLCommandException(4000); } catch (XMLSignatureException e) { if (e.getCause() instanceof URIReferenceException) { URIReferenceException uriReferenceException = (URIReferenceException) e.getCause(); if (uriReferenceException.getCause() instanceof SLCommandException) { throw (SLCommandException) uriReferenceException.getCause(); } } log.error("Failed to sign XMLSignature.", e); throw new SLCommandException(4000); } }