tests/e2e: firewalld, nftables, iptables and kube rules make the firewall step hold (tests #115)

Aperta
#144 0 commenti 0 reazioni 0 assegnatari Vedi su GitHub

I maintainer di solito rispondono entro 2 giorni

Nessuno ha ancora preso questa issue.

Valutazione

Difficoltà
4/5
Tempo stimato
1-2 giorni
Idoneità per principianti
55/100
Tipo di issue
Funzionalità
Chiarezza
Specificata chiaramente
Stato di attività
Attiva
Stack tecnologico
bash, debian, docker, shell, ubuntu

Direzione di ricerca

Read #115 and inspect step_firewall, fw.managers, tests/exit-status.sh, and the existing end-to-end test setup to see how scenarios provision and reset VMs. Start by tracing the firewall step and audit behavior for existing managers. Add the four manager scenarios and the fresh-path and false-positive checks on Debian 13 and Ubuntu 24.04; done means the listed assertions pass and the workflow runs weekly and for relevant pull requests.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

area: audit area: ci area: prep claude enhancement priority: medium security size: M

Epic #121 · Tests #115 (epic #109) · Milestone Phase 5: Servers already in use · Priority medium · Size M · Depends on #115


Why

#115 detects firewalld, nftables, netfilter-persistent and Kubernetes rules before enabling UFW. The issue keeps it out of the brownfield profile, so it gets its own short scenario set: boot, set up one manager, run only the firewall step. No full prep, so it stays cheap.

Scenarios fw-manager-<name> (one fresh VM each, or one VM reset between them)

For each of firewalld (unit active, one allowed port), nftables (nftables.service active, /etc/nftables.conf with an input chain), netfilter-persistent (/etc/iptables/rules.v4 not empty) and kube (a hand-made KUBE-SERVICES chain):

  • --existing --yes --only firewall: HELD with a todo that names the manager and how to switch. UFW stays inactive and ufw_docker_rules() does not run (no ufw-user-forward in DOCKER-USER).
  • The manager still works: the port it allows still answers from the runner, and its unit is still active.
  • Audit: fw.managers is PASS (one manager) or INFO (nftables only).

Then, on the firewalld VM:

  • Fresh path: --yes --only firewall without --existing warns, then enables UFW. Audit fw.managers is WARN "two firewall managers active (ufw, firewalld)".
  • No false positive: on the fresh profile VM (Docker and Tailscale-style ts- chains), fw.managers is PASS and the step is not HELD.

Acceptance criteria

  • Runs weekly on every system, and on PRs that touch step_firewall or fw.managers on Debian 13 and Ubuntu 24.04.
  • The unit check in tests/exit-status.sh from #115 stays, as the fast check.
Lingua principale
Shell
Stelle
2
Fork
3
Merge medio
2g 14m
PR unite (30g)
47

Preparare l'ambiente

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di exceev-consulting/server-prep

Tutte le issue di exceev-consulting/server-prep

Issue simili

Altre issue su Shell/Bash

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.