diff --git a/backend/src/main/java/de/htwg_konstanz/mobilelearning/services/auth/JwtService.java b/backend/src/main/java/de/htwg_konstanz/mobilelearning/services/auth/JwtService.java index 9dcf6f02..71a65b5c 100644 --- a/backend/src/main/java/de/htwg_konstanz/mobilelearning/services/auth/JwtService.java +++ b/backend/src/main/java/de/htwg_konstanz/mobilelearning/services/auth/JwtService.java @@ -39,7 +39,7 @@ public DefaultJWTCallerPrincipal getJwtClaims(String jwt) throws InvalidJwtExcep * email email of the user from ldap * preferred_username username of the user from ldap * groups roles of the user - * exp expiration time of the token (2 days) + * exp expiration time of the token (365 days) * * @param user * @return JWT token @@ -71,7 +71,7 @@ public String getToken(User user) { .claim(Claims.email.name(), user.getEmail()) .claim(Claims.preferred_username.name(), user.getUsername()) .groups(new HashSet(user.getRoles())) - .expiresAt((System.currentTimeMillis() + 172800000L)/1000L) + .expiresAt((System.currentTimeMillis() + 31536000000L)/1000L) .sign(); return token; }