Commit Graph

4 Commits

Author SHA1 Message Date
Nick Brown 22a6a37079 Record counts of packets with unknown L3/L4 numbers
Previously, we recorded a single aggregated count. These per-protocol counts
can help us debug field issues when frames are dropped for this reason.

PiperOrigin-RevId: 405913911
2021-10-27 10:06:55 -07:00
Nick Brown b8b43f70c8 Send ICMP errors when link address resolution fails
Before this change, we would silently drop packets when link resolution
failed. This change brings us into line with RFC 792 (IPv4) and RFC 4443 (IPv6),
both of which specify that gateways should return an ICMP error to the sender
when link resolution fails.

PiperOrigin-RevId: 374699789
2021-05-19 12:13:09 -07:00
Arthur Sfez 60bdf7ed31 Move multicounter testutil functions out of network/ip
This is in preparation of having aggregated NIC stats at the stack
level. These validation functions will be needed outside of the
network layer packages to test aggregated NIC stats.

PiperOrigin-RevId: 373180565
2021-05-11 10:25:33 -07:00
Kevin Krakauer 10de8978f9 Use nicer formatting for IP addresses in tests
This was semi-automated -- there are many addresses that were not replaced.
Future commits should clean those up.

Parse4 and Parse6 were given their own package because //pkg/test can introduce
dependency cycles, as it depends transitively on //pkg/tcpip and some other
netstack packages.

PiperOrigin-RevId: 368726528
2021-04-15 15:11:04 -07:00