Empty Dependency

Martin Haase Martin.Haase at DAASI.de
Tue May 29 03:34:20 EDT 2018


Hi,

I am faced with an ERROR in the Velocity filter template of an LDAP
DataConnector. The connector looks like this:

    <DataConnector id="myLDAP2" ...>
        <Dependency ref="someAttributeXYZ" />
	<FilterTemplate>
            <![CDATA[
                (member=uid=$someAttributeXYZ.get(0),dc=some,dc=domain)
            ]]>
        </FilterTemplate>

The error the templating engine spits out approximately says that there
is no value for "someAttributeXYZ", so it cannot dereference its first
element (ArrayIndexOutOfBoundsException). This is IdP v3.3.x.

Now I am baffled: I was under the assumption that if an
attributeDefinition returns no value for an attribute, the dependent
attributeDefinitions or dataConnectors would not fire in the first
place. Obviously this does not seem to be the case.

I now do have a workaround that checks on $someAttributeXYZ.size() using
a Velocity #if, but it is ugly because there needs to be some bogus
filter string in the #else branch as well for the DataConnector to not fail.

I feel there should be something like a <Dependency
ref="someAttributeXYZ" *emptyisok**="false"* />. Am I missing something,
or can this be reached via other means?

Regards,

Martin





-- 
Dr. Martin Haase, Solutions Engineer

DAASI International GmbH        
Europaplatz 3                   
D-72072 Tübingen                
Germany                    

phone: +49 7071 407109-0
fax:   +49 7071 407109-9  
email: martin.haase at daasi.de
web:   www.daasi.de

Sitz der Gesellschaft: Tübingen
Registergericht: Amtsgericht Stuttgart, HRB 382175
Geschäftsleitung: Peter Gietz

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://shibboleth.net/pipermail/users/attachments/20180529/04d54ff8/attachment.html>


More information about the users mailing list