@libid/contracts 0.11.0 → 0.13.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -7,16 +7,15 @@
7
7
  * THESE STRINGS ARE OURS, NOT THE SPECIFICATION'S. ceremony-common fixes no
8
8
  * literal of its own: platform-ceremonies REQ-PLAT-01 fixes the profile
9
9
  * NAMES, and every byte below is the profile author's choice. So this is a
10
- * cross-implementation agreement, and it is agreed here rather than four
10
+ * cross-implementation agreement, and it is agreed here rather than three
11
11
  * times over.
12
12
  *
13
- * Four components must produce the same bytes: this repository's verifiers,
14
- * the browser that notarizes three of the four sessions, the deployment that
15
- * notarizes the fourth, and the notary that signs what they observed. A
16
- * disagreement is silent -- a Consumer dispatching on one string and a
17
- * verifier registered under another simply never meet, and a request line a
18
- * prover composes one byte differently is an attestation rejected with no
19
- * error that says why.
13
+ * Three components must produce the same bytes: this repository's verifiers,
14
+ * the browser that notarizes all four sessions, and the notary that signs
15
+ * what it observed. A disagreement is silent -- a Consumer dispatching on one
16
+ * string and a verifier registered under another simply never meet, and a
17
+ * request line a prover composes one byte differently is an attestation
18
+ * rejected with no error that says why.
20
19
  *
21
20
  * Changing a value here changes what a deployed verifier accepts. That is a
22
21
  * new ceremonyVersion, not an edit.
@@ -33,13 +32,18 @@ export interface Session {
33
32
  }
34
33
  export interface TokenSession {
35
34
  readonly session: Session;
36
- /** The body field committed rather than revealed, or null. */
37
- readonly secretField: string | null;
38
35
  /** The header lines a Platform Verifier requires, each exactly once with
39
36
  * its value: `host` and `content-type`. Every other header is the
40
37
  * runtime's own, save the names `FORBIDDEN_REQUEST_HEADERS` lists.
41
38
  * `content-length` is absent: the HTTP client appends it. */
42
39
  readonly requiredHeaders: readonly string[];
40
+ /** The form fields the body carries, in the order the prover serializes
41
+ * them. Every verifier holds the whole body to this list: exactly these
42
+ * names in this order, each once with a nonempty value, nothing after
43
+ * the last. GitHub's list is REQ-PLAT-61's; X's specification keeps its
44
+ * decoded form on ASM-PROV-07, so the contract is stricter than the
45
+ * specification there. */
46
+ readonly tokenFields: readonly string[];
43
47
  }
44
48
  export interface IdentitySession {
45
49
  readonly session: Session;
@@ -66,10 +70,10 @@ export declare const GOOGLE: Profile;
66
70
  */
67
71
  export declare const X: Profile;
68
72
  /**
69
- * A confidential client. The exchange runs in the deployment because the
70
- * secret cannot reach the browser, and the two sessions are served by
71
- * DIFFERENT hosts -- which is why one pinned authority per profile would
72
- * be wrong.
73
+ * The credential GitHub calls `client_secret` is sent and revealed, so
74
+ * an attestation publishes it and nothing here is confidential. The two
75
+ * sessions are served by DIFFERENT hosts -- which is why one pinned
76
+ * authority per profile would be wrong.
73
77
  */
74
78
  export declare const GITHUB: Profile;
75
79
  /** The closed launch list. */
@@ -1 +1 @@
1
- {"version":3,"file":"profiles.d.ts","sourceRoot":"","sources":["../../src/ceremony/profiles.ts"],"names":[],"mappings":"AAGA;;;;;;;;;;;;;;;;;;;;;;GAsBG;AAEH,2EAA2E;AAC3E,MAAM,MAAM,OAAO,GAAG,YAAY,GAAG,aAAa,CAAA;AAElD,MAAM,WAAW,OAAO;IACtB,8DAA8D;IAC9D,QAAQ,CAAC,SAAS,EAAE,MAAM,CAAA;IAC1B,QAAQ,CAAC,MAAM,EAAE,MAAM,CAAA;IACvB,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAA;IACrB,mEAAmE;IACnE,QAAQ,CAAC,WAAW,EAAE,MAAM,CAAA;CAC7B;AAED,MAAM,WAAW,YAAY;IAC3B,QAAQ,CAAC,OAAO,EAAE,OAAO,CAAA;IACzB,8DAA8D;IAC9D,QAAQ,CAAC,WAAW,EAAE,MAAM,GAAG,IAAI,CAAA;IACnC;;;iEAG6D;IAC7D,QAAQ,CAAC,eAAe,EAAE,SAAS,MAAM,EAAE,CAAA;CAC5C;AAED,MAAM,WAAW,eAAe;IAC9B,QAAQ,CAAC,OAAO,EAAE,OAAO,CAAA;IACzB,QAAQ,CAAC,OAAO,EAAE,MAAM,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AAG,MAAM,CAEzD;AAED;;;;;;;;;;;;;;GAcG;AACH,eAAO,MAAM,yBAAyB,EAAE,SAAS,MAAM,EAQtD,CAAA;AAED,sDAAsD;AACtD,eAAO,MAAM,mCAAmC,MAAM,CAAA;AACtD,eAAO,MAAM,wBAAwB,OAAO,CAAA;AAC5C,eAAO,MAAM,6BAA6B,OAAO,CAAA"}
@@ -25,8 +25,8 @@ export const X = {
25
25
  path: '/2/oauth2/token',
26
26
  requestLine: 'POST /2/oauth2/token ',
27
27
  },
28
- secretField: null,
29
28
  requiredHeaders: ['host: api.x.com', 'content-type: application/x-www-form-urlencoded'],
29
+ tokenFields: ['grant_type', 'client_id', 'code', 'redirect_uri', 'code_verifier'],
30
30
  },
31
31
  identity: {
32
32
  session: {
@@ -41,10 +41,10 @@ export const X = {
41
41
  },
42
42
  };
43
43
  /**
44
- * A confidential client. The exchange runs in the deployment because the
45
- * secret cannot reach the browser, and the two sessions are served by
46
- * DIFFERENT hosts -- which is why one pinned authority per profile would
47
- * be wrong.
44
+ * The credential GitHub calls `client_secret` is sent and revealed, so
45
+ * an attestation publishes it and nothing here is confidential. The two
46
+ * sessions are served by DIFFERENT hosts -- which is why one pinned
47
+ * authority per profile would be wrong.
48
48
  */
49
49
  export const GITHUB = {
50
50
  platform: 'github',
@@ -56,8 +56,8 @@ export const GITHUB = {
56
56
  path: '/login/oauth/access_token',
57
57
  requestLine: 'POST /login/oauth/access_token ',
58
58
  },
59
- secretField: 'client_secret',
60
59
  requiredHeaders: ['host: github.com', 'content-type: application/x-www-form-urlencoded'],
60
+ tokenFields: ['client_id', 'code', 'redirect_uri', 'code_verifier', 'client_secret'],
61
61
  },
62
62
  identity: {
63
63
  session: {
@@ -1 +1 @@
1
- {"version":3,"file":"profiles.js","sourceRoot":"","sources":["../../src/ceremony/profiles.ts"],"names":[],"mappings":"AAAA,gEAAgE;AAChE,oEAAoE;AAgEpE;;;;GAIG;AACH,MAAM,CAAC,MAAM,MAAM,GAAY;IAC7B,Q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OAAO,MAAM,CAAC,IAAI,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,QAAQ,KAAK,QAAQ,CAAC,CAAA;AACpD,CAAC;AAED,mEAAmE;AACnE,MAAM,UAAU,gBAAgB,CAAC,OAAgB;IAC/C,OAAO,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,OAAO,CAAC,QAAQ,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAA;AAC7D,CAAC;AAED;;;;;;;;;;;;;;GAcG;AACH,MAAM,CAAC,MAAM,yBAAyB,GAAsB;IAC1D,eAAe;IACf,kBAAkB;IAClB,QAAQ;IACR,mBAAmB;IACnB,eAAe;IACf,wBAAwB;IACxB,mBAAmB;CACpB,CAAA;AAED,sDAAsD;AACtD,MAAM,CAAC,MAAM,mCAAmC,GAAG,GAAG,CAAA;AACtD,MAAM,CAAC,MAAM,wBAAwB,GAAG,IAAI,CAAA;AAC5C,MAAM,CAAC,MAAM,6BAA6B,GAAG,IAAI,CAAA"}
package/package.json CHANGED
@@ -1,11 +1,11 @@
1
1
  {
2
2
  "name": "@libid/contracts",
3
- "version": "0.11.0",
3
+ "version": "0.13.0",
4
4
  "description": "Typed viem-ready ABIs and call builders for the libid contracts, plus the identity helper layer (handle normalization, name resolution).",
5
5
  "license": "(MIT OR Apache-2.0)",
6
6
  "repository": {
7
7
  "type": "git",
8
- "url": "git+https://github.com/libid-org/libid-contracts.git",
8
+ "url": "git+https://github.com/libid-org/libID-contracts.git",
9
9
  "directory": "ts/packages/contracts"
10
10
  },
11
11
  "type": "module",
@@ -10,16 +10,15 @@
10
10
  * THESE STRINGS ARE OURS, NOT THE SPECIFICATION'S. ceremony-common fixes no
11
11
  * literal of its own: platform-ceremonies REQ-PLAT-01 fixes the profile
12
12
  * NAMES, and every byte below is the profile author's choice. So this is a
13
- * cross-implementation agreement, and it is agreed here rather than four
13
+ * cross-implementation agreement, and it is agreed here rather than three
14
14
  * times over.
15
15
  *
16
- * Four components must produce the same bytes: this repository's verifiers,
17
- * the browser that notarizes three of the four sessions, the deployment that
18
- * notarizes the fourth, and the notary that signs what they observed. A
19
- * disagreement is silent -- a Consumer dispatching on one string and a
20
- * verifier registered under another simply never meet, and a request line a
21
- * prover composes one byte differently is an attestation rejected with no
22
- * error that says why.
16
+ * Three components must produce the same bytes: this repository's verifiers,
17
+ * the browser that notarizes all four sessions, and the notary that signs
18
+ * what it observed. A disagreement is silent -- a Consumer dispatching on one
19
+ * string and a verifier registered under another simply never meet, and a
20
+ * request line a prover composes one byte differently is an attestation
21
+ * rejected with no error that says why.
23
22
  *
24
23
  * Changing a value here changes what a deployed verifier accepts. That is a
25
24
  * new ceremonyVersion, not an edit.
@@ -39,13 +38,18 @@ export interface Session {
39
38
 
40
39
  export interface TokenSession {
41
40
  readonly session: Session
42
- /** The body field committed rather than revealed, or null. */
43
- readonly secretField: string | null
44
41
  /** The header lines a Platform Verifier requires, each exactly once with
45
42
  * its value: `host` and `content-type`. Every other header is the
46
43
  * runtime's own, save the names `FORBIDDEN_REQUEST_HEADERS` lists.
47
44
  * `content-length` is absent: the HTTP client appends it. */
48
45
  readonly requiredHeaders: readonly string[]
46
+ /** The form fields the body carries, in the order the prover serializes
47
+ * them. Every verifier holds the whole body to this list: exactly these
48
+ * names in this order, each once with a nonempty value, nothing after
49
+ * the last. GitHub's list is REQ-PLAT-61's; X's specification keeps its
50
+ * decoded form on ASM-PROV-07, so the contract is stricter than the
51
+ * specification there. */
52
+ readonly tokenFields: readonly string[]
49
53
  }
50
54
 
51
55
  export interface IdentitySession {
@@ -89,8 +93,8 @@ export const X: Profile = {
89
93
  path: '/2/oauth2/token',
90
94
  requestLine: 'POST /2/oauth2/token ',
91
95
  },
92
- secretField: null,
93
96
  requiredHeaders: ['host: api.x.com', 'content-type: application/x-www-form-urlencoded'],
97
+ tokenFields: ['grant_type', 'client_id', 'code', 'redirect_uri', 'code_verifier'],
94
98
  },
95
99
  identity: {
96
100
  session: {
@@ -106,10 +110,10 @@ export const X: Profile = {
106
110
  }
107
111
 
108
112
  /**
109
- * A confidential client. The exchange runs in the deployment because the
110
- * secret cannot reach the browser, and the two sessions are served by
111
- * DIFFERENT hosts -- which is why one pinned authority per profile would
112
- * be wrong.
113
+ * The credential GitHub calls `client_secret` is sent and revealed, so
114
+ * an attestation publishes it and nothing here is confidential. The two
115
+ * sessions are served by DIFFERENT hosts -- which is why one pinned
116
+ * authority per profile would be wrong.
113
117
  */
114
118
  export const GITHUB: Profile = {
115
119
  platform: 'github',
@@ -121,8 +125,8 @@ export const GITHUB: Profile = {
121
125
  path: '/login/oauth/access_token',
122
126
  requestLine: 'POST /login/oauth/access_token ',
123
127
  },
124
- secretField: 'client_secret',
125
128
  requiredHeaders: ['host: github.com', 'content-type: application/x-www-form-urlencoded'],
129
+ tokenFields: ['client_id', 'code', 'redirect_uri', 'code_verifier', 'client_secret'],
126
130
  },
127
131
  identity: {
128
132
  session: {