summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorAleksander Jan Bajkowski <olek2@wp.pl>2024-09-23 23:49:49 +0200
committerPaolo Abeni <pabeni@redhat.com>2024-10-01 10:58:07 +0200
commit45c0de18ff2dc9af01236380404bbd6a46502c69 (patch)
tree173be92066ce05774ccfd47bb0e1cc36c847a096 /include
parente609c959a939660c7519895f853dfa5624c6827a (diff)
net: ethernet: lantiq_etop: fix memory disclosure
When applying padding, the buffer is not zeroed, which results in memory disclosure. The mentioned data is observed on the wire. This patch uses skb_put_padto() to pad Ethernet frames properly. The mentioned function zeroes the expanded buffer. In case the packet cannot be padded it is silently dropped. Statistics are also not incremented. This driver does not support statistics in the old 32-bit format or the new 64-bit format. These will be added in the future. In its current form, the patch should be easily backported to stable versions. Ethernet MACs on Amazon-SE and Danube cannot do padding of the packets in hardware, so software padding must be applied. Fixes: 504d4721ee8e ("MIPS: Lantiq: Add ethernet driver") Signed-off-by: Aleksander Jan Bajkowski <olek2@wp.pl> Reviewed-by: Jacob Keller <jacob.e.keller@intel.com> Reviewed-by: Florian Fainelli <florian.fainelli@broadcom.com> Link: https://patch.msgid.link/20240923214949.231511-2-olek2@wp.pl Signed-off-by: Paolo Abeni <pabeni@redhat.com>
Diffstat (limited to 'include')
0 files changed, 0 insertions, 0 deletions