You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Thanks @dewyatt for the explanation. The valid range isn't clear from the Ruby documentation since the class is Integer. I found the relevant bit in the RFC (4-octet time field) which perhaps would supplement the rubydoc well.
Maybe it's also good to make the error message clearer by saying specifically which field is invalid?
Honestly I'd really like to change all these "expiration" parameters to something else, like validity_seconds or lifetime_sec, or something more intuitive. The RFC uses "expiration time" quite a bit in ways I find misleading.
@dewyatt I was going to suggest renaming expiration_time to expiration_duration but I think your suggestions of validity_seconds and lifetime_sec are better as they're more explicit.
So it would emit errors like RangeError: validity_seconds beyond 4294967295 is unsupported by RFC4880.
Description
Key expiration time doesn't accept times beyond 2106-02-07 06:28:15 UTC
(
== Time.at(('1' * 32).to_i(2))
).A
RangeError
would be thrown.Steps to reproduce
This would be fine:
This would fail:
Expected results
It would either happily consume it or emit an error that is more meaningful,
e.g.
RangeError: expiration time beyond 4294967295 is unsupported
.The text was updated successfully, but these errors were encountered: