Subject: Revised Matched Values Draft

From: "David Chadwick" <[email-masked]>
Date: Sat, 1 Jul 2000 21:45:33 +0100

Could you please publish the attached Internet Draft

Regards

David

***************************************************

David Chadwick
IS Institute, University of Salford, Salford M5 4WT
Tel +44 161 295 5351  Fax +44 161 745 8169
Mobile +44 790 167 0359
Email [email-masked]
Home Page  http://www.salford.ac.uk/its024/chadwick.htm
Understanding X.500  http://www.salford.ac.uk/its024/X500.htm
X.500/LDAP Seminars http://www.salford.ac.uk/its024/seminars.htm
Entrust key validation string MLJ9-DU5T-HV8J

***************************************************

Internet-Draft                                      David Chadwick
LDAPExt WG                       		   University of Salford      
Intended Category: Standards Track                     Sean Mullan
								  Sun Microsystems
Expires: 1 January 2001                             1 July 2000

Returning Matched Values with LDAPv3
<draft-ldapext-matchedval-02.txt>

STATUS OF THIS MEMO

This document is an Internet-Draft and is in full conformance with 
all the provisions of Section 10 of RFC2026.

Internet-Drafts are working documents of the Internet Engineering 
Task Force (IETF), its areas, and its working groups. Note that other
groups may also distribute working documents as Internet-Drafts.

Internet-Drafts are draft documents valid for a maximum of six months
and may be updated, replaced, or obsoleted by other documents at any
time. It is inappropriate to use Internet-Drafts as reference 
material or to cite them other than as "work in progress."

The list of current Internet-Drafts can be accessed at
http://www.ietf.org/ietf/1id-abstracts.txt.

The list of Internet-Draft Shadow Directories can be accessed at
http://www.ietf.org/shadow.html.

This Internet-Draft expires on 1 January 2001. Comments and 
suggestions on this document are encouraged. Comments on this 
document should be sent to the LDAPExt working group discussion list:
                [email-masked]
or directly to the authors.

ABSTRACT

This document describes a control for the Lightweight Directory 
Access Protocol v3 that is used to return a subset of attribute 
values from an entry, specifically, only those values that match a 
"values return" filter. Without support for this control, a client 
must retrieve all of an attribute's values and search for specific 
values locally.

1. Introduction

When reading an attribute from an entry using LDAP v2 [1] or LDAPv3 
[2], it is normally only possible to read either the attribute type, 
or the attribute type and all its values. It is not possible to 
selectively read just a few of the attribute values. If an attribute 
holds many values, for example, the userCertificate attribute, or the 
subschema publishing operational attributes objectClasses and 
attributeTypes [3], then it may be desirable for the user to be able 
to selectively retrieve a subset of the values, specifically, those 
attribute values that match some user defined selection criteria. 
Without the control specified in this [ID/standard] a client must 
read all of the attribute's values and filter out the unwanted 
values, necessitating the client to implement the matching rules. It 
also requires the client to potentially read and process many 
irrelevant values, which can be inefficient if the values are large 
or complex, or there are many values stored per attribute.

This Internet Draft specifies an LDAPv3 control to enable a user to 
return only those values that matched (i.e. returned TRUE to) one or 
more elements of a newly defined "values return" filter. This control 
can be especially useful when used in conjunction with extensible 
matching rules that match on one or more components of complex binary 
attribute values.

The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT",  
"SHOULD", "SHOULD NOT", "RECOMMENDED",  "MAY", and "OPTIONAL" in this 
document are to be interpreted as described in RFC 2119 [5].

2. The valuesReturnFilter Control

The valuesReturnFilter control MAY be critical or non-critical as 
determined by the user. It is only applicable to the Search 
operation, and SHALL be ignored by the server if it is present on any 
other LDAP operation (even if marked critical on such operations).

The object identifier for this control is 1.2.826.0.1.3344810.2.3

The controlValue is 

        ValuesReturnFilter ::= SEQUENCE OF SimpleFilterItem

        SimpleFilterItem ::= CHOICE {
                equalityMatch   [3] AttributeValueAssertion,
                substrings      [4] SubstringFilter,
                greaterOrEqual  [5] AttributeValueAssertion,
                lessOrEqual     [6] AttributeValueAssertion,
                present         [7] AttributeDescription,
                approxMatch     [8] AttributeValueAssertion,
                extensibleMatch [9] SimpleMatchingAssertion }

         SimpleMatchingAssertion ::= SEQUENCE {
                matchingRule    [1] MatchingRuleId OPTIONAL,
                type            [2] AttributeDescription OPTIONAL,
                matchValue      [3] AssertionValue}

All the above data types have their standard meanings as defined in 
[2].

If the server supports this control, the server MUST make use of the 
control as follows:

(1) The Search Filter is first executed in order to determine 
which entries satisfy the Search criteria. The control has no 
impact on this step.

(2) If the typesOnly parameter of the Search Request is TRUE, 
the control has no effect and the Search Request SHOULD be 
processed as if the control had not been specified.

(3) If the attributes parameter of the Search Request consists 
of a list containing only the attribute with OID "1.1" 
(specifying that no attributes are to be returned), the control 
has no effect and the Search Request SHOULD be processed as if 
the control had not been specified.

(4) For each attribute listed in the attributes parameter of the 
Search Request, the server MUST apply the control as follows:

i) Every attribute value that evaluates TRUE against one or 
more elements of the ValuesReturnFilter is placed in the 
SearchResultEntry.
ii) Every attribute value that evaluates FALSE or undefined 
against all elements of the ValuesReturnFilter is not 
placed in the SearchResultEntry. An attribute that has no 
values selected is returned with an empty set of vals.

Editor's Note. There is possibly a more efficient but slightly more 
complex way of achieving the value filtering. An alternative is to 
remove the 'present' SimpleFilterItem (which obviously evaluates true 
for every attribute value of the 'present' attribute description), 
and to say that any attribute whose type is not mentioned in the 
ValuesReturnFilter is not filtered and has all its attribute values 
returned. Comments please.

3. Relationship to X.500

The control is a superset of the matchedValuesOnly boolean of the 
X.500 DAP [4] Search argument, as amended in the latest version [6].
Close examination of the matchedValuesOnly boolean by the LDAPExt 
group revealed ambiguities and complexities in the MVO boolean that 
could not easily be resolved. For example, are only those attribute 
values that contributed to the overall truth of the filter governed 
by the MVO boolean, or all values of attributes in the filter 
governed by the MVO boolean, even if the filter item containing the 
attribute evaluated to false. For this reason the LDAP group decided 
to replace the MVO boolean with a simple filter that removes any 
uncertainty as to whether an attribute value has been selected or 
not. 

4. Examples

(1) The first example simply shows how the control can be used to 
selectively read a subset of attribute values. 

The entry below represents a groupOfNames object class containing 
several members from different organizations.

cn: Cross Organizational Standards Body
member: cn=joe,o=acme
member: cn=alice,o=acme
member: cn=bob,o=foo
member: cn=sue,o=bar

An LDAP search operation is specified with a baseObject set to the
DN of the entry, a baseObject scope, a filter set to 
"member=*o=acme", and the list of attributes to be returned set to 
"member". In addition, a ValuesReturnFilter control is set to 
"member=*o=acme".

The search results returned by the server would consist of the 
following entry:

cn: Cross Organizational Standards Body
member: cn=joe, o=acme
member: cn=alice, o=acme

(2) The second example shows how the control can be set to match on 
attributes that are (mail) and are not (telephoneNumber) part of the 
search filter. It also shows how a user can filter some attribute 
values (mail) and not others (telephoneNumber).

The entries below represent inetOrgPerson [7] object classes located
below some distinguished name in the directory.

cn: Sean Mullan
mail: [email-masked]
mail: [email-masked]
telephoneNumber: +1 781 442 0926
telephoneNumber: 555-9999

cn: David Chadwick
mail: [email-masked]

An LDAP search operation is specified with a baseObject set to the
DN of the entry, a subtree scope, a filter set to 
"(|(mail=[email-masked])(mail=[email-masked]))", and 
the list of attributes to be returned set to "mail telephoneNumber". 
In addition, a ValuesReturnFilter control is set to 
"mail=[email-masked], mail=[email-masked], 
telephoneNumber=*"

The search results returned by the server would consist of the 
following entries:

cn: Sean Mullan
mail: [email-masked]
telephoneNumber: +1 781 442 0926
telephoneNumber: 555-9999

cn: David Chadwick
mail: [email-masked]

Note that the control has no effect on the values returned for the 
"telephoneNumber" attribute (all of the values are returned), since 
the control specified that all values should be returned.

(3) The third example shows how one might retrieve a single attribute 
type schema definition for the "gunk" attribute with OID 1.2.3.4.5

Assume the subschema subentry is held somewhere below the root entry 
with RDN "subschema subentry", and this holds an attributeTypes 
operational attribute holding the descriptions of the 35 attributes 
known to this server (each description is held as a single attribute 
value of the attributeTypes attribute). 

cn: subschema subentry
objectClass: subschema
attributeTypes: ( 2.5.4.3 NAME 'cn' SUP name )
attributeTypes: ( 2.5.4.6 NAME 'c' SUP name SINGLE-VALUE )
attributeTypes: ( 2.5.4.0 NAME 'objectClass' EQUALITY 
objectIdentifierMatch SYNTAX 1.3.6.1.4.1.1466.115.121.1.38 )
attributeTypes: ( 2.5.18.2 NAME 'modifyTimestamp' EQUALITY 
generalizedTimeMatch ORDERING generalizedTimeOrderingMatch
SYNTAX 1.3.6.1.4.1.1466.115.121.1.24 SINGLE-VALUE NO-USER-
MODIFICATION USAGE directoryOperation )
attributeTypes: ( 2.5.21.6 NAME 'objectClasses' EQUALITY 
objectIdentifierFirstComponentMatch SYNTAX 
1.3.6.1.4.1.1466.115.121.1.37 USAGE directoryOperation )
attributeTypes: ( 1.2.3.4.5 NAME 'gunk' EQUALITY caseIgnoreMatch  
SUBSTR caseIgnoreSubstringsMatch SYNTAX 
1.3.6.1.4.1.1466.115.121.1.44{64} )
attributeTypes: ( 2.5.21.5 NAME 'attributeTypes' EQUALITY 
objectIdentifierFirstComponentMatch SYNTAX 
1.3.6.1.4.1.1466.115.121.1.3 USAGE directoryOperation )

plus another 28 - you get the idea.

The user creates an LDAP search operation with a baseObject set to 
root, a subtree scope, a filter set to "objectClass=subschema", the 
list of attributes to be returned set to "attributeTypes", and the 
ValuesReturnFilter set to "attributeTypes=1.2.3.4.5"

The search result returned by the server would consist of the 
following entry:

cn: subschema subentry
attributeTypes: ( 1.2.3.4.5 NAME 'gunk' EQUALITY caseIgnoreMatch  
SUBSTR caseIgnoreSubstringsMatch SYNTAX 
1.3.6.1.4.1.1466.115.121.1.44{64} )

(4) The final example shows how the control can be set to match on 
attributes that are not part of the search filter. For example, 
searching for all entries that have an email address in the
sun.com domain, and returning the telephone number for any attribute
values that start with "555". 

The entries below represent inetOrgPerson [7] object classes located
below some distinguished name in the directory.

cn: Sean Mullan
mail: [email-masked]
mail: [email-masked]
telephoneNumber: +1 781 442 0926
telephoneNumber: 555-9999

cn: David Chadwick
mail: [email-masked]

An LDAP search operation is specified with a baseObject set to the
DN of the entry, a subtree scope, a filter set to "mail=*sun.com", 
and the list of attributes to be returned set to "telephoneNumber". 
In addition, a ValuesReturnFilter control is set to
"telephoneNumber=555*"

The search results returned by the server would consist of the 
following entry:

cn: Sean Mullan
telephoneNumber: 555-9999

5. Security Considerations

This Internet Draft does not discuss security issues at all. 

Note that attribute values MUST only be returned if the access 
controls applied by the LDAP server allow them to be returned, and in 
this respect the effect of the ValuesReturnFilter control is of no 
consequence.

Note that the ValuesReturnFilter control may have a positive effect 
on the deployment of public key infrastructures. Certain PKI 
operations, like searching for specific certificates, become more 
practical (when combined with X.509 certificate matching rules at the 
server) and more scalable, since the control avoids the downloading 
of potentially large numbers of irrelevant certificates which would 
have to be processed and filtered locally (which in some cases is 
very difficult to perform).

6. Acknowledgements

The authors would like to thank members of the LDAPExt list for their 
constructive comments on earlier versions of this draft, and in 
particular to Harald Alvestrand who first suggested having an 
attribute return filter and Bruce Greenblatt who first proposed a 
syntax for this control.

7. Copyright

Copyright (C) The Internet Society (date). All Rights Reserved.

This document and translations of it may be copied and furnished to 
others, and derivative works that comment on or otherwise explain it 
or assist in its implementation may be prepared, copied, published 
and distributed, in whole or in part, without restriction of any 
kind, provided that the above copyright notice and this paragraph are 
included on all such copies and derivative works.  However, this 
document itself may not be modified in any way, such as by removing 
the copyright notice or references to the Internet Society or other 
Internet organizations, except as needed for the purpose of 
developing Internet standards in which case the procedures for 
copyrights defined in the Internet Standards process must be 
followed, or as required to translate it into languages other than 
English.

The limited permissions granted above are perpetual and will not be 
revoked by the Internet Society or its successors or assigns.

This document and the information contained herein is provided on an 
"AS IS" basis and THE INTERNET SOCIETY AND THE INTERNET ENGINEERING 
TASK FORCE DISCLAIMS ALL WARRANTIES, EXPRESS OR IMPLIED, INCLUDING 
BUT NOT LIMITED TO ANY WARRANTY THAT THE USE OF THE INFORMATION 
HEREIN WILL NOT INFRINGE ANY RIGHTS OR ANY IMPLIED WARRANTIES OF 
MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE.

8. References

[1] Yeong, W., Howes, T., and Kille, S. "Lightweight Directory Access 
Protocol", RFC 1777, March 1995.
[2] M. Wahl, T. Howes, S. Kille, "Lightweight Directory Access  
Protocol (v3)", Dec. 1997, RFC 2251
[3] M. Wahl, A. Coulbeck, T. Howes, S. Kille, "Lightweight Directory 
Access Protocol (v3): Attribute Syntax Definitions", RFC 2252, Dec 
1997
[4] ITU-T Rec. X.511, "The Directory: Abstract Service Definition", 
1993.
[5] S.Bradner. "Key words for use in RFCs to Indicate Requirement 
Levels", RFC 2119, March 1997.
[6] ISO/IEC 9594 / ITU-T Rec X.511 (2000) The Directory: Abstract 
Service Definition.
[7] M. Smith. "Definition of the inetOrgPerson LDAP Object Class", 
Internet Draft <draft-smith-ldap-inetorgperson-03.txt>, April 1999.

9. Authors Addresses

David Chadwick
IS Institute
University of Salford
Salford M5 4WT 
England

Email: [email-masked]

Sean Mullan			
Sun Microsystems
East Point Business Park
Dublin 3
Ireland
Tel: +353 1 853 0655
Email: [email-masked]

Internet-Draft   Returning Matched Values with LDAPv3     1 July 2000

1

---

From: "Kurt D. Zeilenga" <[email-masked]>
Date: Sat, 01 Jul 2000 22:47:14 -0700

[portions document trimmed]
>[2],

I suggest not mentioning LDAP v2...

>it is normally only possible to read either the attribute type, 

s/[ID/standard]/document/

>This Internet Draft specifies an LDAPv3 control to enable a user to

s/Internet Draft/document/

>other LDAP operation (even if marked critical on such operations).

I suggest that if this control is provided to non-search operations and marked
critical that an unavailableCriticalExtension (unsupportedCriticalExtension)
error should be returned.  This is consistent with RFC 2251, 4.1.12.
   If the control is not appropriate for the operation and criticality
   field is TRUE, the server MUST NOT perform the operation, and MUST
   instead return the resultCode unsupportedCriticalExtension.

>returned. Comments please.

I prefer the specified approach as it appears easier to implement especially
for servers which separate filter evaluation from attribute list processing.
That is, in U-Mich derived servers, filter evaluation is done by database
backends and attribute list processing is done by the frontend.  Implementing
this control with the above design might prove to be more than slightly
complex and the efficient gain may actually be quite slight.

>several members from different organizations.

Please specify a DN, object classes, and ensure entry is valid per
Standard Track schema in all examples.  You might specify
that entries are provided in LDIF (RFC2849).

>"member". In addition, a ValuesReturnFilter control is set to 

Note that filter (which is missing parentheses) is should evaluation to Undefined
as member attribute type does specify a substrings matching rule.

>values (mail) and not others (telephoneNumber).

Note sure why you have parentheses around these attribute types.

>below some distinguished name in the directory.

I would suggest using organizationalPerson (w/ appropriate attributes)
instead of inetOrgPerson as inetOrgPerson is Informational (though I
don't be this use would cause a standard track maturity issue).

>"mail=[email-masked], mail=[email-masked], 

Please use parentheses.  In fact, you may want to define a string format
for ValuesReturnFilter.  I suggest something like:

  (:(mail=[email-masked])(mail=[email-masked])(telephoneNumber=*))

or if that looks too much like a search filter:

  {(mail=[email-masked])(mail=[email-masked])(telephoneNumber=*)}

>SUBSTR caseIgnoreSubstringsMatch SYNTAX 

Per RFC 2251, subschema subentries should be retrieved using a search
with a base of the subschema subentry's DN, scope base, and filter
(objectclass=subschema).  Please use this procedure in your example.

>SUBSTR caseIgnoreSubstringsMatch SYNTAX 

s/Internet Draft/document/

I suggest you strike this statement as this section discussion
security issues (though mute).  I suggest you revise the comments
below into primary considerations.

>this respect the effect of the ValuesReturnFilter control is of no 

How do "search" versus "read" access to be applied.  That is, where
"search" access is required to evaluation search filters and "read"
access is required to return return attributes, is this mechanism
considered part of "searching" or part of "reading"?  Though the
mechanism uses filters, I'm thinking it's part of "reading" as the
mechanism is only applied entries which match the search filter
and scope.  Would treating the mechanism as part of "reading"
be consistent with X.500/LDAP/vendor access controls?

>constructive comments on earlier versions of this draft, and in

s/draft/document/
 
>Copyright (C) The Internet Society (date). All Rights Reserved.

Date should be specified.

>Internet Draft <draft-smith-ldap-inetorgperson-03.txt>, April 1999.

Published as RFC 2798.

---

From: "Kurt D. Zeilenga" <[email-masked]>
Date: Sat, 01 Jul 2000 23:05:21 -0700

>the control had not been specified.

This step seems unnecessary.

>values selected is returned with an empty set of vals.

How is the control applied if no attribute list is provided or "*"
is in the list.  I would assume, in both cases, that all user
attributes contain in entry would be evaluated (per step 4)
as if they were explicitly listed.

---

From: "David Chadwick" <[email-masked]>
Date: Tue, 11 Jul 2000 23:35:59 +0100

Kurt

I have produced a version 03 including your comments as described 
below, but I wont release it until after Pittsburgh and any other 
comments that I get

> I suggest not mentioning LDAP v2...

done

> 
> >it is normally only possible to read either the attribute type, or
> >the attribute type and all its values. It is not possible to

done

> s/Internet Draft/document/

done

> I suggest that if this control is provided to non-search operations
> and marked critical that an unavailableCriticalExtension
> (unsupportedCriticalExtension) error should be returned.  This is
> consistent with RFC 2251, 4.1.12.

done

> >(specifying that no attributes are to be returned), the control has
> >no effect and the Search Request SHOULD be processed as if the
> >control had not been specified.
> >
> I prefer the specified approach as it appears easier to implement
> especially for servers which separate filter evaluation from attribute
> list processing. That is, in U-Mich derived servers, filter evaluation
> is done by database backends and attribute list processing is done by
> the frontend.  Implementing this control with the above design might
> prove to be more than slightly complex and the efficient gain may
> actually be quite slight.

Editors note removed

> Standard Track schema in all examples. 

The examples are not that good and so I have redone them. 
Example one has been deleted completely. 
Please review in the revised ID when it is published

> You might specify that entries
> are provided in LDIF (RFC2849).

Done

> >An LDAP search operation is specified with a baseObject set to the DN
> >of the entry, a baseObject scope, a filter set to "member=*o=acme",
> >and the list of attributes to be returned set to "member". In
> >addition, a ValuesReturnFilter control is set to "member=*o=acme".
> 
> Note that filter (which is missing parentheses) is should evaluation
> to Undefined as member attribute type does specify a substrings
> matching rule.

Noted. This is why I have redone the examples!

> Note sure why you have parentheses around these attribute types.

It was to show which ones were which in the example, that's all. But 
its gone now.

> don't be this use would cause a standard track maturity issue).

I would rather keep it as well as adding orgPerson, as I need the 
mail attribute.

> >An LDAP search operation is specified with a baseObject set to the DN
> >of the entry, a subtree scope, a filter set to
> Please use parentheses.  In fact, you may want to define a string
> format for ValuesReturnFilter.  I suggest something like:
> 

I think it would be a good idea for the LDAP group to settle on a 
character that can represent the ASN.1 type SEQUENCE, and 
another that can represent a SET. I need this also for my PKI and 
PMI schema document. Steven Legg is working on this at the 
moment, but lets assume for now that comma , represents 
SEQUENCE and + represents SET. Unfortunately we have not 
been too consistent in this in the past, as comma has represented 
both, and + has also represented SET (e.g. as in DNs)

> >1.3.6.1.4.1.1466.115.121.1.44{64} ) attributeTypes: ( 2.5.21.5 NAME
> >'attributeTypes' EQUALITY objectIdentifierFirstComponentMatch SYNTAX

Done

> >searching for all entries that have an email address in the sun.com
> >domain, and returning the telephone number for any attribute values
> >that start with "555". 
> >
> >An LDAP search operation is specified with a baseObject set to the DN
> >of the entry, a subtree scope, a filter set to "mail=*sun.com", and
> >the list of attributes to be returned set to "telephoneNumber". In
> >addition, a ValuesReturnFilter control is set to
> >"telephoneNumber=555*"
> >

Done

> mechanism is only applied entries which match the search filter and
> scope.  Would treating the mechanism as part of "reading" be
> consistent with X.500/LDAP/vendor access controls?
> 

Actually I think that ValuesReturnFilter should be independent of the 
access control mechanism. In other words, search access is used 
as now to find the entries, then valuesReturnFilter filters the 
attributes free of any access contol provisions, then read access is 
applied as now to the filtered attributes to see if they can be 
returned or not. (You could in fact consider the ValuesReturnFilter 
as an access control applied by the user!! or maybe not)

> > constructive comments on earlier versions of this draft, and in

Done

> Date should be specified.

I think that is left until the RFC is published is it not?

> >Internet Draft <draft-smith-ldap-inetorgperson-03.txt>, April 1999.

Done

Many thanks
David

David Chadwick

---

From: "David Chadwick" <[email-masked]>
Date: Tue, 11 Jul 2000 23:36:00 +0100

Date sent:      	Sat, 01 Jul 2000 23:05:21 -0700
To:             	[email-masked]
From:           	"Kurt D. Zeilenga" <[email-masked]>
Subject:        	Re: Revised Matched Values Draft
Copies to:      	[email-masked]

> This step seems unnecessary.

Agreed but I would rather keep it in, as it removes any ambiguity, 
and in the future someone is sure to ask "what about an attribute of 
1.1?". Whilst you can argue that the clause is covered by the 
preceding one, this just makes sure it is crystal clear.

> How is the control applied if no attribute list is provided or "*" is
> in the list.  I would assume, in both cases, that all user attributes
> contain in entry would be evaluated (per step 4) as if they were
> explicitly listed.

Correct. I have added a note to this effect.

David

David Chadwick

---

From: Bruce Greenblatt <[email-masked]>
Date: Tue, 11 Jul 2000 18:01:38 -0700

I'll voice the same reservations this time that I voiced last time.

Use of this control solves a problem that normally exists due to poor 
schema and DIT design.  There is no obvious reason why an entry should have 
so many values of an attribute that an LDAP client would have a problem 
retrieving them all.  Do not put hundreds of values (or however many you 
have in mind) in the attribute.  The introduction uses the userCertificate 
attribute as an example.  While it is true that a single user in the real 
world may have numerous certificates, this should not translate into an 
LDAP entry that has numerous userCertificate attribute values.  IMHO, this 
is poor schema/DIT design.  By creating this control, we only encourage 
this type of design, when we really need to discourage it.  In my mind it 
is analogous to encouraging non-normalized SQL schemas.  I wrote a little 
draft a while back 
(http://www.ietf.org/internet-drafts/draft-greenblatt-ldap-certinfo-schema-02.txt) 
that recommends a schema/DIT design for holding certificate information in 
the schema that allows for selective retrieval of certificates without 
requiring any protocol extensions (or even any new syntaxes).  I have had 
several people ask me privately about this draft with indications that they 
were interested in implementing it.

Additionally, I believe that implementation of this control could place an 
unnecessary burden on the server for sifting through the attribute values, 
when it should be done on the client (perhaps this is more of a stylistic 
issue).  In any case, I would not be in favor of promoting this draft along 
the standards track.  Last time this came up, and I voice this same 
objection to the draft, I received several notes supporting my position.  I 
think that we need to think carefully about what kinds of protocol 
extension that should be standardized, and how they benefit LDAP 
applications.  In my mind this extension provides no benefits to LDAP 
applications.

Bruce

---

From: "David Chadwick" <[email-masked]>
Date: Wed, 12 Jul 2000 11:44:48 +0100

Date sent:      	Tue, 11 Jul 2000 18:01:38 -0700
To:             	[email-masked], "Kurt D. Zeilenga" <[email-masked]>
From:           	Bruce Greenblatt <[email-masked]>
Subject:        	Re: Revised Matched Values Draft
Copies to:      	[email-masked]

Bruce

there are two separate though inter-related issues addressed in 
your ID.
i) the first concerns the DIT structure and the storage of multiple, 
possibly related, attribute values in separate entries rather than in a 
single entry
ii) the second concerns matching on complex attribute values.

Matched values assumes for i) that separate entries will not always 
be employed, and so helps in cases where they are not. 
Interestingly, for the first issue you describe a DIT structure that is 
very similar to the family of entries structure I proposed in <draft-
chadwick-families-00.txt> (now expired). I think that this 
sort of structure is sensible for grouping single values 
together and has lots of uses. We agree that we should try 
to standardise schema and controls for handling this type 
of subtree, as it has wide applicability (and is already in 
use in many directory implementations). However, even if we 
can agree on a standard approach to creating subtrees of 
related entries, there is no guarantee that every DIT will 
always use this approach, so there is still some value in 
the matchedValues ID.

For the matching issue your proposal is that we actually 
dissect a complex attribute into its component parts, 
create separate attributes for each part and then put them 
together in a single entry. I dont like this approach for 
several reasons. Firstly it puts the onus on someone to 
read an attribute, dissect it, create separate attributes, 
and store them together, and make sure that the whole bunch 
are kept atomic. This is not a sensible approach as it puts 
a huge burden on some administrator or the creation of a 
new administration tool to do this. It also is a way of 
introducing errors since you are duplicating data. Secondly 
it mandates the subtree of entries approach and cannot work 
without it. Thirdly, it is not secure in the case of 
certificates (your example). A certificate is a digitally 
signed construct that cannot be manipulated. Your set of 
simple attributes are not digitally signed and therefore 
can be manipulated. There is no security control (outside 
of directory access controls) that stops this manipulation, 
and nothing that allows the user to check that these simple 
attributes are correct (either due to tampering or 
negligence or simple error), other than retrieving the 
certificate and comparing it to his matching criteria (i.e. 
he cannot trust the directory to perform correct matching). 
The better approach (I believe) is to define a matching 
rule that will match on a complex attribute. The matching 
software only has to be implemented in the server (in fact 
it is usually a combination of simple already-existing 
matching rules that need to be combined) and then we remove 
the overhead of dissection and attribute creation which is 
an ongoing process (we also significantly reduce storage 
space as well). Finally it will work with both subtrees of 
related entries and with single entries with lots of 
values. The new ID <draft-pkix-ldap-schema-00.txt> proposes 
an LDAP schema for this.

> schema and DIT design.  There is no obvious reason why an entry should
> have so many values of an attribute that an LDAP client would have a
> problem retrieving them all. 

I suggest that subschema publishing is one such set of attributes 
that have this property. And this is mandatory to support in every 
LDAPv3 server. Thus the authors of LDAPv3 and X.500 are poor 
schema designers by implication. The other point is that every 
LDAPv3 will need a matchedValues type control if it is to return 
individual schema definitions.

> Do not put hundreds of values (or
> however many you have in mind) in the attribute.  The introduction
> uses the userCertificate attribute as an example.  While it is true
> that a single user in the real world may have numerous certificates,
> this should not translate into an LDAP entry that has numerous
> userCertificate attribute values.  IMHO, this is poor schema/DIT
> design.  By creating this control, we only encourage this type of
> design, when we really need to discourage it.  In my mind it is
> analogous to encouraging non-normalized SQL schemas.  I wrote a little
> draft a while back
> (http://www.ietf.org/internet-drafts/draft-greenblatt-ldap-certinfo-sc
> hema-02.txt) that recommends a schema/DIT design for holding
> certificate information in the schema that allows for selective
> retrieval of certificates without requiring any protocol extensions
> (or even any new syntaxes).  I have had several people ask me
> privately about this draft with indications that they were interested
> in implementing it.
> 
> Additionally, I believe that implementation of this control could
> place an unnecessary burden on the server for sifting through the
> attribute values, when it should be done on the client (perhaps this
> is more of a stylistic issue). 

We have had this discussion previously and several messages to 
the list said that sorting through complex attributes was a task that 
should be performed by the server and not the client.

David

> In any case, I would not be in favor
> of promoting this draft along the standards track.  Last time this
> came up, and I voice this same objection to the draft, I received
> several notes supporting my position.  I think that we need to think
> carefully about what kinds of protocol extension that should be
> standardized, and how they benefit LDAP applications.  In my mind this
> extension provides no benefits to LDAP applications.
> 
> Bruce
> 
> 

David Chadwick

---

From: "Kurt D. Zeilenga" <[email-masked]>
Date: Wed, 12 Jul 2000 09:15:43 -0700

At 06:01 PM 7/11/00 -0700, Bruce Greenblatt wrote:
>Use of this control solves a problem that normally exists due to poor schema and DIT design.

X.500 is designed to support multiple valued attributes.  In numerous
cases it makes good sense for a given attribute to have many
(hundreds, thousands, more?).  X.500 recognized this and, to aid
in clients accessing such attributes, provide a mechanism to
returned only the desired values.  LDAPv3 is missing this
functionality.  This control extends LDAP to provide functionality
already available to X.500 users (via DAP).   Without this
control, clients have to implement the appropriate matching rules
and apply it to all returned values to locate the desired values.

The control will solve operational issues which exist today due to
design of our current schema (X.5xx/RFC2252/RFC2256).

I believe this control will be useful for both user and management
applications.  When used appropriately, it will reduce the burden
upon the client and the network.  The overhead of server computation
is likely in the noise (the control may actually reduce server
side computation associated with some requests).  

In the user application space, this control may be used obtain the specification for a particular attribute type.  The subentry (or
entry) which controls the entry attributeTypes attribute may have
hundreds of values as the entry may be allowed to have hundreds
of attribute types.  This reduces the burden of client (and
the network).

In the management application space, this control will also be
quite useful for managing (X.500) ACIs and groups (especially
when used with ACIs... as you cannot nest access groups).

        Kurt

---

From: "David Chadwick" <[email-masked]>
Date: Thu, 13 Jul 2000 15:02:40 +0100

Kurt wrote

> (hundreds, thousands, more?).  X.500 recognized this and, to aid in
> clients accessing such attributes, provide a mechanism to returned
> only the desired values.  LDAPv3 is missing this functionality.  This
> control extends LDAP to provide functionality already available to
> X.500 users (via DAP).   

In fact, LDAP has provided a cleaner and more effective design 
than X.500 originally did (if you remember we started out using the 
X.500 design and replaced it with the new design due to 
complexities and ambiguities in the X.500 design that effectively had 
used one field (the filter) to do two different jobs (this is always a 
bad design decision in the long run).

You might like to know that the X.500 group is proposing to start a 
new work item "alignment with LDAP" and if the match values 
control is standardised by LDAP then X.500 will almost certainly 
add it to DAP in order to keep some semblance of alignment.

David

David Chadwick

---

From: Bruce Greenblatt <[email-masked]>
Date: Thu, 13 Jul 2000 08:46:07 -0700

>>Use of this control solves a problem that normally exists due to poor
schema and DIT design.
>(hundreds, thousands, more?).  X.500 recognized this and, to aid
[snip]

Kurt,

I disagree (obviously).  Just because an implementation allows you to do
something, doesn't mean that it was designed to support it or that is even
a good idea.  For example, just because you can put 25 college students in
a Volkswagen Beetle doesn't make it a good idea, or an indication that the
car's designers had that in mind when they first designed the car.

Bruce
==============================================
Bruce Greenblatt, Ph. D.
Directory Tools and Application Services, Inc.
http://www.directory-applications.com
See my new Book on Internet Directories:
http://www.phptr.com/ptrbooks/ptr_0139744525.html

---

From: "Steven Legg" <[email-masked]>
Date: Fri, 14 Jul 2000 16:54:07 +1000

David,

> -----Original Message-----
> From: David Chadwick [mailto:[email-masked]]
> Sent: Wednesday, 12 July 2000 8:36
> To: Kurt D. Zeilenga
> Cc: [email-masked]

[snip]
 
> another that can represent a SET.

I think it would be a good idea for the LDAP group to settle on a
uniform predictable way of encoding any ASN.1 type (I volunteer to
write an I-D on it if there's any support) but that is another story.

> I need this also for my PKI and 

I don't see any need to distinguished between SET and SEQUENCE in a
string encoding. They can just as well use the same separator, or if
the components of the SET/SEQUENCE are self-contained as in Kurt's
suggestion above then no separators are necessary.

ASN.1 value notation also treats SET & SEQUENCE the same, and I suspect
the comma separators there are cosmetic anyway.

[snip]

Regards,
Steven