Subject: [AAA-WG]: [issue] Issue 40: Can an AVP have zero data length?

From: "Mark Jones" <[email-masked]>
Date: Mon, 4 Jun 2001 16:57:32 -0400

[Note: This appears to be a duplicate of the issue raised by Paul Funk
earlier today but I'm posting it for completeness since it is already
being tracked on the issues web page. If Paul agrees, I suggest we track
his issue under #40 rather than create a new one.]

Submitter name: Mark Jones
Submitter email address: [email-masked]
Date first submitted: Interim AAA Meeting in May, 2001
Reference: Issue #40 on http://www.diameter.org/issues.html
Document: Base
Comment type: T
Priority: 2
Section: 4.3
Rationale/Explanation of issue:

In section 4.3 of the base protocol draft (-04), the Data field is
described as being zero or more octets in length. However, none of the
data types as defined in  section 4.3 of the -04 draft can have zero data
bytes.

From Paul's email earlier today (issue: OctetString with null value), the
Octet String can have zero bytes when the EAP-Payload AVP indicates
EAP-Start so the OctetString description is incorrect.

Requested changes:

+ Update the OctetString description as follows:

      OctetString
         The data contains arbitrary data of variable length and MAY be
         a null value, i.e. zero data bytes. Unless otherwise noted,
         the AVP Length field MUST be set to at least 8 (12 if the 'V'
         bit is enabled).  Data used to transmit (human readable)
         character string data uses the UTF-8 [24] character set and is
         NOT NULL-terminated. AVP Values of this type that do not align
         on a 32-bit boundary MUST have the necessary padding.

Regards,
       Mark

---

From: Pat Calhoun <[email-masked]>
Date: Mon, 4 Jun 2001 14:00:38 -0700

> his issue under #40 rather than create a new one.]

We could, but I've already added the issue to the web site (and accepted it by me to
be included in the base -05 since EAP will not work without this change).

This issue, one the other hand, is asking for the inverse :)

PatC

---

From: "Mark Jones" <[email-masked]>
Date: Mon, 4 Jun 2001 17:33:08 -0400

Pat,

> This issue, one the other hand, is asking for the inverse :)

Didn't Paul request a change to the OctetString description such that it
can have 0-length values? I thought the OctetString text I suggested
addressed this.
What do you have for the OctetString description in the -05 draft?

Regards,
       Mark

---

From: Pat Calhoun <[email-masked]>
Date: Mon, 4 Jun 2001 14:26:55 -0700

> What do you have for the OctetString description in the -05 draft?

hmm.... now I'm really confused. -05 currently has:

   The Data field is zero or more octets and contains information
   specific to the Attribute. The format and length of the Data field is
   determined by the AVP Code and AVP Length fields. The format of the
   Data field MAY be one of the following data types.

   The interpretation of the values depends on the specification of the
   AVP.  For example, an OctetString may be used to transmit human
   readable string data and Unsigned32 may be used to transmit a time
   value.  Conventions for these common interpretations are described
   below.

      OctetString
         The data contains arbitrary data of variable length. Unless
         otherwise noted, the AVP Length field MUST be set to at least 8
         (12 if the 'V' bit is enabled).  Data used to transmit (human
         readable) character string data uses the UTF-8 [24] character
         set and is NOT NULL-terminated. The minimum Length field MUST
         be 9, but can be set to any value up to 65504 bytes. AVP Values
         of this type that do not align on a 32-bit boundary MUST have
         the necessary padding.

So if your issue is consistent with the above change, then we can delete Paul's
issue and simply mark it as a dup.

PatC

---

From: "Mark Jones" <[email-masked]>
Date: Mon, 4 Jun 2001 17:45:53 -0400

Pat,

> hmm.... now I'm really confused. -05 currently has:

The new text looks good to me. My "issue" #40 was really just a question I
posed at the interim meeting. I noticed the discrepancy in the data types
description text in -04 but was unaware of scenarios which justified a
zero data length AVP. Paul answered my question with his EAP example so I
consider issue #40 closed.

Regards,
       Mark

---

From: Barney Wolff <[email-masked]>
Date: Mon, 4 Jun 2001 21:39:51 -0400

Pat, is the 9 below a typo, or are you intending to say that an AVP
that is intended to have human-readable text cannot be empty?  If
so, I respectfully disagree.  But if that's the way it ends up,
the text should say explicitly "An AVP defined as containing
human-readable text cannot be empty."

Barney

---

From: Pat Calhoun <[email-masked]>
Date: Mon, 4 Jun 2001 18:36:52 -0700

On Mon, Jun 04, 2001 at 09:39:51PM -0400, Barney Wolff wrote:
> that is intended to have human-readable text cannot be empty? 

sigh. yes, I missed that one :( :(

PatC