ietf-smime
[Top] [All Lists]

Re: Comment on ESS and Privacy Marks

1998-03-03 09:27:55
All,

Having worked with a 1988-constrained ASN.1 ToolKit for several years, we
(VDA) can verify that both Paul Hoffman's and Bancroft Scott's "UTF8String"
strategies will work.  We have played similar tricks using both strategies.

It seems that Paul Hoffman's strategy (see below) is cleaner because a
context-specific tag is not required for UTF8String if the ASN.1 software
recognizes UTF8String:

ESSPrivacyMark ::= CHOICE {
    pString      PrintableString (SIZE (1..ub-privacy-mark-length)),
    utf8String   UTF8String
}

ub-privacy-mark-length INTEGER ::= 128


I believe that we should add "SIZE (1..ub-utf8-privacy-mark-length)" to the
UTFString component above where ub-utf8-privacy-mark-length is defined as
"ub-utf8-privacy-mark-length INTEGER ::= 768".

Why 768?  It seems that the SIZE constraint on UTF8String should be 6 times
that of the printableString based on Bancroft's statement as follows:

"For almost all purposes UTF8String characters are three bytes max,
but in theory can range to 6 bytes per character.  Only when carrying
characters that lie outside the range of those carried by BMPString
does it exceed three characters per byte.  You may want to look at: 
ftp://ftp.informatik.uni-erlangen.de/pub/doc/ISO/charsets/ISO-10646-UTF-8.html";

================================
John Pawling   
jsp(_at_)jgvandyke(_dot_)com                             
J.G. Van Dyke & Associates, Inc.           
================================