Skip to content

Commit

Permalink
Subtyping and values
Browse files Browse the repository at this point in the history
  • Loading branch information
expede committed Oct 18, 2023
1 parent af08657 commit a9cdb33
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 43 deletions.
49 changes: 6 additions & 43 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -181,7 +181,7 @@ A revocation store MUST keep UCAN revocations for UCANs that are otherwise still

# 3 Expiry

FIXME Note on expiry
Revocations MUST NOT expire. If a Revocation was issued in error,

# 4 Action

Expand All @@ -201,10 +201,10 @@ Note that per [UCAN Invocation], the `nnc` field SHOULD is set to `""` since rev

Being expressed as an Invocation means that Revocations MUST define an Action type for the command `ucan/revoke`.

| Field | Type | Required | Description |
|-------|-----------------|----------|---------------------------------------------------------------------------------------|
| `rev` | `&Delegation` | Yes | The [UCAN Delegation] that is being revoked |
| `pth` | `[&Delegation]` | No | [Proof of delegation path] from a delegation by the Revoker to the revoked Delegation |
| Field | Type | Required | Description |
|-------|-----------------|----------|--------------------------------------------------------------------------|
| `rev` | `&Delegation` | Yes | The [UCAN Delegation] that is being revoked |
| `pth` | `[&Delegation]` | No | [A delegation path] that includes the Revoker and the revoked Delegation |

### 4.1.1 Revoked Delegation

Expand All @@ -223,44 +223,7 @@ flowchart LR

Mallory is not in the delegation chain of Erin. This is fine, since the semantics of revocation merely state that she would assert that no delegation of hers may be used in the `prf` field of an Invocation if it also includes the `rev` Delegation. However, issuing spurious Revocations and requiring them to be stored is a potential DoS vector. Executors MAY require a delegation path witness be included to avoid this situaton.

Unlike Mallory, Bob, Carol, and Dan can both provide valid delegation paths that include Delegations that they have issued. Bob has two paths (`Bob -> Dan -> Erin` or `Bob -> Carol -> Erin`), but either will suffice.



















Revocations MAY be gossiped between systems. As such, they need to be parsable by a wide number of languages and contexts. To accommodate this, compliant UCAN revocations MUST be JSON-encoded.

















Unlike Mallory, Bob, Carol, and Dan can both provide valid delegation paths that include Delegations that they have issued. Bob has two paths (`Alice -> Bob -> Dan -> Erin` or `Alice -> Bob -> Carol -> Erin`), and either will suffice.

# 5 Prior Art

Expand Down
10 changes: 10 additions & 0 deletions revocation.ipldsch
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
type RevocationAction <: Action {
cmd "ucan/revoke"
nnc ""
arg RevocationArguments
}

type RevocationArguments struct {
rev &Delegation
pth [&Delegation]
}

0 comments on commit a9cdb33

Please sign in to comment.