fix: enhance attachment handling and folder deletion logic; improve error responses and rate limiting

This commit is contained in:
shuaiplus
2026-02-18 03:06:50 +08:00
parent fff2b149e9
commit c53819e178
9 changed files with 166 additions and 52 deletions
+2
View File
@@ -99,6 +99,7 @@ export function createRefreshToken(): string {
export interface FileDownloadClaims {
cipherId: string;
attachmentId: string;
jti: string;
exp: number;
}
@@ -114,6 +115,7 @@ export async function createFileDownloadToken(
const payload: FileDownloadClaims = {
cipherId,
attachmentId,
jti: createRefreshToken(),
exp: now + 300, // 5 minutes
};