Version 1 LDIF examples
You can use the optional charset tag so that the utilities will automatically convert from the specified character set to UTF-8 as in the provided example.
version: 1
charset: ISO-8859-1
dn: cn=Juan Griego, o=University of New Mexico, c=US
cn: Juan Griego
sn: Griego
description:: V2hhdCBhIGNhcmVmdWwgcmVhZGVyIHlvd
title: Associate Dean
title: [title in Spanish]
jpegPhoto:< file:///usr/local/photos/jgriego.jpgIn this instance, all values that follow an attribute name and a single colon are translated from the ISO-8859-1 character set to UTF-8. Values that follow an attribute name and a double colon (such as description:: V2hhdCBhIGNhcm... ) must be base-64 encoded, and are expected to be either binary or UTF-8 character strings. Values read from a file, such as the jpegPhotoattribute specified by the Web address in the previous example, are also expected to be either binary or UTF-8. No translation from the specified "charset" to UTF-8 is done on those values.
In this example of an LDIF file without the charset tag,
content is expected to be in UTF-8, or base-64 encoded UTF-8, or base-64
encoded binary data:
# IBM Directorysample LDIF file
#
# The suffix "o=sample" should be defined before attempting to load
# this data.
version: 1
dn: o=sample
objectclass: top
objectclass: organization
o: sample
dn: ou=Austin, o=sample
ou: Austin
objectclass: organizationalUnit
seealso: cn=Linda Carlesberg, ou=Austin, o=sampleThis
same file could be used without the version: 1header information,
as in previous releases of IBM® Security Verify Directory: # IBM Directorysample LDIF file
#
# The suffix "o=sample" should be defined before attempting to load
# this data.
dn: o=sample
objectclass: top
objectclass: organization
o: sample
dn: ou=Austin, o=sample
ou: Austin
objectclass: organizationalUnit
seealso: cn=Linda Carlesberg, ou=Austin, o=sample Note: The
textual attribute values can be specified in base-64 format.