@profullstack/threatcrush 0.13.23 → 0.13.24

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/daemon.js CHANGED
@@ -17069,6 +17069,10 @@ function isSuccessfulAuth(message) {
17069
17069
  }
17070
17070
  function explainBlockFailure(err, backend) {
17071
17071
  const raw = err.message || String(err);
17072
+ if (/EROFS|read-only file system/i.test(raw)) {
17073
+ const path = /open '([^']+)'/.exec(raw)?.[1];
17074
+ return `threatcrushd cannot write ${path ?? "its firewall config"} for ${backend}: the systemd unit mounts it read-only. Reinstall the unit and restart: sudo $(which threatcrush) install-service && sudo systemctl restart threatcrushd`;
17075
+ }
17072
17076
  const denied = /not permitted|EACCES|EPERM|permission denied|must be root/i.test(raw);
17073
17077
  if (!denied) return `${raw} (backend: ${backend})`;
17074
17078
  const who = typeof process.getuid === "function" && process.getuid() === 0 ? "as root" : `as uid ${typeof process.getuid === "function" ? process.getuid() : "?"}`;