Media Stack called every node local, and a host whose watchdogs never ran reported all clear

This commit is contained in:
Gmer4Lfe
2026-08-21 22:50:09 -04:00
parent 20998c8c31
commit 387382ec9f
3 changed files with 36 additions and 3 deletions
+6
View File
@@ -460,6 +460,12 @@ function vv_arrs_all(): array {
$cacheFile = VV_CACHE_DIR . '/arrs_remote_' . $h . '.json';
if (file_exists($cacheFile)) {
$node = json_decode(file_get_contents($cacheFile), true) ?: [];
// The cache file was written by vv_arrs_local_node() ON THAT HOST, where the node is by
// definition local — so it arrives claiming 'local' => true and, re-emitted verbatim,
// made every node on every host report as this one. Ownership is decided here, by who
// is reading the file, not by who wrote it.
$node['local'] = false;
$node['host'] = $h;
$node['cached'] = true;
$node['cache_age'] = time() - (int)filemtime($cacheFile);
$result[] = $node;