release: WRNexusJS 0.5.0

This commit is contained in:
Clintchiz committed 2026-07-29 12:51:10 +05:30
1 parent 76c768099d
commit 6afe32f63f
456 files changed
+40879 -8850

No files matched your search

+21
View File
@@ -0,0 +1,21 @@
import {
createCaptchaEngine,
createCaptchaHttpHandlers,
MemoryCaptchaStore,
} from "@wrnexus/captcha/server";
export const captchaEngine = createCaptchaEngine({
secret: process.env.CAPTCHA_SECRET ?? "development-auth-showcase-captcha-secret-change-this",
store: new MemoryCaptchaStore(),
basePath: "/api/captcha",
challengeTtlMs: 2 * 60_000,
responseTokenTtlMs: 5 * 60_000,
maxAttempts: 3,
minCompletionMs: 800,
});
export const captchaHandlers = createCaptchaHttpHandlers(captchaEngine, {
createLimit: 60,
verifyLimit: 60,
windowMs: 60_000,
});