Uniqueness plugin builds an LDAP filter to search for duplicate values using list of uniqueness attributes per configuration. The search then uses existing matching rules defined for these attributes to match values captured in LDAP ADD operation.
Sometimes comparison needs to be a bit wider than the original match. For example, case-insensitive match would be needed to capture duplicates for already existing attributes with exact matches.
It would be nice to specify attributes and their custom match rules in the plugin configuration.
For example,
uniqueness-attribute-name: fooName:caseIgnoreMatch:
would allow uniqueness plugin to build a filter that includes (|(fooName:caseIgnoreMatch:=<some value>)(..)).
Right now this syntax is accepted without any issue but then fails to apply because the plugin in pre-add callback will attempt to iterate over the configured attributes and retrieve them from the added mods. Obviously, fooName:caseIgnoreMatch: attribute name will not match any attribute in the ADD mods.
Uniqueness plugin builds an LDAP filter to search for duplicate values using list of uniqueness attributes per configuration. The search then uses existing matching rules defined for these attributes to match values captured in LDAP ADD operation.
Sometimes comparison needs to be a bit wider than the original match. For example, case-insensitive match would be needed to capture duplicates for already existing attributes with exact matches.
It would be nice to specify attributes and their custom match rules in the plugin configuration.
For example,
would allow uniqueness plugin to build a filter that includes
(|(fooName:caseIgnoreMatch:=<some value>)(..)).Right now this syntax is accepted without any issue but then fails to apply because the plugin in pre-add callback will attempt to iterate over the configured attributes and retrieve them from the added mods. Obviously,
fooName:caseIgnoreMatch:attribute name will not match any attribute in the ADD mods.