Re: Ensure uniqueness over multiple attributes?

2017-10-13 Thread Michael Ströder
Karsten Heymann wrote:
> IMHO this does not work without adding all possible values to at least
> one of the attributes *or* SUP-ing all attribute values from a common
> attribute type.
> 
> How would attribute inheritance tie into this? I'm relatively free in
> modifying our ldap schema so making mailAlias SUP mail would be possible. 

slapo-unique simply searches for an attribute type and value (should be
eq-indexed). A SUP-ed attribute type also matches a search for all
sub-types.

E.g. try searching with parent attribute 'name'.

Note: Depending on your clients and attributes used this might *not* be
what you want.

In my LDAP directories for e-mail the value in 'mail' is always also
present in e.g. 'mailLocalAddress' for which I have a unique constraint.

Ciao, Michael.



smime.p7s
Description: S/MIME Cryptographic Signature


Re: Ensure uniqueness over multiple attributes?

2017-10-13 Thread Karsten Heymann
2017-10-13 16:25 GMT+02:00 Michael Ströder :

> Dieter Klünter wrote:
> > slapo-unique(5) plus slapo-constraint(5)
>

Interesting, I hadn't that in mind. Unfortunately I think Michael is right
that using a constraint in this scenario won't work. But I have other uses
for slapo-contraint in mind already.


> IMHO this does not work without adding all possible values to at least
> one of the attributes *or* SUP-ing all attribute values from a common
> attribute type.
>

How would attribute inheritance tie into this? I'm relatively free in
modifying our ldap schema so making mailAlias SUP mail would be possible.

+Karsten


Re: Ensure uniqueness over multiple attributes?

2017-10-13 Thread Michael Ströder
Dieter Klünter wrote:
> Am Fri, 13 Oct 2017 14:44:09 +0200
> schrieb Karsten Heymann :
>> does the unique overlay support checking multiple values for a single
>> uniqueness check? Our clients can use emails in two attributes (think
>> mail and mailAlias) and addresses have to be unique in regard to both
>> fields, which means an address that is used in either of them cannot
>> be used in any other of them. Is that possible?
> 
> slapo-unique(5) plus slapo-constraint(5)

IMHO this does not work without adding all possible values to at least
one of the attributes *or* SUP-ing all attribute values from a common
attribute type.

Ciao, Michael.



smime.p7s
Description: S/MIME Cryptographic Signature


Re: Ensure uniqueness over multiple attributes?

2017-10-13 Thread Dieter Klünter
Am Fri, 13 Oct 2017 14:44:09 +0200
schrieb Karsten Heymann :

> Hi,
> 
> does the unique overlay support checking multiple values for a single
> uniqueness check? Our clients can use emails in two attributes (think
> mail and mailAlias) and addresses have to be unique in regard to both
> fields, which means an address that is used in either of them cannot
> be used in any other of them. Is that possible?

slapo-unique(5) plus slapo-constraint(5)

-Dieter

-- 
Dieter Klünter | Systemberatung
http://sys4.de
GPG Key ID: E9ED159B
53°37'09,95"N
10°08'02,42"E



Ensure uniqueness over multiple attributes?

2017-10-13 Thread Karsten Heymann
Hi,

does the unique overlay support checking multiple values for a single
uniqueness check? Our clients can use emails in two attributes (think mail
and mailAlias) and addresses have to be unique in regard to both fields,
which means an address that is used in either of them cannot be used in any
other of them. Is that possible?

+Karsten