Add global auth middleware and refresh token handling
This commit is contained in:
@@ -16,19 +16,20 @@ export default defineNuxtConfig({
|
||||
signInResponseTokenPointer: "/access",
|
||||
type: "JWT",
|
||||
headerName: "Authorization",
|
||||
maxAgeInSeconds: 60 * 30,
|
||||
cookieName: "authls.atoken",
|
||||
maxAgeInSeconds: 30 * 60,
|
||||
},
|
||||
refresh: {
|
||||
isEnabled: true,
|
||||
endpoint: { path: "/refresh", method: "post" },
|
||||
refreshOnlyToken: true,
|
||||
endpoint: { path: "/jwt/refresh/", method: "post" },
|
||||
refreshOnlyToken: false,
|
||||
token: {
|
||||
signInResponseRefreshTokenPointer: "/refresh",
|
||||
refreshResponseTokenPointer: "",
|
||||
refreshResponseTokenPointer: "/access",
|
||||
refreshRequestTokenPointer: "/refresh",
|
||||
maxAgeInSeconds: 60 * 60 * 24,
|
||||
cookieName: "authls.rtoken",
|
||||
maxAgeInSeconds: 60 * 60 * 24,
|
||||
sameSiteAttribute: "strict",
|
||||
},
|
||||
},
|
||||
endpoints: {
|
||||
|
||||
Reference in New Issue
Block a user