Table of Contents

This function is only available in CFEngine Enterprise.

Prototype: ldaparray(array, uri, dn, filter, scope, security)

Return type: boolean

Description: Fills array with the entire LDAP record, and returns whether there was a match for the search.

This function retrieves an entire record with all elements and populates an associative array with the entries. It returns a class that is true if there was a match for the search, and false if nothing was retrieved.


  • array: string, in the range: .*
  • uri: string, in the range: .*
  • dn: string, in the range: .*
  • filter: string, in the range: .*
  • scope: one of
    • subtree
    • onelevel
    • base
  • security: one of
    • none
    • ssl
    • sasl

dn specifies the distinguished name, an ldap formatted name built from components, e.g. "dc=cfengine,dc=com". filter is an ldap search, e.g. "(sn=User)". Which security values are supported depends on machine and server capabilities.



   "gotdata" expression => ldaparray(