Skip to content
This repository was archived by the owner on Oct 28, 2018. It is now read-only.

Commit 0e3ef0d

Browse files
committed
* Changes in crypto-conditions.md: * Clarify ordering of all parameters in condition URIs * Add examples for parameter ordering in condition URIs * Fix broken parser values in author’s portion of “NIST - Recommendation for Key Management” * Add special formatting to URI parameter names like `fmt` and `cost`, etc. * Changes in README.md * Fix typo in grunt kramdown command.
1 parent 3dd1eda commit 0e3ef0d

File tree

3 files changed

+41
-11
lines changed

3 files changed

+41
-11
lines changed

.gitignore

+2
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
11
/dist/*
22
!/dist/README.txt
33
/node_modules/
4+
/.DS_Store
5+
/.idea

README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ Uses [kramdown-rfc2629](https://github.com/cabo/kramdown-rfc2629/), [xml2rfc](ht
5656
From root directory of the repo run:
5757

5858
npm install
59-
grunt kramdown-rfc2629
59+
grunt kramdown_rfc2629
6060

6161
To watch edits to `crypto-conditions.md` and auto-generate output when changes are saved run:
6262

src/spec/crypto-conditions.md

+38-10
Original file line numberDiff line numberDiff line change
@@ -103,11 +103,26 @@ informative:
103103
target: http://csrc.nist.gov/publications/nistpubs/800-57/sp800-57_part1_rev3_general.pdf
104104
date: 2012-07
105105
author:
106-
- fullname: Elaine Barker
107-
- fullname: William Barker
108-
- fullname: William Burr
109-
- fullname: William Polk
110-
- fullname: Miles Smid
106+
-
107+
initials: E.B.
108+
surname: Barker
109+
fullname: Elaine Barker
110+
-
111+
initials: W.B.
112+
surname: Barker
113+
fullname: William Barker
114+
-
115+
initials: W.B.
116+
surname: Burr
117+
fullname: William Burr
118+
-
119+
initials: W.P.
120+
surname: Polk
121+
fullname: William Polk
122+
-
123+
initials: M.S.
124+
surname: Smid
125+
fullname: Miles Smid
111126
OPENSSL-X509-CERT-EXAMPLES:
112127
title: OpenSSL - X509 certificate examples for testing and verification
113128
target: http://fm4dd.com/openssl/certexamples.htm
@@ -859,21 +874,34 @@ While [RFC6920](#RFC6920) allows for truncated hashes, implementations using the
859874

860875
### Parameter: Fingerprint Type (fpt)
861876

862-
The type parameter indicates the type of condition that is represented by the URI. The value MUST be one of the names from the [Crypto-Condition Type Registry](#crypto-conditions-type-registry).
877+
The `type` parameter indicates the type of condition that is represented by the URI. The value MUST be one of the names from the [Crypto-Condition Type Registry](#crypto-conditions-type-registry).
863878

864879
### Parameter: Cost (cost)
865880

866881
The cost parameter is the cost of the condition that is represented by the URI.
867882

868883
### Parameter: Subtypes (subtypes)
869884

870-
The subtypes parameter indicates the types of conditions that are subtypes of the condition represented by the URI. The value MUST be a comma seperated list of names from the [Crypto-Condition Type Registry](#crypto-conditions-type-registry).
885+
The subtypes parameter indicates the types of conditions that are subtypes of the condition represented by the URI. The value MUST be a comma-separated list of names from the [Crypto-Condition Type Registry](#crypto-conditions-type-registry).
871886

872-
The list MUST exclude the type of the root crypto-condition. i.e. The value of the fpt parameter should not appear in the list of types provided as the value of the subtypes parameter.
887+
The subtypes list MUST exclude the type of the root crypto-condition. Specifically, the value of the `fpt` parameter should not appear in the list of subtypes.
873888

874-
The list MUST be ordered by the type id value of each type, in ascending order. i.e. preimage-sha-256 MUST appear before prefix-sha-256.
889+
For example, if a threshold condition contains another threshold condition as well as a prefix condition, then its URI query parameters would appear like this:
875890

876-
The commas in the list should be treated as reserved characters per [RFC3986](#RFC3986)and not be percent encoded when used as list delimiters in the subtypes parameter.
891+
ni:///...?cost=30&fpt=threshold-sha-256&subtypes=prefix-sha-256
892+
893+
Notice that the `subtypes` parameter does not contain `threshold-sha-256` because that type is already indicated in the `fpt` parameter.
894+
895+
The commas in the list should be treated as reserved characters per [RFC3986](#RFC3986) and MUST not be percent encoded when used as list delimiters in the subtypes parameter.
896+
897+
#### Subtype Parameter Value Ordering
898+
899+
The subtypes list MUST be ordered by the type id value of each type, in ascending lexicographical order. That is, `preimage-sha-256` MUST appear before `prefix-sha-256`, which MUST appear before `threshold-sha-256`, and so on.
900+
901+
## Condition URI Parameter Ordering
902+
903+
The parameters of a condition URI MUST appear in ascending lexicographical order based upon the
904+
name of each parameter. For example, the `cost` parameter must appear before the `fpt` parameter, which must appear before the `subtypes` parameter.
877905

878906
# Example Condition
879907

0 commit comments

Comments
 (0)