Skip to content

Commit

Permalink
change cred expiration date
Browse files Browse the repository at this point in the history
  • Loading branch information
endimion committed Sep 13, 2024
1 parent a359ad1 commit 6135dd1
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions routes/routes.js
Original file line number Diff line number Diff line change
Expand Up @@ -443,7 +443,7 @@ router.post("/credential", async (req, res) => {
iss: serverURL,
sub: decodedHeaderSubjectDID || "",
iat: Math.floor(Date.now() / 1000), // Token issued at time
exp: (Math.floor(Date.now() / 1000) + 60 * 60) * 1000,
exp: Math.floor(Date.now() / 1000) + 60 * 60 * 24 * 30, // Token expiration time (1 hour from now)
jti: "urn:did:1904a925-38bd-4eda-b682-4b5e3ca9d4bc",
vc: {
type: ["StudentID"],//["EducationalID"],
Expand Down Expand Up @@ -475,7 +475,7 @@ router.post("/credential", async (req, res) => {
Math.floor(Date.now() / 1000) * 1000
).toISOString(),
expirationDate: new Date(
(Math.floor(Date.now() / 1000) + 60 * 60) * 1000
(Math.floor(Date.now() / 1000) + 60 * 60 * 24 * 30) * 1000
).toISOString(),
validFrom: new Date(
Math.floor(Date.now() / 1000) * 1000
Expand Down

0 comments on commit 6135dd1

Please sign in to comment.