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
+5 -1
View File
@@ -1,6 +1,7 @@
#!/usr/bin/env node
"use strict";
const { loginViaAuthForm } = require('./lib/browser-auth-login');
const assert = require("node:assert");
const { spawn } = require("node:child_process");
const {
@@ -72,7 +73,10 @@ async function validateAuthEntry(baseUrl) {
assert.match(authText, /name="password"[^>]*type="password"|type="password"[^>]*name="password"/);
assert.match(authText, /data-auth-mode="control-plane-session"/);
assert.match(authText, /没有账号?注册/);
assert.match(authText, /测试账号快速登录/);
assert.doesNotMatch(authText, /测试账号快速登录/);
assert.doesNotMatch(authText, /data-auth-test-login/);
assert.doesNotMatch(authText, /data-test-password/);
assert.match(authText, /data-auth-submit/);
assert.doesNotMatch(authText, /隐私政策|使用\s*Google|使用\s*GitHub|第三方快捷/iu);
const authedAuth = await fetchWithTimeout(`${baseUrl}/auth`, {