Skip to Content.
Sympa Menu

mace-opensaml-users - RE: How to tranport Errors

Subject: OpenSAML user discussion

List archive

RE: How to tranport Errors


Chronological Thread 
  • From: Scott Cantor <>
  • To: ,
  • Subject: RE: How to tranport Errors
  • Date: Mon, 26 Jan 2004 17:07:56 -0500
  • Importance: Normal
  • Organization: The Ohio State University

> I've read the SAML Standard several times also the OpenSaml
> Javadocs, but I still don't know how to transport an error
> like "Service not available (in cause of maintanace)" or
> something like "unknown Subject" in an attribute query.

Physically in the XML, you have to use a substatus code and/or a message.

> I don't know if I should throw a Saml Exeption, or pass an
> SAMLExeption Object to the SAMLRespond method.
> Have I to tranport via soap:fault or via the StatusCode,
> Message, ... Elements.

Kind of a mess, I know. Depends on the context, but generally tossing an
exception will not help you. You're on the hook to catch it and do something
with it.

If you want to return the error after a SOAP request, you can pass a
SAMLException to the SAMLResponse constructor and it will return that
exception as the serialization of the Status element in the response.

Don't use a Fault unless it's a SOAP problem. If you do want to use a fault,
you can pass a SOAPException to the SAMLResponse and it will detect that.

-- Scott




Archive powered by MHonArc 2.6.16.

Top of Page