[ovs-dev] [RFC v3 4/5] ovn: Support OVS action 'check_pkt_larger' in OVN

Ben Pfaff blp at ovn.org
Tue Feb 12 03:22:25 UTC 2019


On Thu, Jan 10, 2019 at 11:31:25PM +0530, nusiddiq at redhat.com wrote:
> From: Numan Siddique <nusiddiq at redhat.com>
> 
> Previous commit added a new OVS action 'check_pkt_larger'. This
> patch supports that action in OVN. The syntax to use this would be
> 
> reg0[0] = check_pkt_larger(LEN)
> 
> Upcoming commit will make use of this action in ovn-northd and
> will generate an ICMP4 packet if the packet length is greater than
> the specified length.
> 
> Signed-off-by: Numan Siddique <nusiddiq at redhat.com>

Thanks

In pinctrl_handle_icmp(), this attempts to add two integers that are in
network byte order, without first converting them to host byte order:

            nh->ip_tot_len += htons(orig_ip_datagram_len);

I think that the code that includes the original IP header in
pinctrl_handle_icmp() should handle the case where the original IP
header is longer than 20 bytes (and it should also handle the case where
it is short or invalid or followed by fewer than 8 bytes of payload).

I guess that ovn-trace should allow the user to specify what value to
return.

Thanks,

Ben.


More information about the dev mailing list