Harden auth/vault path sanitization and clean WeKnora docs

This commit is contained in:
Agent Board
2026-07-28 17:04:27 +08:00
parent 2deaf59f7b
commit 26ff1a9c9a
190 changed files with 13454 additions and 4987 deletions
@@ -1,6 +1,7 @@
#!/usr/bin/env node
"use strict";
const { loginViaAuthForm } = require('./lib/browser-auth-login');
const assert = require("node:assert");
const fs = require("node:fs");
const os = require("node:os");
@@ -43,9 +44,7 @@ async function saveScreenshot(page, name) {
async function loginTestAccount(page) {
await page.goto(`${BASE_URL}/auth`, { waitUntil: "domcontentloaded", timeout: UI_TIMEOUT_MS });
if (page.url().includes("/auth")) {
const quickLogin = page.locator('[data-auth-test-login]').first();
await quickLogin.waitFor({ state: "visible", timeout: UI_TIMEOUT_MS });
await quickLogin.click({ timeout: UI_TIMEOUT_MS });
await loginViaAuthForm(page, { timeoutMs: typeof UI_TIMEOUT_MS !== 'undefined' ? UI_TIMEOUT_MS : undefined });
await page.waitForURL((url) => !url.toString().includes("/auth"), {
waitUntil: "commit",
timeout: UI_TIMEOUT_MS,