lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  PHC 
Open Source and information security mailing list archives
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Thu, 8 Oct 2020 10:25:51 +0200
From:   Daniel Borkmann <>
To:     Jesper Dangaard Brouer <>,
        John Fastabend <>
Cc:     Maciej ┼╗enczykowski <>,
        bpf <>, Linux NetDev <>,
        Daniel Borkmann <>,
        Alexei Starovoitov <>,
        Lorenz Bauer <>,
        Shaun Crampton <>,
        Lorenzo Bianconi <>,
        Marek Majkowski <>,
        Jakub Kicinski <>,
        Eyal Birger <>
Subject: Re: [PATCH bpf-next V2 5/6] bpf: Add MTU check for TC-BPF packets
 after egress hook

On 10/8/20 10:07 AM, Jesper Dangaard Brouer wrote:
>>> However, due to both gso and vlan offload, even this is not trivial to do...
>>> The mtu is L3, but drivers/hardware/the wire usually care about L2...
> If net_device->mtu is L3 (1500) and XDP (and TC, right?) operate at L2,
> that likely means that the "strict" bpf_mtu_check (in my BPF-helper) is
> wrong, as XDP (and TC) length at this point include the 14 bytes
> Ethernet header.  I will check and fix.

Yes, both at L2 layer.

> Is this accounted for via net_device->hard_header_len ?

It is, see also ether_setup().

Powered by blists - more mailing lists