Skip to content

Firewall rule deleted via API remains active in PF ruleset - version api v2.8.3 #921

Description

@joaquimrbjr

A floating firewall rule deleted through the API was removed from /cf/conf/config.xml, but remained in /tmp/rules.debug and in the active PF ruleset.

Rule details:

Type: Floating
Action: Pass
Quick: Enabled
Protocol: TCP
Source: 172.22.19.98
Destination: sg_testesub3224_e941ab16
Port: 80
Tracker ID: 1784834938

After deletion:

grep 1784834938 /cf/conf/config.xml

returned no result, but:

grep 1784834938 /tmp/rules.debug

still returned:

pass in log quick inet proto tcp from 172.22.19.98 to $sg_testesub3224_e941ab16 port 80 ridentifier 1784834938 flags S/SA keep state label "USER_RULE: Ingress: 172.22.19.98/32 → SG sg_testesub3224_e..." label "id:1784834938"

New HTTP connections continued to match this rule, so the issue was not caused only by existing firewall states.

The problem was resolved by manually running:

/etc/rc.filter_configure

This suggests that the API updated config.xml, but did not regenerate and reload the PF ruleset after deleting the rule.

Expected behavior: deleting a firewall rule through the API should update the configuration and reload the active firewall rules.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions