-
Notifications
You must be signed in to change notification settings - Fork 9
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
add clock skew to ValidAt #100
Conversation
@@ -477,15 +477,22 @@ func TestVerifiableCredential_ValidAt(t *testing.T) { | |||
hhh := time.Date(2001, 0, 0, 0, 0, 0, 0, time.UTC) | |||
|
|||
// no validity period is always true; includes missing IssuanceDate(.IsZero() == true) | |||
assert.True(t, VerifiableCredential{}.ValidAt(time.Now())) | |||
assert.True(t, VerifiableCredential{}.ValidAt(time.Now(), 0)) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
test with non-zero skew?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
(now the argument could just be ignored, who knows)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
added
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It will be ignored, there are no nbf/exp values set. This only validates it is within the valid window for the given values, not if a value is set.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
tests, rest ok
100!