feat: up refresh tokens to be valid for 12 hours

This commit is contained in:
Jonathan Barrow
2025-06-21 17:39:59 -04:00
parent 6450f3256e
commit 983ee92c9e
5 changed files with 5 additions and 5 deletions

View File

@@ -127,7 +127,7 @@ router.post('/', async (request: express.Request, response: express.Response): P
pid: pnid.pid,
access_level: pnid.access_level,
title_id: BigInt(0),
expire_time: BigInt(Date.now() + (3600 * 1000))
expire_time: BigInt(Date.now() + 12 * 3600 * 1000)
};
try {

View File

@@ -384,7 +384,7 @@ router.post('/', async (request: express.Request, response: express.Response): P
pid: pnid.pid,
access_level: pnid.access_level,
title_id: BigInt(0),
expire_time: BigInt(Date.now() + (3600 * 1000))
expire_time: BigInt(Date.now() + 12 * 3600 * 1000)
};
try {

View File

@@ -71,7 +71,7 @@ export async function login(request: LoginRequest): Promise<DeepPartial<LoginRes
pid: pnid.pid,
access_level: pnid.access_level,
title_id: BigInt(0),
expire_time: BigInt(Date.now() + (3600 * 1000))
expire_time: BigInt(Date.now() + 12 * 3600 * 1000)
};
const accessTokenBuffer = await generateToken(config.aes_key, accessTokenOptions);

View File

@@ -246,7 +246,7 @@ export async function register(request: RegisterRequest): Promise<DeepPartial<Lo
pid: pnid.pid,
access_level: pnid.access_level,
title_id: BigInt(0),
expire_time: BigInt(Date.now() + (3600 * 1000))
expire_time: BigInt(Date.now() + 12 * 3600 * 1000)
};
const accessTokenBuffer = await generateToken(config.aes_key, accessTokenOptions);

View File

@@ -164,7 +164,7 @@ router.post('/access_token/generate', deviceCertificateMiddleware, consoleStatus
system_type: SystemType.WUP,
token_type: TokenType.OAuthRefresh,
pid: pnid.pid,
expire_time: BigInt(Date.now() + (3600 * 1000))
expire_time: BigInt(Date.now() + 12 * 3600 * 1000)
};
const accessTokenBuffer = await generateToken(config.aes_key, accessTokenOptions);