Allow creation and verification for a specified time · Issue #50 · auth0/java-jwt · GitHub
Skip to content

Allow creation and verification for a specified time #50

Description

@chadjaros

Unit testing classes with expiring tokens with this library is difficult because it is tied to System.currentTimeMillis() in multiple places. I use JodaTime, which has a number of features which make unit testing easier, including freezing the joda clock at a specified time. I would like to inject the time for iat/exp on creation, and for verifying exp, such that it can be made to work with this Joda functionality.

I am already setting iat/exp manually to leverage this feature, but it doesn't seem possible to do so for verification at this time.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions