Skip to Content.
Sympa Menu

mace-opensaml-users - Re: [OpenSAML] xsi:type in AttributeValue

Subject: OpenSAML user discussion

List archive

Re: [OpenSAML] xsi:type in AttributeValue


Chronological Thread 
  • From: Brent Putman <>
  • To:
  • Subject: Re: [OpenSAML] xsi:type in AttributeValue
  • Date: Fri, 23 May 2008 16:25:11 -0400

Yes, it does support this. Looks like the problem here is simply that the xmltooling provider config file (schema-config.xml) does not have the providers registered for the xs:anyURI type QName. BTW, It's also missing for xs:boolean. Please file a bug to track this and we can easily add.

You can workaround in the interim by registering the builder/marshaller/unmarshaller for that type manually (either programatically or declaratively with a new config file). You want the XSURI* classes in org.opensaml.xml.schema.impl package in xmltooling.

HTH,
Brent


Kenny Pearce wrote:
Hi,
I'm trying to use typed AttributeValues as suggested by saml-core
sect.
2.7.3.1.1, but as far as I can tell OpenSAML is ignoring my xsi:type
element.
Here is the XML element in question I'm trying to unmarshall:

<saml:AttributeValue xmlns:xs="http://www.w3.org/2001/XMLSchema";
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";
xsi:type="xs:anyURI">urn:hxti:roles:hxti:super-user</saml:AttributeValue>

I get the following in the logger:

2008-05-23 15:27:03.217 TRACE - Unmarshalling other child nodes of DOM
Element {urn:oasis:names:tc:SAML:2.0:assertion}Attribute
2008-05-23 15:27:03.217 TRACE - Unmarshalling child elements of
XMLObject {urn:oasis:names:tc:SAML:2.0:assertion}Attribute
2008-05-23 15:27:03.217 TRACE - No unmarshaller was registered for
{urn:oasis:names:tc:SAML:2.0:assertion}AttributeValue, child of
{urn:oasis:names:tc:SAML:2.0:assertion}Attribute. Using default
unmarshaller.
2008-05-23 15:27:03.217 TRACE - Unmarshalling child element
{urn:oasis:names:tc:SAML:2.0:assertion}AttributeValuewith unmarshaller
org.opensaml.xml.schema.impl.XSAnyUnmarshaller
2008-05-23 15:27:03.217 TRACE - Starting to unmarshall DOM element
{urn:oasis:names:tc:SAML:2.0:assertion}AttributeValue
2008-05-23 15:27:03.217 TRACE - Targeted QName checking is not available
for this unmarshaller, DOM Element
{urn:oasis:names:tc:SAML:2.0:assertion}AttributeValue was not verified
2008-05-23 15:27:03.217 TRACE - Building XMLObject for
{urn:oasis:names:tc:SAML:2.0:assertion}AttributeValue
2008-05-23 15:27:03.217 TRACE - No builder was registered for
{urn:oasis:names:tc:SAML:2.0:assertion}AttributeValue but the default
builder org.opensaml.xml.schema.impl.XSAnyBuilder was available, using
it.
2008-05-23 15:27:03.217 TRACE - Unmarshalling attributes of DOM Element
{urn:oasis:names:tc:SAML:2.0:assertion}AttributeValue
2008-05-23 15:27:03.217 TRACE - Pre-processing attribute
{http://www.w3.org/2001/XMLSchema-instance}type
2008-05-23 15:27:03.217 TRACE - Unmarshalling other child nodes of DOM
Element {urn:oasis:names:tc:SAML:2.0:assertion}AttributeValue
2008-05-23 15:27:03.217 TRACE - Releasing cached DOM reprsentation for
parent of {urn:oasis:names:tc:SAML:2.0:assertion}AttributeValue with
propagation set to true


Does OpenSAML support the use of xsi:type here? If yes, what am I doing
wrong?

Thanks,




Archive powered by MHonArc 2.6.16.

Top of Page