Skip to content
This repository was archived by the owner on Apr 13, 2022. It is now read-only.

Commit 934f877

Browse files
jaxoncreeddmitrizagidulin
authored andcommitted
PoP tokens documentation
1 parent 2b2c5a3 commit 934f877

File tree

2 files changed

+22
-2
lines changed

2 files changed

+22
-2
lines changed

README.md

Lines changed: 21 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ See also: [Motivation for WebID-OIDC](motivation.md).
4343
### Benefits and Capabilities
4444

4545
* Fully decentralized cross-domain authentication (any peer node can serve as
46-
an identity provider as well as a relying party to any other node)
46+
an identity provider as well as a relying party to any other node) made possible by [PoP Tokens](https://tools.ietf.org/html/rfc7800).
4747
* Builds on decades of real-world authentication industry experience
4848
* Incorporates lessons from, and fixes to threat models of: SAML, OpenID and
4949
OpenID 2, OAuth and OAuth 2. See, for example, [RFC 6819 - OAuth 2.0 Threat
@@ -99,6 +99,8 @@ WebID-OIDC makes the following changes to the base OpenID Connect protocol
9999
* Specifies the [Authorized OIDC Issuer
100100
Discovery](#authorized-oidc-issuer-discovery) process (used as part of
101101
Provider Confirmation, and during Provider Selection steps).
102+
* Utilizes [PoP tokens](https://tools.ietf.org/html/rfc7800) to securely
103+
query a wide array of resource providers.
102104

103105
It's also worth mentioning that while traditional OpenID Connect use cases are
104106
concerned with retrieving user-related claims from [UserInfo
@@ -304,6 +306,24 @@ that profile, she would add the following triple to her profile:
304306
<#me> solid:oidcIssuer <https://provider.com> .
305307
```
306308

309+
## Securing tokens for multiple resource providers
310+
311+
#### The Problem
312+
313+
Unlike standard implementations of OIDC, WebID-OIDC must deal with a number of RPs many of which the OP will not know about. OIDC defines the `aud` claim which defines the RPs for which a token can be used.
314+
315+
However, given Solid's use case, a token should be usable for any RP so the user may federate a query across multiple Pods, so the `aud`ience cannot be constrained. Yet, an unconstrained `aud`ience opens up the possibility of token stealing. In this case, a user sends a request to `evilPod.example`. The Pod returns the requested information, but now has the user's token and may pretend to be the user on any other Pod in the world.
316+
317+
#### The Solution
318+
319+
The solution employs [Proof of Possession (PoP) tokens](https://tools.ietf.org/html/rfc7800) changing the way the Bearer token is constructed:
320+
321+
1. A client application generates a public and private key.
322+
2. The client generates a request `JWT` just as it would under normal OIDC with the addition of a `key` field containing the public key.
323+
3. Authentication proceeds normally and yeilds a signed `id_token` where the `aud`ience is the client application (represented by the `origin` of the provided `redirect_uri`) and an additional field `cnf` is provided containing the client's public key.
324+
4. Before sending requests to any RPs, the client generates a new signed JWT PoP token containing the RP's uri as the `aud`ience and an `id_token` feild containing the `id_token` provided by the OP.
325+
5. When an RP receives the PoP token, it MUST reject any tokens containing a mismatched audience or a signature that is not associated with the public key in the `cnf` claim.
326+
307327
## Detailed Sign In Workflow Example
308328

309329
To walk through a more detailed example for WebID-OIDC login, refer to the

example-workflow.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -110,7 +110,7 @@ browser cookie), so that the user can skip Step 3 in subsequent interactions
110110
(until the session expires or the user signs out).
111111

112112
### 4. User Consent
113-
User consent screen ("Do you want to sign in to www.example.com?" etc).
113+
User consent screen ("Do you want to give www.example.com access to your Pod?" etc).
114114

115115
*Example 1:* `alice.example`, in the Provider role, presents Alice with a User
116116
Consent screen that says something like "Do you want to sign in to bob.example?",

0 commit comments

Comments
 (0)