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

Re: attributetype 'date' syntax



> Ron Peterson writes:
>> Is there a common syntax for defining a 'date' type attribute?
>
> Generalized Time, OID 1.3.6.1.4.1.1466.115.121.1.24.
>
> Format: yyyymmddHHMMSSzone,
>   where zone is "Z" which means Coordinated Universal Time (equivalent
> to Greenwich Mean Time), or "-HHMM", or "+HHMM".
>
> Actually the minute and second components are optional, and you can also
> have a fraction of a second, but I'm not sure if OpenLDAP supports the
> full syntax.

As far as I remember, OpenLDAP does not admit optional values,
e.g. everything is required.  You can find helper routines to
generate generalized time in libraries/liblutil/utils.c, and
of course the corresponding validation/normalization code in
servers/slapd/schema_init.c; if not present, we could modify
validation/normalization routines to accept formats with missing
optional portions...

p.

-- 
Pierangelo Masarati
mailto:pierangelo.masarati@sys-net.it