Write/Read opensaml Assertion to/from XML file

Brent Putman putmanb at georgetown.edu
Tue Jan 31 21:30:19 GMT 2012


Well, the helper method that Chad previously mentioned
XMLHelper.writeNode(Node, OutputStream) can just as easily serialize to
a file or anywhere else - just supply the appropriate OutputStream method.

Similarly with the reading in: our ParserPool can read from an
InputStream instance, so just supply one for a file input stream.

Both of those mechanisms will preserve the file such that signature
validation will still work after you write and read back in.


On 1/31/12 3:07 PM, José Luis Hernández Ramos wrote:
> Hi all and thanks in advance,
>  
> I have been looking for about the possibility of write and read an
> Assertion (in Java) but I have found only an example from shibboleth
> pages:
> https://wiki.shibboleth.net/confluence/display/OpenSAML/OSTwoUsrManJavaCreateFromXML
> and using the MetadataTest class. Is there any way in order to validate
> the signature in the assertion in a correct way after writing and
> reading the Assertion?
>  
> Thanks again.
>  
> Best regards,
> Jose.
> 
> 
> --
> To unsubscribe from this list send an email to dev-unsubscribe at shibboleth.net


More information about the dev mailing list