1LDAPURL(1)                  General Commands Manual                 LDAPURL(1)
2
3
4

NAME

6       ldapurl - LDAP URL formatting tool
7

SYNOPSIS

9       ldapurl      [-a attrs]      [-b searchbase]     [-e [!]ext[=extparam]]
10       [-E [!]ext[=extparam]] [-f filter] [-H ldapuri] [-h ldaphost] [-p ldap‐
11       port] [-s {base|one|sub|children}] [-S scheme]
12

DESCRIPTION

14       ldapurl  is  a  command that allows to either compose or decompose LDAP
15       URIs.
16
17       When invoked with the -H option, ldapurl extracts the components of the
18       ldapuri  option argument, unescaping hex-escaped chars as required.  It
19       basically acts as a frontend to the ldap_url_parse(3) call.  Otherwise,
20       it builds an LDAP URI based on the components passed with the appropri‐
21       ate options, performing the inverse operation.  Option -H is incompati‐
22       ble with options -a, -b, -E, -f, -H, -h, -p, -S, and -s.
23

OPTIONS

25       -a attrs
26              Set a comma-separated list of attribute selectors.
27
28       -b searchbase
29              Set the searchbase.
30
31       -e [!]ext[=extparam]
32
33       -E [!]ext[=extparam]
34
35              Specify  general extensions with -e and search extensions
36              with -E.  ´!´ indicates criticality.
37
38              General extensions:
39                [!]assert=<filter>   (an RFC 4515 Filter)
40                [!]authzid=<authzid> ("dn:<dn>" or "u:<user>")
41                [!]manageDSAit
42                [!]noop
43                ppolicy
44                [!]postread[=<attrs>]        (a comma-separated attribute list)
45                [!]preread[=<attrs>] (a comma-separated attribute list)
46                abandon, cancel (SIGINT sends abandon/cancel; not really controls)
47
48              Search extensions:
49                [!]domainScope                               (domain scope)
50                [!]mv=<filter>                               (matched values filter)
51                [!]pr=<size>[/prompt|noprompt]       (paged results/prompt)
52                [!]sss=[-]<attr[:OID]>[/[-]<attr[:OID]>...]  (server side sorting)
53                [!]subentries[=true|false]           (subentries)
54                [!]sync=ro[/<cookie>]                        (LDAP Sync refreshOnly)
55                        rp[/<cookie>][/<slimit>]     (LDAP Sync refreshAndPersist)
56
57
58       -f filter
59              Set the URL filter.  No particular check  on  con‐
60              formity  with  RFC 4515 LDAP filters is performed,
61              but the value is hex-escaped as required.
62
63       -H ldapuri
64              Specify URI to be exploded.
65
66       -h ldaphost
67              Set the host.
68
69       -p ldapport
70              Set the TCP port.
71
72       -S scheme
73              Set the URL scheme.  Defaults  for  other  fields,
74              like ldapport, may depend on the value of scheme.
75
76       -s {base|one|sub|children}
77              Specify the scope of the search to be one of base,
78              one, sub, or children to specify  a  base  object,
79              one-level,   subtree,  or  children  search.   The
80              default is sub.   Note:  children  scope  requires
81              LDAPv3 subordinate feature extension.
82
83

OUTPUT FORMAT

85       If  the  -H  option  is  used,  the  ldapuri  supplied is
86       exploded in its components, which are printed to standard
87       output in an LDIF-like form.
88
89       Otherwise, the URI built using the values passed with the
90       other options is printed to standard output.
91

EXAMPLE

93       The following command:
94
95           ldapuri -h ldap.example.com -b dc=example,dc=com -s sub -f "(cn=Some One)"
96
97       returns
98
99           ldap://ldap.example.com:389/dc=example,dc=com??sub?(cn=Some%20One)
100
101       The command:
102
103           ldapuri -H ldap://ldap.example.com:389/dc=example,dc=com??sub?(cn=Some%20One)
104
105       returns
106
107           scheme: ldap
108           host: ldap.example.com
109           port: 389
110           dn: dc=example,dc=com
111           scope: sub
112           filter: (cn=Some One)
113

DIAGNOSTICS

115       Exit status is zero if no errors occur.  Errors result in
116       a  non-zero  exit  status  and a diagnostic message being
117       written to standard error.
118

SEE ALSO

120       ldap(3), ldap_url_parse(3),
121

AUTHOR

123       The OpenLDAP Project <http://www.openldap.org/>
124

ACKNOWLEDGEMENTS

126       OpenLDAP Software is  developed  and  maintained  by  The
127       OpenLDAP  Project  <http://www.openldap.org/>.   OpenLDAP
128       Software is derived from University of Michigan LDAP  3.3
129       Release.
130
131
132
133OpenLDAP 2.4.23                   2010/06/30                        LDAPURL(1)
Impressum