Skip to content
This repository was archived by the owner on Nov 24, 2025. It is now read-only.
This repository was archived by the owner on Nov 24, 2025. It is now read-only.

Improve nACL Optimization #248

@YairSlobodin1

Description

@YairSlobodin1
  • Using the power of deny rules: Sometimes there is a hole that can be blocked with a deny rule and then a larger allow rule, instead of several allow rules (see example 1). Dividing the cubes into groups of adjacent cubes and checking whether it is better to use complement rules instead may improve the optimization.
  • Currently the activeRules algorithm runs according to the src dimension, but it might be improved if we run it from other dimensions as well. See Example 2.
  • src, dst of nACL rules should be a single CIDR. This could be improved, see example 3.

example one

can be converted into 2 rules
image


example two

can be converted into 2 cubes
image


example three

allow src -> 1.1.1.1
allow src -> 1.1.1.2/31
allow src -> 1.1.1.4/30
allow src -> 1.1.1.8/29

can be converted to:

deny src -> 1.1.1.0
allow src -> 1.1.1.0/28

Note: In the examples above, assume that x axis is srcIP and y axis is dstIP

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions