Skip to content

refactor: rename block_ip to block_ipv4#46

Merged
leodido merged 4 commits intomainfrom
rename/block-ip-to-block-ipv4
May 1, 2026
Merged

refactor: rename block_ip to block_ipv4#46
leodido merged 4 commits intomainfrom
rename/block-ip-to-block-ipv4

Conversation

@leodido
Copy link
Copy Markdown
Owner

@leodido leodido commented May 1, 2026

Description

block_ip only inspects IPv4 (ETH_P_IP) and filters by IPv4 destination address. The name implies generic IP handling but it doesn't touch IPv6. Renaming to block_ipv4 makes the scope unambiguous.

This establishes the naming convention for the allow_ipv4 rename in PR #41.

Changes

  • Rename bpf/block_ip.bpf.cbpf/block_ipv4.bpf.c (file, function, bpf_printk strings)
  • Update api.lua input_fields key
  • Update input_parse.h enum references
  • Update README.txt and docs/README.md
  • Rename test fixture and update all test files

Pure rename — no behavioral changes.

@leodido leodido changed the title rename block_ip to block_ipv4 refactor: rename block_ip to block_ipv4 May 1, 2026
@leodido leodido self-assigned this May 1, 2026
@leodido leodido force-pushed the rename/block-ip-to-block-ipv4 branch from 6442cff to a8836be Compare May 1, 2026 10:18
leodido and others added 4 commits May 1, 2026 10:19
Rename the BPF source file, function name, and bpf_printk strings.
The program only handles IPv4 — the new name makes that explicit.

Co-authored-by: Ona <no-reply@ona.com>
Update input_fields key in api.lua and enum references in
input_parse.h to match the renamed BPF program.

Co-authored-by: Ona <no-reply@ona.com>
Update CLI examples, CNI examples, and built-in programs
descriptions in README.txt and docs/README.md.

Co-authored-by: Ona <no-reply@ona.com>
Update test names, commands, assertions, and CNI fixture
to use the new program name.

Co-authored-by: Ona <no-reply@ona.com>
@leodido leodido force-pushed the rename/block-ip-to-block-ipv4 branch from a8836be to 9886730 Compare May 1, 2026 10:19
@leodido leodido merged commit a7622b0 into main May 1, 2026
2 checks passed
leodido added a commit that referenced this pull request May 3, 2026
The program only handles IPv4 (ETH_P_IP). The new name makes the
scope unambiguous, consistent with the block_ipv4 rename in PR #46.

Co-authored-by: Ona <no-reply@ona.com>
leodido added a commit that referenced this pull request May 3, 2026
The program only handles IPv4 (ETH_P_IP). The new name makes the
scope unambiguous, consistent with the block_ipv4 rename in PR #46.

Co-authored-by: Ona <no-reply@ona.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant