Subject: [Ietf-krb-wg] hyphen vs underscore in pa-types

From: Sam Hartman <[email-masked]>
Date: Sat, 31 Jan 2009 17:39:25 -0500 (EST)

I'm pleased that the most pressing open issue on my plate is punctuation.  I think that means we're very close to done.

Larry noticed  that I had changed from using underscore to hyphen in some of the constants in the preauth framework.

RFC 4120 uses _ for most constants, including things like errors.
However hyphen is used for pa-data, typed-data, enctypes and checksum
types.

I decided to be consistent with RFC 4120 and used hyphen for pa-data and underscore for everything else.
Larry (and I) find it a bit jarring that some constants use hyphen and some use underscore.  (We won't mention pa-pk-as-rep_old).

Did I do the right thing or should we do something else?

_______________________________________________
ietf-krb-wg mailing list
[email-masked]
https://lists.anl.gov/mailman/listinfo/ietf-krb-wg

---

From: Tom Yu <[email-masked]>
Date: Sat, 31 Jan 2009 21:16:03 -0500

> Did I do the right thing or should we do something else?

This is a symptom of a long-standing inconsistency in our
specifications.

There are several things to consider:

* identifiers in ASN.1

* identifiers in running text

* identifiers in tables

* hyphens vs underscores

* all-caps vs all-lowercase vs mixed-case

* type names vs value names

Identifiers in ASN.1 use hyphens, not underscores.  RFC 4120 uses a
mixture.  ASN.1 identifiers that reference values (constants) must
begin with a lowercase letter, while ASN.1 identifiers that reference
types must begin with an uppercase letter.

RFC 4120 transforms some (but not all) ASN.1 type names and value
names into forms that resemble C identifiers, specifically the
all-caps-with-underscores form typically used for preprocessor macros.

A downside to using ASN.1 syntax conventions for constants is that the
conventionally all-lowercase form of these identifiers does not stand
out visually from running text.  Identifiers used in tables lack some
of these problems.

Further confusing matters, we do not use ASN.1 value assignments in
RFC 4120, which might otherwise look like

    pa-etype-info2 Int32 ::= 19

and we do define ASN.1 types, which for example might look like

    ETYPE-INFO2 ::= SEQUENCE SIZE (1..MAX) OF ETYPE-INFO2-ENTRY

which looks very similar.

Most of the constants in RFC 4120 are meant to be integers.  Integers
may be referenced by C preprocessor macros or by ASN.1 value
assignments.  Sometimes implied ASN.1 value assignments, e.g. numbers
corresponding to pa-data types, are listed in RFC 4120 with all caps
but hyphens.  This can be interpreted as an all-caps version of the
(implied) all-lowercase value assignment, transformed thus for the
sake of readability.
_______________________________________________
ietf-krb-wg mailing list
[email-masked]
https://lists.anl.gov/mailman/listinfo/ietf-krb-wg