Skip to content

Commit 0b9fbe1

Browse files
feat: directed identity (#26)
Co-authored-by: Radu-Cristian Popa <praducristian@gmail.com>
1 parent c1de330 commit 0b9fbe1

4 files changed

Lines changed: 91 additions & 6 deletions

File tree

VERSION

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
1.2.0
1+
1.3.0

openapi/auth-server.yaml

Lines changed: 88 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
openapi: 3.1.0
22
info:
33
title: Open Payments Authorization Server
4-
version: '1.2.0'
4+
version: '1.3.0'
55
license:
66
name: Apache 2.0
77
identifier: Apache-2.0
@@ -164,6 +164,23 @@ paths:
164164
- read
165165
identifier: 'http://ilp.interledger-test.dev/bob'
166166
client: 'https://webmonize.com/.well-known/pay'
167+
Grant request with directed identity (JWK):
168+
value:
169+
access_token:
170+
access:
171+
- type: incoming-payment
172+
actions:
173+
- create
174+
- read
175+
identifier: 'http://ilp.interledger-test.dev/bob'
176+
client:
177+
jwk:
178+
kid: example-key-1
179+
alg: EdDSA
180+
use: sig
181+
kty: OKP
182+
crv: Ed25519
183+
x: 11qYAYKxCrfVS_7TyWQHOg7hcvPapiMlrwIaaPcHURo
167184
Grant request for subject information:
168185
value:
169186
subject:
@@ -565,15 +582,41 @@ components:
565582
additionalProperties: false
566583
client:
567584
title: client
568-
type: string
569585
description: |-
570-
Wallet address of the client instance that is making this request.
586+
Client identification for grant requests.
571587
572588
When sending a non-continuation request to the AS, the client instance MUST identify itself by including the client field of the request and by signing the request.
573589
590+
Can be either:
591+
- A wallet address string (backwards compatible format)
592+
- An object with either `jwk` (for directed identity) or `walletAddress` (mutually exclusive)
593+
594+
When using a wallet address string or the `walletAddress` property:
574595
A JSON Web Key Set document, including the public key that the client instance will use to protect this request and any continuation requests at the AS and any user-facing information about the client instance used in interactions, MUST be available at the wallet address + `/jwks.json` url.
575596
597+
When using the `jwk` property (directed identity approach):
598+
The client instance provides its public key directly in the request, eliminating the need for the AS to fetch it from a wallet address. This approach enhances privacy by not requiring the client to expose a persistent wallet address identifier. The `jwk` property can only be used for non-interactive grant requests (i.e.: incoming payments).
599+
576600
If sending a grant initiation request that requires RO interaction, the wallet address MUST serve necessary client display information.
601+
oneOf:
602+
- type: string
603+
format: uri
604+
description: 'DEPRECATED: This string format of the client wallet address is maintained only for backwards compatibility. Migrate to the object form with `jwk` or `walletAddress`.'
605+
deprecated: true
606+
- type: object
607+
required: [walletAddress]
608+
properties:
609+
walletAddress:
610+
type: string
611+
format: uri
612+
description: Wallet address of the client instance that is making this request.
613+
additionalProperties: false
614+
- type: object
615+
required: [jwk]
616+
properties:
617+
jwk:
618+
$ref: '#/components/schemas/json-web-key'
619+
additionalProperties: false
577620
continue:
578621
title: continue
579622
type: object
@@ -783,6 +826,48 @@ components:
783826
maxItems: 1
784827
required:
785828
- sub_ids
829+
json-web-key:
830+
type: object
831+
properties:
832+
kid:
833+
type: string
834+
alg:
835+
type: string
836+
description: 'The cryptographic algorithm family used with the key. The only allowed value is `EdDSA`. '
837+
enum:
838+
- EdDSA
839+
use:
840+
type: string
841+
enum:
842+
- sig
843+
kty:
844+
type: string
845+
enum:
846+
- OKP
847+
crv:
848+
description: 'The cryptographic curve used with the key. This parameter identifies the elliptic curve (for EC keys) or the Edwards curve (for OKP keys). The only allowed value is `Ed25519`.'
849+
type: string
850+
enum:
851+
- Ed25519
852+
x:
853+
type: string
854+
pattern: '^[a-zA-Z0-9-_]+$'
855+
description: The base64 url-encoded public key.
856+
required:
857+
- kid
858+
- alg
859+
- kty
860+
- crv
861+
- x
862+
title: Ed25519 Public Key
863+
description: A JWK representation of an Ed25519 Public Key
864+
examples:
865+
- kid: key-1
866+
alg: EdDSA
867+
use: sig
868+
kty: OKP
869+
crv: Ed25519
870+
x: 11qYAYKxCrfVS_7TyWQHOg7hcvPapiMlrwIaaPcHURo
786871
securitySchemes:
787872
GNAP:
788873
name: Authorization

openapi/resource-server.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
openapi: 3.1.0
22
info:
33
title: Open Payments
4-
version: '1.2.0'
4+
version: '1.3.0'
55
license:
66
name: Apache 2.0
77
identifier: Apache-2.0

openapi/wallet-address-server.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
openapi: 3.1.0
22
info:
33
title: Wallet Address API
4-
version: '1.2.0'
4+
version: '1.3.0'
55
license:
66
name: Apache 2.0
77
identifier: Apache-2.0

0 commit comments

Comments
 (0)