-
Notifications
You must be signed in to change notification settings - Fork 18
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
Should we support non DID principals ? #139
Comments
Yes, strongly support. I was having a very similar thought last night (I think prompted by @gobengo's comments about did-percent-encoding) and was getting close to writing up that we'd need a "canonical-form" for the issuer encoded in the UCAN in order to make NNS & WhoCANs work. The encoding of that would be exactly the same as you've just proposed: "mailto:", "https://", "acct:", etc. A conversation with Brooke yesterday also provided some clarifying detail on where this might be useful: UCANs, with did:key issuers (principals?), are capabilities. (let me know if that makes sense / needs tweaks / doesn't make sense!) I don't know / have an opinion on the best way to encode this in the UCAN, but I support the approach in principle. |
It's a good question, and has come up a few times! I'm not dead set against opening principals to being any URI, or alternately limiting them to public keys only (people have argued for both).
I'm not aware of anything in the DID spec that prevents Arbitrary URIs also open up the potential for confused deputies, since (e.g.) multiple verification methods on a single URI scheme mean that it's much easier to spoof the root of trust. We would need to define some new methods for signalling verification. I have the intuition that this puts us on a path to writing a parallel spec to DID that covers a lot of the same ground, but haven't explored it deeply.
UCAN principals can absolutely be one of a set of keys today! We did a proof of concept with ION a couple years back and it worked well (other than the fact that not being self-attesting imposed additional latency and liveness constraints that we're hoping to avoid in a lot of our current work).
Yup absolutely 💯 These are slightly different layers: authN vs authZ. We sadly can't get away from authN completely (at least AFAIK), but you're absolutely right that we try to minimize it in UCAN as much as possible |
You are correct that DID spec does not explicitly calls out "single source of truth", yet most of the spec seems to be written in a way that expect that to be the case. That is not to say we can't define a method that goes about it differently, it's just I'm not sure if benefits of doing it outweigh the tradeoffs.
I'm not sure I entirely follow this. My expectation was that spec defines how to verify UCANs issued by I realize there is some overlap with DID spec, yet I often find that most of the DID spec is irrelevant in UCAN context as you really just need a way to verify that issuer authorized specific UCAN delegation / invocation. Let me try and make it more concrete in case of UCAN mailto.
To accomplish this we need to:
Even if we do all that we still have some problems:
Lets take a step back here. All I wanted to do is redelegate capability from my email address to some DID but instead I had to create intermediate did:key send an email proving I own it and then creating a delegation UCAN that I can sign with that key. And if that new key gets compromised I'm in trouble because I don't have a way to revoke the DKIM fact. I think things could be both simpler and better if instead
The best part is we don't even need a way to resolve key for This way deputy just needs to generate payload for UCAN per usual, ensure that it matches subject in the DKIM header and verify DKIM signature. Not only we completely sidestep the whole DID documents and keys and resolution we also retained all of the missing functionality from UCANs like time bounds and revocations. We also don't have translate email address into idiosyncratic format just to make them DIDs.
This is what spec says today, which tells me that I could sign some UCAN today with my did:web today which may become invalid because I've added another key to the document. Again not end of the world, just another case of incidental complexity. Line 361 in 692e8aa
|
Right now UCAN spec requires that principals be identified by DID URIs, which in turn motivated me to start defining did:mailto method so that we could use email principals.
Unfortunately DIDs even though decentralized are in fact logically centralized (perhaps that's why most methods are blockchain based) which seems to be at odds with (our) desired uses in UCANs. Specifically with did:mailto there is no desire to have canonical set of keys associated with that identifier, on the contrary we want an evidence inside the UCAN chain that specific
did:key
has been authorized to invoke certain capabilities on behalf of specificmailto:
principal. We also several other things that DIDs do not address while UCANs do:DIDs require you to resolve canonical state and make it complicated to embed that state into UCAN instead.
There is also whole another thing with DID been set of keys, while UCAN principals been a specific key instead.
As a side effect mentioning did:mailto to people inspires questions about how one resolves the key(s) ? And even if you do resolve it which one has an authority to invoke which capabilities (If you call out key ids with fragment identifier in UCAN delegations you wind up having to introduce interior mutability, which is another 🥫🪱).
This got me wondering if it would be a better idea to relax a spec and allow principals to be an arbitrary URIs. That way we could define ucan-mailto spec without having to define did:mailto spec and avoid whole logical centralization. E.g. ucan-mailto could define how to represent
mailto: -> did:key
delegation without implying that the key is somehow associated with that email address.The text was updated successfully, but these errors were encountered: