/** * nftables ruleset applied inside podman's rootless infra netns. See packages/runner/README.md: * jobs must run on a bridge network (slirp default has no filterable hop, gVisor's * netstack transmits via AF_PACKET), rules hook forward, and established/related must * be accepted first or NAT-reversed replies are dropped and all egress dies. */ export declare const EGRESS_TABLE = "integrator_egress"; /** * Renders the complete nftables ruleset; declare-delete-recreate makes it * idempotent. Extra addresses (a deployment's own public IPs, its private * network) join the default private-range drop set. */ export declare function buildRuleset(blockedAddresses?: string[]): string; /** Table metering each networked job's traffic, separate from the drop rules so re-applying those never resets a meter. */ export declare const METER_TABLE = "integrator_meter"; /** * Base of the meter table: a verdict map from job container address to the * job's chain, consulted for both directions of forwarded traffic. Created * once per netns; job chains are added and removed around each job. */ export declare function buildMeterTable(): string; /** * Attaches a job's meter: a counter, an optional over-quota drop, and the map * element routing the job's address to them. An element left for the same * address by a finished job whose detach has not run yet is replaced. */ export declare function buildMeterAttach(id: string, address: string, quotaMb: number | undefined, replace: boolean): string; /** Detaches a job's meter; the map element is removed only while it still routes to this job. */ export declare function buildMeterDetach(id: string, address: string, ownsElement: boolean, hasQuota: boolean): string;