PS "serious bug" might be too strong - it is a serious EDITORIAL bug, but the
presence of 8.21.10 makes the intent clear, even if the text does not actually
clearly specify the intent! A Corrigendum will in due course appear to clarify
the text.
(No further replies needed.)
John L
John Larmouth wrote:
There seems to be a serious bug here in the spec. 8.21.10 is the clause
you need for UTF8String. Clause 8.21.5 should list UTF8String as a
further exclusion (notice that it does not appear in table 3), and
8.21.3 should reference 8.21.4, 8.21.5, *and* 8.21.10.
I am afraid this text seems to be a bit of a mess!
(But I think your encoding is correct!)
John L
Eduard Lascu wrote:
I am trying to implement an encoding/decoding function for UTF 8
Strings in
BER. The standard (ITU-T X.690 - 07/2002), clauses 8.21.3 and 8.21.5
explain
that strings (other than UniversalString and BMLString) should be encoded
according to the ISO/IEC 2022 standard. Can anybody here confirm that the
octets for each character should be encoded according to the following
table?
Table 1. UTF-8 encoding
===============================================
bytes bits representation
1 7 0bbbbbbb
2 11 110bbbbb 10bbbbbb
3 16 1110bbbb 10bbbbbb 10bbbbbb
4 21 11110bbb 10bbbbbb 10bbbbbb 10bbbbbb
===============================================
Each b represents a bit that can be used to store character data.
Best regards,
Eddie
_______________________________________________
ASN1 mailing list
[email protected]
http://lists.asn1.org/mailman/listinfo/asn1
--
Prof John Larmouth
Larmouth T&PDS Ltd
(Training and Protocol Development Services Ltd)
1 Blueberry Road
Bowdon [EMAIL PROTECTED]
Cheshire WA14 3LS
England
Tel: +44 161 928 1605 Fax: +44 161 928 8069
_______________________________________________
ASN1 mailing list
[email protected]
http://lists.asn1.org/mailman/listinfo/asn1