spec
spec copied to clipboard
Expiry field is required but may be set to null
According to the spec, Expiry field is required but may be set to null to convey "never expires".
Are there reasons to have the field set to null vs having it absent (optional)?
There are several reasons to prefer having it optional:
- Adheres to the JWT spec
- Makes for a uniform way of conveying absence, as it is for
nbf& other fields. - Makes for a more sound absence semantic, this great talk gives a fine mindset for it
Are there reasons to have the field set to
nullvs having it absent (optional)?
Intention had been to have an explicit signal and catch malformed UCANs that accidentally omitted this field.
Yeah, an expiry was required (arguably it still should be, though there are hacks around that). Ergonomically, making this field required means that people have to at least think about POLA.