The parser accepts a port name as a next hop, and a /prefix that it then rejects #1281
Labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
jaylouisw/packetforge#1281
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
The census in #1279 proved state → text. This is the other direction: what the parser accepts and
then stores, which is sometimes neither what was typed nor anything at all.
Why the route shape matters
routeTo()readsr.gwas an address andr.ifaceas an egress. A port name ingwtherefore produces aroute that is listed, installed, printed by
show running-config, and then ARPs for an address calledGi0.Measured on a two-router lab with the pc's LAN reachable through r2:
ip route 192.168.9.0 255.255.255.0 10.0.0.2ip route 192.168.9.0 255.255.255.0 Gi0no ARP reply from 192.168.9.9The port-only form is legal and worth keeping — it is how you point at a segment — but it carries a packet only
if the far side proxies ARP for the destination, and nothing said so anywhere. That is the failure mode this
project keeps closing: a table that looks healthy over a path that cannot work.
What "done" looks like
ip route <dest> <mask> <port>stores the port in the egress field,gwnull;no next hop: this resolves by ARP on that segment, which needs proxy ARP on the far sidewhen the line is typed, and
show ip routecarries(no next hop: ARP for the destination on that segment)on the row;
a port followed by anything else is refused; a next hop followed by an unknown port is refused;
show running-config— including the port-onlyform, which used to print an empty field and two spaces;
ip address <addr>/<len>is refused with both accepted forms spelled out, and the previous address is leftuntouched;
network <net>/<len>andnetwork <net> <mask>produce identical state and identical printed config;an impossible prefix (
/33) is refused quoting the value and stores no half-network.