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
Copy file name to clipboardExpand all lines: README.md
+21-2
Original file line number
Diff line number
Diff line change
@@ -28,16 +28,19 @@ encoded private key for RSA and ECDSA.
28
28
29
29
*`algorithm` (default: `HS256`)
30
30
*`expiresIn`: expressed in seconds or an string describing a time span [rauchg/ms](https://github.com/rauchg/ms.js). Eg: `60`, `"2 days"`, `"10h"`, `"7d"`
31
+
*`notBeforeMinutes` or `notBeforeSeconds`
31
32
*`audience`
32
33
*`subject`
33
34
*`issuer`
35
+
*`jwtid`
36
+
*`subject`
34
37
*`noTimestamp`
35
38
*`headers`
36
39
37
40
If `payload` is not a buffer or a string, it will be coerced into a string
38
41
using `JSON.stringify`.
39
42
40
-
If any `expiresIn`, `audience`, `subject`, `issuer` are not provided, there is no default. The jwt generated won't include those properties in the payload.
43
+
If any `expiresIn`, `notBeforeMinutes`, `audience`, `subject`, `issuer` are not provided, there is no default. The jwt generated won't include those properties in the payload.
41
44
42
45
Additional headers can be provided via the `headers` object.
43
46
@@ -77,7 +80,9 @@ encoded public key for RSA and ECDSA.
77
80
*`audience`: if you want to check audience (`aud`), provide a value here
78
81
*`issuer`: if you want to check issuer (`iss`), provide a value here
79
82
*`ignoreExpiration`: if `true` do not validate the expiration of the token.
80
-
*`maxAge`: optional sets an expiration based on the `iat` field. Eg `2h`
83
+
*`ignoreNotBefore`...
84
+
*`jwtid`: if you want to check JWT ID (`jti`), provide a value here
85
+
*`subject`: if you want to check subject (`sub`), provide a value here
0 commit comments