Novell is now a part of Micro Focus

Converting Boolean Attributes for OpenLDAP

Novell Cool Solutions: Tip

Digg This - Slashdot This

Posted: 20 Sep 2006


A Forum reader recently asked:

"I want to synchronize some Boolean attributes with IDM3 to an OpenLDAP directory. Doing so, I get the error "value #0 invalid per syntax". I found out that Boolean values in NDS are stored in lowercase letters (true/false) but OpenLDAP requires uppercase values (TRUE/FALSE) according to RFC 2252, section 6.4.

I there a way to change all Boolean attributes from NDS to uppercase values for OpenLDAP in general? Or do I need to change each attribute separately?"

And here's a solution from Father Ramon ...


You can use something like this in an output transformation policy:

  <description>convert boolean values to upper case</description>
     <token-xpath expression="value[@type='state']"/>
     <do-set-local-variable name="uppervalue">
        <token-local-variable name="current-node"/>
     <do-strip-xpath expression="$current-node/text()"/>
     <do-append-xml-text expression="$current-node">
       <token-local-variable name="uppervalue"/>

Novell Cool Solutions (corporate web communities) are produced by WebWise Solutions.

© Copyright Micro Focus or one of its affiliates