Skip to content

Commit d4f7fcb

Browse files
Merge pull request #12 from ietf-wg-privacypass/extnegotiation
Initial draft of extension negotiation
2 parents 02abe19 + 7741b80 commit d4f7fcb

File tree

1 file changed

+59
-9
lines changed

1 file changed

+59
-9
lines changed

Diff for: draft-ietf-privacypass-auth-scheme-extensions.md

+59-9
Original file line numberDiff line numberDiff line change
@@ -37,8 +37,8 @@ informative:
3737

3838
--- abstract
3939

40-
This document specifies a new parameter for the "PrivateToken" HTTP authentication
41-
scheme. This purpose of this parameter is to carry extensions for Privacy Pass
40+
This document specifies new parameters for the "PrivateToken" HTTP authentication
41+
scheme. This purpose of these parameters is to negotiate and carry extensions for Privacy Pass
4242
protocols that support public metadata.
4343

4444
--- middle
@@ -69,11 +69,15 @@ scheme for carrying extensions. This extensions parameter, otherwise referred to
6969
public metadata, is cryptographically bound to the Token structure via the Privacy
7070
Pass issuance protocol.
7171

72+
This document additionally defines an optional extension negotiation scheme which
73+
allows origins to indicate what extension types they expect, and allows clients to
74+
respond with the extensions appropriate for their context.
75+
7276
# Conventions and Definitions
7377

7478
{::boilerplate bcp14-tagged}
7579

76-
# PrivateToken Extensions Parameter
80+
# PrivateToken Extensions Parameter {#extensions}
7781

7882
As defined in {{Section 2.2 of AUTHSCHEME}}, the "PrivateToken" authentication
7983
scheme defines one parameter, "token", which contains the base64url-encoded
@@ -123,17 +127,63 @@ issuance protocol. In particular, the value of an Extensions structure is provid
123127
metadata for the issuance protocol. Candidate issuance protocols are specified in
124128
{{?PUBLIC-ISSUANCE=I-D.hendrickson-privacypass-public-metadata}}.
125129

126-
# Extensions Negotiation {#negotiation}
130+
# PrivateToken Challenge Extension Parameter
131+
132+
As defined in {{Section 2.1 of AUTHSCHEME}}, the "PrivateToken" authentication
133+
scheme defines two parameters, "challenge" which contains the base64url-encoded
134+
TokenChallenge struct, and a "token-key" which contains the base64url-encoded
135+
public key used for this challenge. This document defines two OPTIONAL new parameters,
136+
"extension-set," which contains the base64url-encoded representation of the
137+
following ExtensionSet structure, and "extensions" which contain the base64url-encoded
138+
representation of the Extensions strucuture defined in {#extensions}. This document
139+
follows the default padding behavior described in {{Section 3.2 of !RFC4648}}, so the
140+
base64url value MUST include padding.
141+
142+
~~~
143+
struct {
144+
enum { false(0), true(1) } Bool;
145+
Bool is_required;
146+
ExtensionType extension_type;
147+
} ExtensionEntry;
148+
149+
enum {
150+
reserved(0),
151+
(65535)
152+
} ExtensionType;
153+
154+
struct {
155+
ExtensionEntry extension_types<0..2^16-1>;
156+
} ExtensionSet;
157+
~~~
158+
159+
The contents of ExtensionSet is a list of ExtensionEntry structs containing extensions (defined in #extensions),
160+
each of which is a type-length-value structure whose semantics are determined by the type, and a bit marking whether
161+
the extension is required or optional. T he type and length of each ExtensionType is a 2-octet integer, in network byte order. The
162+
length of the extension_types list is also a 2-octet integer, in network byte order.
163+
164+
ExtensionTypes are to be defined outside of this document.
127165

128-
The mechanism Clients and Origins use to determine which set of extensions to provide
129-
for redemption is out of scope for this document.
166+
The extensions parameter is to be used for pre-populated extension structs the origin suggests
167+
to the client.
168+
169+
When presented with an ExtensionSet, a client should expect to be rejected if not providing required extensions.
170+
A client MAY provide optional extensions. A client MAY use the pre-populated extension
171+
provided by the origin, or craft its own.
172+
173+
~~~
174+
WWW-Authenticate:
175+
PrivateToken challenge="abc...", token-key="123...", extension-set="0x0001,0x0002..." extensions="def..."
176+
~~~
177+
178+
# Extensions Negotiation {#negotiation}
130179

131180
In some Privacy Pass deployments, the set
132181
of extensions may be well known to Clients and Origins and thus do not require negotiation.
182+
In this case, no extension-set or extensions are provided by the origin in the PrivateToken.
133183
In other settings, negotiation may be required. However, negotiation can raise privacy
134-
risks, especially if negotiation can be abused by Origins for partitioning Clients and
135-
risking Origin-Client unlinkability. Some of these risks may be mitigated if all Clients
136-
in a given redemption context respond to negotiation in the same manner. However, if
184+
risks, by partitioning Clients by their chosen provided extensions risking Origin-Client
185+
unlinkability. Some of these risks may be mitigated if all Clients in a given redemption
186+
context respond to negotiation in the same manner. However, if
137187
Clients have different observable behavior, e.g., if certain extension use is determined
138188
by user choice, Origins can observe this differential behavior and therefore partition
139189
Clients in a redemption context.

0 commit comments

Comments
 (0)