How to sign Timestamp

Brent Putman putmanb at georgetown.edu
Tue Oct 30 17:36:11 EDT 2018



On 10/30/18 1:41 PM, Binh Pham wrote:
> Thank you so much for helping thus far. I still have some more questions.
>
> I would add the timestamp id to DocumentInternalIDContentReference
> like so:
>
> DocumentInternalIDContentReference reference = new
> DocumentInternalIDContentReference(timestamp.getWSUId());
> reference.getTransforms().add(SignatureConstants.TRANSFORM_C14N_EXCL_OMIT_COMMENTS);
> reference.setDigestAlgorithm(SignatureConstants.ALGO_ID_DIGEST_SHA1);
> Signature signature = getSignature(credential);
> signature.getContentReferences().add(reference);

Offhand, structurally speaking that looks correct to me.

>
> Then call Signer.signObject(signature);?
>

Yes.  Other than manually creating and adding the ContentReference,
everything else should be conceptually the same as other XML
signatures, such as the enveloped signature on Assertion.

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://shibboleth.net/pipermail/dev/attachments/20181030/6cadce17/attachment.html>


More information about the dev mailing list