Skip to content

Conversation

pinkisemils
Copy link

On macOS, time::Instant::now() - time::Duration::from_secs(86400) would panic due to an underflow if the machine was running for less than 24 hours. This of course is not ideal, as that expression is used to initialize the cookie validator. I've worked around this by making the birth of the secret optional, and just assume that a secret without a birthday is invalid. This could also be changed to have the secret itself be optional.

@pinkisemils pinkisemils changed the title Fix time::Instant in handshake Fix time::Instant underflow in handshake Apr 28, 2021
@pinkisemils pinkisemils force-pushed the fix-validator-underflow branch from 5a906fa to fb943cb Compare May 11, 2021 00:02
@pinkisemils pinkisemils force-pushed the fix-validator-underflow branch from fb943cb to f171579 Compare May 11, 2021 00:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

1 participant