Prefix Overlap
prefix_overlapCheck if two IP prefixes overlap, returning whether they are disjoint, contain one another, or equal. Detect conflicts in IP allocation or routing policy.
Instructions
Check if two IP prefixes overlap.
Returns the relationship: disjoint, one contains the other, or equal. Useful for detecting conflicts in IP allocation or routing policy.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| prefix_a | Yes | First IP prefix (e.g. '10.0.0.0/24') | |
| prefix_b | Yes | Second IP prefix (e.g. '10.0.0.128/25') |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| overlaps | Yes | ||
| prefix_a | Yes | ||
| prefix_b | Yes | ||
| relationship | Yes | 'disjoint', 'a_contains_b', 'b_contains_a', 'equal', or 'partial_overlap' (only possible for differing IP versions or malformed input) |