7cc7f95019
Adopt model-redis v1.5.0 and give the on-demand is_cache Host records (and their Cached tracking records) created by Host.addCache a TTL, so they auto-expire instead of accumulating forever. Only the record hash carries the TTL, so OpenResty's direct HGETALL sees a miss once it expires and re-resolves through the lookup path. The lifetime is configurable via conf.cacheTTL (seconds, default 3600; 0 disables expiry). This also mitigates the matchAny=false "wrong host" bug: stale leftover cache entries now expire (and are still busted on parent update), so undefined subdomains stop being served by old caches. Add test/unit/wildcard_matchany.test.js covering the matchAny routing decision (defined vs undefined subdomains, mixed-policy sibling wildcards, and cache-entry behavior) and wire it into the test scripts. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
54 lines
1.7 KiB
JSON
54 lines
1.7 KiB
JSON
{
|
|
"name": "proxy-api",
|
|
"version": "1.0.0",
|
|
"private": true,
|
|
"author": [
|
|
{
|
|
"name": "William Mantly",
|
|
"email": "wmantly@gmail.com"
|
|
}
|
|
],
|
|
"scripts": {
|
|
"start": "node ./bin/www",
|
|
"dev": "npx nodemon --ignore public/ ./bin/www",
|
|
"test": "node --test test/unit/callback_queue.test.js test/unit/host_lookup.test.js test/unit/wildcard_matchany.test.js test/unit/unix_socket.test.js test/integration/dns_provider.test.js",
|
|
"test:unit": "node --test test/unit/callback_queue.test.js test/unit/host_lookup.test.js test/unit/wildcard_matchany.test.js test/unit/unix_socket.test.js",
|
|
"test:integration": "node --test test/integration/dns_provider.test.js",
|
|
"test:watch": "node --test --watch test/unit/callback_queue.test.js test/unit/host_lookup.test.js test/unit/wildcard_matchany.test.js test/unit/unix_socket.test.js test/integration/dns_provider.test.js"
|
|
},
|
|
"engines": {
|
|
"node": ">=18.0.0"
|
|
},
|
|
"dependencies": {
|
|
"@fortawesome/fontawesome-free": "^7.1.0",
|
|
"@popperjs/core": "^2.11.8",
|
|
"@simpleworkjs/conf": "^1.0.0",
|
|
"acme-client": "^5.4.0",
|
|
"axios": "^1.13.5",
|
|
"bcrypt": "^6.0.0",
|
|
"bootstrap": "^5.3.8",
|
|
"ejs": "^3.1.10",
|
|
"express": "^5.2.1",
|
|
"extend": "^3.0.2",
|
|
"jq-repeat": "^2.0.1",
|
|
"jquery": "^3.7.1",
|
|
"ldapts": "^8.1.2",
|
|
"linux-sys-user": "^1.2.0",
|
|
"model-redis": "^1.5.0",
|
|
"moment": "^2.30.1",
|
|
"mustache": "^4.2.0",
|
|
"p2psub": "^0.2.0",
|
|
"redis": "^6.1.0",
|
|
"socket.io": "^4.8.3",
|
|
"tld-extract": "^2.1.0"
|
|
},
|
|
"license": "MIT",
|
|
"repository": {
|
|
"type": "git",
|
|
"url": "https://git.theta42.com/wmantly/proxy.git"
|
|
},
|
|
"devDependencies": {
|
|
"nodemon": "^3.1.11"
|
|
}
|
|
}
|