• Matthew Daley's avatar
    x25: Handle undersized/fragmented skbs · cb101ed2
    Matthew Daley authored
    There are multiple locations in the X.25 packet layer where a skb is
    assumed to be of at least a certain size and that all its data is
    currently available at skb->data.  These assumptions are not checked,
    hence buffer overreads may occur.  Use pskb_may_pull to check these
    minimal size assumptions and ensure that data is available at skb->data
    when necessary, as well as use skb_copy_bits where needed.
    Signed-off-by: default avatarMatthew Daley <mattjd@gmail.com>
    Cc: Eric Dumazet <eric.dumazet@gmail.com>
    Cc: Andrew Hendry <andrew.hendry@gmail.com>
    Cc: stable <stable@kernel.org>
    Acked-by: default avatarAndrew Hendry <andrew.hendry@gmail.com>
    Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
    cb101ed2
x25_subr.c 9.49 KB