Skip to content

decreaseExpirationBySec is being used as miliseconds #1318

Open
@wawyed

Description

@wawyed

Describe the bug
The variable name and documentation imply that this is use as seconds but the comparisons in the code are against milliseconds values.

Use cases:

parseInt(expiresAt, 10) - this.decreaseExpirationBySec <

expiresAtMSec + clockSkewInMSec - this.decreaseExpirationBySec <= now

We either fix the code or documentation. Probably less breaking change to fix the two usages.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions