-
Notifications
You must be signed in to change notification settings - Fork 22
Description
I ran into couple of issues when exercising integration with invocation spec in rs-ucan that could use some clarification or revision on fixtures
-
Order of proofs in the invocation assumes
invoker <- subjectwhere's at some implementations seem to assumesubject → invoker. In my current workstream I'm basically resorting to accepting either order, but it would be nice to have spec and test vectors align. -
Some of the invocation fixtures error with
UnauthorizedSubjectin rs-ucan instead of expectedExpired/TooEarlyerrors. Specifically, "expired proof", "inactive proof" and "expired invocation". That is because proof authorizes subdid:key:z6MkmT9j...but then invocation claims subdid:key:z6MkmJce...which is misaligned.I think if subs were aligned rs-ucan would also fail on time bounds, it's just we asses subject alignment earlier. Either way I think fixing fixtures so subs align would be a good idea.
-
I think invocation fixtures should also include time field denoting time of validation, otherwise things that are too early eventually may become not anymore early. Less likely to see same for already expired ones. Either way I think it's a good idea to to have time captured so test can be deterministic and don't have time variable in them.