1 '\" te
   2 .\" Copyright (C) 1990, Regents of the University of Michigan.  All Rights Reserved.
   3 .\" Portions Copyright (C) 1997, Sun Microsystems, Inc. All Rights Reserved.
   4 .\" The contents of this file are subject to the terms of the Common Development and Distribution License (the "License").  You may not use this file except in compliance with the License.
   5 .\" You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE or http://www.opensolaris.org/os/licensing.  See the License for the specific language governing permissions and limitations under the License.
   6 .\" When distributing Covered Code, include this CDDL HEADER in each file and include the License file at usr/src/OPENSOLARIS.LICENSE.  If applicable, add the following below this CDDL HEADER, with the fields enclosed by brackets "[]" replaced with your own identifying information: Portions Copyright [yyyy] [name of copyright owner]
   7 .TH LDAPTEMPLATES.CONF 4 "Jul 9, 2003"
   8 .SH NAME
   9 ldaptemplates.conf \- configuration file for LDAP display template routines
  10 .SH SYNOPSIS
  11 .LP
  12 .nf
  13 \fB/etc/opt/SUNWconn/ldap/current/ldaptemplates.conf\fR
  14 .fi
  15 
  16 .SH DESCRIPTION
  17 .sp
  18 .LP
  19 The \fBldaptemplates.conf\fR file contains information used by the LDAP display
  20 routines.
  21 .sp
  22 .LP
  23 Blank lines and lines that start with a hash character ('#') are treated as
  24 comments and ignored. Non-comment lines contain one or more tokens. Tokens are
  25 separated by white space, and double quotes can be used to include white space
  26 inside a token.
  27 .sp
  28 .LP
  29 The first non-commment line specifies the version of the template information
  30 and must contain the token \fBVersion\fR followed by an integer version number.
  31 For example,
  32 .sp
  33 .in +2
  34 .nf
  35 Version 1
  36 .fi
  37 .in -2
  38 .sp
  39 
  40 .sp
  41 .LP
  42 The current version is \fI1\fR, so the above example is always the correct
  43 first line.
  44 .sp
  45 .LP
  46 The remainder of the file consists of one or more display templates. The first
  47 two lines of the display template each contain a single token that specifies
  48 singular and plural names for the template in a user-friendly format. For
  49 example,
  50 .sp
  51 .in +2
  52 .nf
  53 "Person"
  54 "People"
  55 .fi
  56 .in -2
  57 .sp
  58 
  59 .sp
  60 .LP
  61 specifies appropriate names for a template designed to display person
  62 information.
  63 .sp
  64 .LP
  65 The next line specifies the name of the icon or similar element that is
  66 associated with this template. For example,
  67 .sp
  68 .in +2
  69 .nf
  70 "person icon"
  71 .fi
  72 .in -2
  73 .sp
  74 
  75 .sp
  76 .LP
  77 The next line is a blank-separated list of template options. "" can be used if
  78 no options are desired. Available options are: \fBaddable\fR (it is appropriate
  79 to allow entries of this type to be added), \fBmodrdn\fR (it is appropriate to
  80 offer the \fBmodify rdn\fR operation), \fBaltview\fR (this template is an
  81 alternate view of another template). For example,
  82 .sp
  83 .in +2
  84 .nf
  85 "addable" "modrdn"
  86 .fi
  87 .in -2
  88 .sp
  89 
  90 .sp
  91 .LP
  92 The next portion of the template is a list of X.500 object classes that is used
  93 to determine whether the template should be used to display a given entry. The
  94 object class information consists of one or more lines, followed by a
  95 terminating line that contains the single token \fBEND\fR. Each line contains
  96 one or more object class names, all of which must be present in a directory
  97 entry. Multiple lines can be used to associate more than one set of object
  98 classes with a given template. For example,
  99 .sp
 100 .in +2
 101 .nf
 102 emailPerson
 103 orgPerson
 104 END
 105 .fi
 106 .in -2
 107 .sp
 108 
 109 .sp
 110 .LP
 111 means that the template is appropriate for display of \fBemailPerson\fR entries
 112 or \fBorgPerson\fR entries.
 113 .sp
 114 .LP
 115 The next line after the object class list is the name of the attribute to
 116 authenticate as to make changes (use "" if it is appropriate to authenticate as
 117 the entry itself). For example,
 118 .sp
 119 .in +2
 120 .nf
 121 "owner"
 122 .fi
 123 .in -2
 124 .sp
 125 
 126 .sp
 127 .LP
 128 The next line is the default attribute to use when naming a new entry, for
 129 example,
 130 .sp
 131 .in +2
 132 .nf
 133 "cn"
 134 .fi
 135 .in -2
 136 .sp
 137 
 138 .sp
 139 .LP
 140 The next line is the distinguished name of the default location under which new
 141 entries are created. For example,
 142 .sp
 143 .in +2
 144 .nf
 145 "o=XYZ, c=US"
 146 .fi
 147 .in -2
 148 .sp
 149 
 150 .sp
 151 .LP
 152 The next section is a list of rules used to assign default values to new
 153 entries. The list should be terminated with a line that contains the single
 154 token \fBEND\fR. Each line in this section should either begin with the token
 155 \fBconstant\fR and be followed by the name of the attribute and a constant
 156 value to assign, or the line should begin with \fBaddersdn\fR followed by the
 157 name of an attribute whose value will be the DN of the person who has
 158 authenticated to add the entry. For example,
 159 .sp
 160 .in +2
 161 .nf
 162 constant        associatedDomain        XYZ.us
 163 addersdn        seeAlso
 164 END
 165 .fi
 166 .in -2
 167 .sp
 168 
 169 .sp
 170 .LP
 171 The last portion of the template is a list of items to display. It consists of
 172 one or more lines, followed by a terminating line that contains the single
 173 token \fBEND\fR. Each line is must begin with the token \fBsamerow\fR or the
 174 token \fBitem\fR
 175 .sp
 176 .LP
 177 It is assumed that each item appears on a row by itself unless it was preceded
 178 by a \fBsamerow\fR line (in which case it should be displayed on the same line
 179 as the previous item, if possible). Lines that begin with \fBsamerow\fR should
 180 not have any other tokens on them.
 181 .sp
 182 .LP
 183 Lines that begin with \fBitem\fR must have at least three more tokens on them:
 184 an item type, a label, and an attribute name. Any extra tokens are taken as
 185 extra arguments.
 186 .sp
 187 .LP
 188 The item type token must be one of the following strings:
 189 .sp
 190 .ne 2
 191 .na
 192 \fB\fBcis\fR \fR
 193 .ad
 194 .RS 14n
 195 case-ignore string attributes
 196 .RE
 197 
 198 .sp
 199 .ne 2
 200 .na
 201 \fB\fBmls\fR \fR
 202 .ad
 203 .RS 14n
 204 multiline string attributes
 205 .RE
 206 
 207 .sp
 208 .ne 2
 209 .na
 210 \fB\fBmail\fR \fR
 211 .ad
 212 .RS 14n
 213 RFC-822 conformant mail address attributes
 214 .RE
 215 
 216 .sp
 217 .ne 2
 218 .na
 219 \fB\fBdn\fR \fR
 220 .ad
 221 .RS 14n
 222 distinguished name pointer attributes
 223 .RE
 224 
 225 .sp
 226 .ne 2
 227 .na
 228 \fB\fBbool\fR \fR
 229 .ad
 230 .RS 14n
 231 Boolean attributes
 232 .RE
 233 
 234 .sp
 235 .ne 2
 236 .na
 237 \fB\fBjpeg\fR \fR
 238 .ad
 239 .RS 14n
 240 JPEG photo attributes
 241 .RE
 242 
 243 .sp
 244 .ne 2
 245 .na
 246 \fB\fBjpegbtn\fR \fR
 247 .ad
 248 .RS 14n
 249 a button that will retrieve and show a JPEG photo attribute
 250 .RE
 251 
 252 .sp
 253 .ne 2
 254 .na
 255 \fB\fBfax\fR \fR
 256 .ad
 257 .RS 14n
 258 FAX T.4 format image attributes
 259 .RE
 260 
 261 .sp
 262 .ne 2
 263 .na
 264 \fB\fBfaxbtn\fR \fR
 265 .ad
 266 .RS 14n
 267 a button that will retrieve and show a FAX photo attribute
 268 .RE
 269 
 270 .sp
 271 .ne 2
 272 .na
 273 \fB\fBaudiobtn\fR \fR
 274 .ad
 275 .RS 14n
 276 audio attributes
 277 .RE
 278 
 279 .sp
 280 .ne 2
 281 .na
 282 \fB\fBtime\fR \fR
 283 .ad
 284 .RS 14n
 285 UTC time attributes
 286 .RE
 287 
 288 .sp
 289 .ne 2
 290 .na
 291 \fB\fBdate\fR \fR
 292 .ad
 293 .RS 14n
 294 UTC time attributes where only the date portion should be shown
 295 .RE
 296 
 297 .sp
 298 .ne 2
 299 .na
 300 \fB\fBurl\fR \fR
 301 .ad
 302 .RS 14n
 303 labeled Uniform Resource Locator attributes
 304 .RE
 305 
 306 .sp
 307 .ne 2
 308 .na
 309 \fB\fBsearchact\fR \fR
 310 .ad
 311 .RS 14n
 312 define an action that will do a directory search for other entries
 313 .RE
 314 
 315 .sp
 316 .ne 2
 317 .na
 318 \fB\fBlinkact\fR \fR
 319 .ad
 320 .RS 14n
 321 define an action which is a link to another display template
 322 .RE
 323 
 324 .sp
 325 .ne 2
 326 .na
 327 \fB\fBprotected\fR \fR
 328 .ad
 329 .RS 14n
 330 for an encrypted attribute, with values displayed as asterisks
 331 .RE
 332 
 333 .sp
 334 .LP
 335 An example of an item line for the drink attribute (displayed with label "Work
 336 Phone"):
 337 .sp
 338 .in +2
 339 .nf
 340 item cis        "Work Phone"    telephoneNumber
 341 .fi
 342 .in -2
 343 .sp
 344 
 345 .SH EXAMPLES
 346 .LP
 347 \fBExample 1 \fRA Sample Configuration File Containing a Template that Displays
 348 People Entries
 349 .sp
 350 .LP
 351 The following template configuration file contains a templates for display of
 352 people entries.
 353 
 354 .sp
 355 .in +2
 356 .nf
 357     #
 358     # LDAP display templates
 359     #
 360     # Version must be 1 for now
 361     #
 362     Version 1
 363     #
 364     # Person template
 365     "Person"
 366     "People"
 367 
 368     # name of the icon that is associated with this template
 369     "person icon"
 370 
 371     # blank-separated list of template options ("" for none)
 372     "addable"
 373 
 374     #
 375     # objectclass list
 376     person
 377     END
 378 
 379     #
 380     # name of attribute to authenticate as ("" means auth as this entry)
 381     ""
 382 
 383     #
 384     # default attribute name to use when forming RDN of a new entry
 385     #
 386     "cn"
 387 
 388     #
 389     # default location when adding new entries (DN; "" means no default)
 390     "o=XYZ, c=US"
 391 
 392     #
 393     # rules used to define default values for new entries
 394     END
 395 
 396     #
 397     # list of items for display
 398     item jpegbtn        "View Photo"            jpegPhoto       "Next Photo"
 399     item audiobtn       "Play Sound"            audio
 400     item cis    "Also Known As"         cn
 401     item cis    "Title"                 title
 402     item mls    "Work Address"          postalAddress
 403     item cis    "Work Phone"            telephoneNumber
 404     item cis    "Fax Number"            facsimileTelephoneNumber
 405     item mls    "Home Address"          homePostalAddress
 406     item cis    "Home Phone"            homePhone
 407     item cis    "User ID"               uid
 408     item mail   "E-Mail Address"        mail
 409     item cis    "Description"           description
 410     item dn             "See Also"              seeAlso
 411     END
 412 .fi
 413 .in -2
 414 .sp
 415 
 416 .SH ATTRIBUTES
 417 .sp
 418 .LP
 419 See \fBattributes\fR(5) for a description of the following attributes:
 420 .sp
 421 
 422 .sp
 423 .TS
 424 box;
 425 c | c
 426 l | l .
 427 ATTRIBUTE TYPE  ATTRIBUTE VALUE
 428 Stability Level Evolving
 429 .TE
 430 
 431 .SH SEE ALSO
 432 .sp
 433 .LP
 434 \fBldap_disptmpl\fR(3LDAP), \fBldap_entry2text\fR(3LDAP), \fBattributes\fR(5)