}
XKMSCAServiceRequest cAReq = new XKMSCAServiceRequest(result, id,true,false);
XKMSCAServiceResponse resp = (XKMSCAServiceResponse) caAdminSession.extendedService(admin, XKMSConfig.cAIdUsedForSigning(admin, caAdminSession), cAReq);
retval = resp.getSignedDocument();
if (log.isDebugEnabled()) {
// Output what we just processed..
ByteArrayOutputStream baos = new ByteArrayOutputStream();
XMLUtils.outputDOMc14nWithComments(retval, baos);
log.debug("(Signed) signResponseIfNeeded XMLUtils.outputDOMc14nWithComments: " + baos.toString());