Michele Bortolato
Michele Bortolato

Reputation: 787

Multiple XADES signature / get original document

I want to ask if exsist a way in xades4j to made multiple signature.

For multiple signature i mean not countersignature, but a double independent sign to the same document, the resulting signature will have 2 or more signature object. In pratice a signer can take a xml signed document as input and resign it.

In other way i need a method to take as input a xml signed file and get as output the original xml document.

Thanks,

Michele

Upvotes: 1

Views: 1541

Answers (1)

lgoncalves
lgoncalves

Reputation: 2090

The "multiple signature" you've described seems to be specific of your use-case. As a library XAdES4j doesn't have that out of the box, but won't stop you from doing it. You just need to compose the references on each signature in the appropriate way and use a signer twice (probably you don't want to apply the second signature over the first one).

Likewise, there's no method to obtain the "original xml document", because the signed resources maybe even be other than xml. That's something that likely belongs to your application logic.

Upvotes: 2

Related Questions