Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Clarify which issuers are implicitly trusted. #52

Closed
wants to merge 1 commit into from

Conversation

RubenVerborgh
Copy link

Fixes #51

@RubenVerborgh RubenVerborgh added the bug Something isn't working label Oct 25, 2021
@@ -350,7 +350,7 @@ With the `webid` scope, the DPoP-bound Access Token payload MUST contain these c

<pre highlight="json">
{
"webid": "https://janedoe.com/web#id",
"webid": "https://jane.doe.example/web#id",
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Changed in order to have subdomain examples below


Unless the RS acquires IdP keys through some other means, or the RS chooses to reject tokens issued by this IdP,
the RS MUST follow OpenID Connect Discovery 1.0 [[!OIDC.Discovery]] to find an IdP's signing keys (JWK).

### WebID Issuer Discovery via Link Headers ### {#webid-issuer-discovery}

A server hosting a WebID document MAY transmit the `http://www.w3.org/ns/solid/terms#oidcIssuer` values via Link Headers but it MUST be the same as in the RDF representation. A client MUST treat the RDF in the body of the WebID document as canonical but MAY use the Link Header values as an optimization.
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I removed this section because it was unclear how this could be enforced.

To me,

A client MUST treat the RDF in the body of the WebID document as canonical

means that the client still has to read the RDF body. So then also checking the header seems pointless.

I.e., I can't think of

MAY use the Link Header values as an optimization

while also enforcing the RDF as canonical.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This can be enforced in cases where a special server understands the issuer claim in a WebID document. A live example of this is at https://id.inrupt.com/acoburn

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There are surely ways to express this more clearly in the specification text. But the point is that this is an optional feature that allows a client to avoid having to download and parse an entire RDF profile document.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Okay; will restore. I think the canonical language is void though. No point in having that if it is not mandatory to check.

This can be enforced in cases where a special server understands the issuer claim in a WebID document. A live example of this is at https://id.inrupt.com/acoburn

I did not understand that one though; how is the enforcement happening? Of do you mean that the server enforces this, not the client? Because the language currently reads that the client should do this.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Updated the language.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Or do you mean that the server enforces this, not the client?

It is a resource server, acting as an HTTP client, that enforces this. The language can certainly be clarified.

@acoburn
Copy link
Member

acoburn commented Oct 25, 2021

In a small organization or deployment where an entire domain space is managed by a single person (or small group) this notion of implicit trust makes a lot of sense. Where this breaks down is in cases where a WebID is hosted in a sub-domain space that is managed separately from the root domain.

For example, if company Foo is deploying Solid in such a way that foo.example is the root domain, managed by one group of administrators and solid.foo.example is managed by a separate group of administrators, it is now possible for that first group of administrators to impersonate any agent with a WebID under solid.foo.example.

Another example is with a large hosting provider: bar.example where the Solid users are given a domain at solid.bar.example. Here, the administrators of solid.bar.example have no knowledge or trust of the administrators who manage the bar.example domain, yet the bar.example administrators would be able to impersonate any solid user without any need to access their credentials.

Copy link
Member

@acoburn acoburn left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would like to see the results of a threat modeling exercise before approving this. This seems to have some significant security aspects that should be considered carefully.

@RubenVerborgh
Copy link
Author

Where this breaks down is in cases where a WebID is hosted in a sub-domain space that is managed separately from the root domain.

Thanks, Aaron. I'm more than happy to drop the subdomain relaxation; I only added it because of #51 (comment)

This seems to have some significant security aspects that should be considered carefully.

Agreed; just want to note that this text is describing existing implementations in the wild, not proposing anything new.

@elf-pavlik
Copy link
Member

We discussed this PR during the panel meeting yesterday.

First of all, we would like to continue the conversation in #51 to see if we could remove implicit trust altogether and always rely on the explicit statement in WebID Document and/or HTTP Link header of the response when requesting WebID.

If in the issuer we decide that we indeed need some form of implicit trust. It shouldn't just match all the subdomains down to TLD. For example, having WebIDs https://jane.doe.example/web#id and https://alice.doe.example/web#id they might have designated https://doe.example/ to an instance of storage. At the same time, they don't intend to use that storage at https://doe.example/ as their OIDC Issuer. The algorithm for matching subdomains proposed in this PR, would give implicit trust to https://doe.example/ and in practice make it impossible to use https://doe.example in a way that doesn't make it a trusted OIDC Issuer.

@elf-pavlik
Copy link
Member

#51 (comment) suggests a way forward, this includes closing this PR without mergning

@elf-pavlik elf-pavlik closed this Feb 16, 2022
@acoburn acoburn deleted the fix/trusted-issuers branch March 29, 2022 20:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Clarify implicitly trusted OIDC issuer
3 participants