change: security-check, memory-check [untest]

- fix high risk security issues
- fix high memory usage
- change adb to connection pool single instance

Signed-off-by: pakintada@gmail.com <Pakin>
This commit is contained in:
pakintada@gmail.com 2026-06-22 10:55:47 +07:00
parent f0619c5a10
commit 4f464a8513
23 changed files with 413 additions and 73 deletions

View file

@ -1,14 +1,5 @@
import { doc, getDoc } from 'firebase/firestore';
import { db } from '../client/firebase';
export async function checkAllowAccess(userDomain: string): Promise<boolean> {
const docRef = doc(db, 'whitelist', 'allowedDomains');
const snapshot = await getDoc(docRef);
if (snapshot.exists()) {
let domains = snapshot.data();
return domains['account_email'].includes(userDomain);
}
// Domain blocker disabled — authentication rework is in progress.
// The domain changed from Google to others; this module will be rewritten.
export async function checkAllowAccess(_userDomain: string): Promise<boolean> {
return true;
}