Subject: Re: [KEYPROV] XML to ASN.1 for attributes

From: Sean Turner <[email-masked]>
Date: Thu, 06 Aug 2009 12:26:58 -0400

Sean Turner wrote:
> As PSKC is basically done, I'm going to convert the XML 
> elements/attributes to ASN.1.  I've got one question: should the 
> elements with child elements be one attribute or separate attributes? 
> For example, DeviceInfo is as follows:
> 
> <DeviceInfo>
>   <Manufacturer>Manufacturer</Manufacturer>
>   <SerialNo>987654321</SerialNo>
>   <UserId>DC=example-bank,DC=net</UserId>
> 
> We could either have one attribute:
> 
> DeviceInfo ::= SEQUENCE {
>   manufactuer Manufactuer,
>   serialNo    SerialNo,
>   userId      UserId }
> 
> or three separate attributes:
> 
>  Manufactuer, SerialNo, and UserId.
> 
> Which way do people want it?

I'm leaning towards separate attributes....

spt

---

From: "Tschofenig, Hannes (NSN - FI/Espoo)" <[email-masked]>
Date: Thu, 6 Aug 2009 21:00:35 +0300

In XML it is more useful to have child elements rather than attributes.
The main reason is extensibility. When you want to define complex
structures then those cannot be added as attributes. 

I wonder whether a similar restriction replies to ASN.1

Ciao
Hannes

>-----Original Message-----
>From: [email-masked] 
>[mailto:[email-masked]] On Behalf Of ext Sean Turner
>Sent: 06 August, 2009 19:27
>To: [email-masked]
>Subject: Re: [KEYPROV] XML to ASN.1 for attributes
>
>Sean Turner wrote:
>_______________________________________________
>KEYPROV mailing list
>[email-masked]
>https://www.ietf.org/mailman/listinfo/keyprov
>

---

From: Sean Turner <[email-masked]>
Date: Thu, 06 Aug 2009 14:34:24 -0400

Hannes,

The ASN.1 container has an extensible mechanism to add arbitrary data to 
a collection of keys or one key.  It just happens to be called an 
attribute.  So the term is being a bit overloaded.  When we define the 
attributes we can either define the attributes to be the lowest child 
element or a collection of child elements.  We can also use ASN.1's 
extensibility mechanism (the "...") to allow more things to be added to 
an attribute that collects more than one child element.

spt

---

From: "Hannes Tschofenig" <[email-masked]>
Date: Thu, 6 Aug 2009 21:39:06 +0300

This sounds like is only a matter of taste whether you go for option (1) or
(2) listed in your original mail. 

>[mailto:[email-masked]] On Behalf Of Sean Turner
>Sent: 06 August, 2009 21:34
>To: Tschofenig, Hannes (NSN - FI/Espoo)
>Cc: [email-masked]
>The ASN.1 container has an extensible mechanism to add 
>arbitrary data to a collection of keys or one key.  It just 
>happens to be called an attribute.  So the term is being a bit 
>overloaded.  When we define the attributes we can either 
>define the attributes to be the lowest child element or a 
>collection of child elements.  We can also use ASN.1's 
>extensibility mechanism (the "...") to allow more things to be 
>added to an attribute that collects more than one child element.
>
>spt
>

---

From: Sean Turner <[email-masked]>
Date: Thu, 06 Aug 2009 15:00:14 -0400

Hannes,

Pretty much.  The one difference that comes to mind is that if we pick 
the separate attributes option you won't have something called with the 
same name as the parent element (e.g., nothing will be called DeviceInfo).

spt