OASIS Mailing List ArchivesView the OASIS mailing list archive below
or browse/search using MarkMail.

 


Help: OASIS Mailing Lists Help | MarkMail Help

pkcs11 message

[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]


Subject: Proposal: add relevant missing constants


Following a proposal with 4 minor issues related to PKCS#11 constants.
Although I don't use Microsoft Word, after discussion, I'll wrap these
up as .doc document fragments for use by the editors.

Cheers,

Stef


1. CK_INVALID

The value (CK_ULONG)-1 is used all over the place in the specification.
We should define a constant for it, like CK_INVALID. Although perhaps
another name would be better such given that this is similar with
CK_INVALID_HANDLE.

CK_INVALID = (CK_ULONG)-1



2. CKA_CERTIFICATE_CATEGORY

This is a regularly used constant in PKCS#11 code I have written or
encountered. We should define the following constants for use with the
CKA_CERTIFICATE_CATEGORY attribute.

CKV_CATEGORY_UNSPECIFIED = OUL
CKV_CATEGORY_TOKEN_USER = 1UL
CKV_CATEGORY_AUTHORITY = 2UL
CKV_CATEGORY_OTHER_ENTITY = 3UL



3. Constants should have UL suffix

All constants in the headers should be unsigned longs.

This reduces bugs in code where constants are passed around in size
sensitive contexts such as variable argument lists and so on.

Some PKCS#11 headers distributed already do this.



4. CKA_JAVA_MIDP_SECURITY_DOMAIN

Although I've not seen this attribute used in PKCS#11 modules I've
encountered, it is another attribute for which special values are
defined but no constants provided. We might choose to provide:

CKV_DOMAIN_UNSPECIFIED = 0UL
CKV_DOMAIN_MANUFACTUROR = 1UL
CKV_DOMAIN_OPERATOR = 2UL
CKV_DOMAIN_THIRD_PARTY = 3UL


[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]