[Date Prev][Date Next] [Chronological] [Thread] [Top]

Re: how to add a .jpg



Fabrice Cartron wrote:

> Bonjour,
>
> Can some one give me an example of syntax in order
> to add a jpg photo to a ldap user.
>
> Thank
> --
> Fabrice Cartron

Since I had also had this problem before, I will go ahead and answer it
in the list rather than give you a pointer to another document.  Well
actually I will do both, the document you will want to check is the rfc
(rfc2849.txt).

For me to add my image, I put this in the ldif file... Actually I will
attach the file.  The way I made the file was to start with this:

dn: uid=wtruitt,dc=usa,dc=alcatel,dc=com
changetype: modify
add: jpegPhoto
jpegPhoto::

I then mmencoded the image, and read it into the file after jpegPhoto.
I then inserted a space before each line of the base64 encoded image.

 -walter

dn: uid=wtruitt,dc=usa,dc=alcatel,dc=com
changetype: modify
add: jpegPhoto
jpegPhoto::
 /9j/4AAQSkZJRgABAQAAAQABAAD//gBIQ1JFQVRPUjogWFYgVmVyc2lvbiAzLjEwYSAgUmV2
 OiAxMi8yOS85NCAgUXVhbGl0eSA9IDc1LCBTbW9vdGhpbmcgPSAwCv/bAEMACAYGBwYFCAcH
 BwkJCAoMFA0MCwsMGRITDxQdGh8eHRocHCAkLicgIiwjHBwoNyksMDE0NDQfJzk9ODI8LjM0
 Mv/bAEMBCQkJDAsMGA0NGDIhHCEyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIy
 MjIyMjIyMjIyMjIyMjIyMv/AABEIAHgAoAMBIgACEQEDEQH/xAAfAAABBQEBAQEBAQAAAAAA
 AAAAAQIDBAUGBwgJCgv/xAC1EAACAQMDAgQDBQUEBAAAAX0BAgMABBEFEiExQQYTUWEHInEU
 MoGRoQgjQrHBFVLR8CQzYnKCCQoWFxgZGiUmJygpKjQ1Njc4OTpDREVGR0hJSlNUVVZXWFla
 Y2RlZmdoaWpzdHV2d3h5eoOEhYaHiImKkpOUlZaXmJmaoqOkpaanqKmqsrO0tba3uLm6wsPE
 xcbHyMnK0tPU1dbX2Nna4eLj5OXm5+jp6vHy8/T19vf4+fr/xAAf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