[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH v6 1/2] net: tulip: check frame size and r/w data length
From: |
P J P |
Subject: |
Re: [PATCH v6 1/2] net: tulip: check frame size and r/w data length |
Date: |
Tue, 24 Mar 2020 18:49:44 +0530 (IST) |
+-- On Tue, 24 Mar 2020, Jason Wang wrote --+
| > + if (s->rx_frame_len + len >= sizeof(s->rx_frame)) {
| > + return;
| > + }
| >
| > Why here is '>=' instead of '>'. IIUC the total sending length can reach
| > to sizeof(s->rx_frame). Same in the other place in this patch.
|
| Yes, this need to be fixed.
But, wouldn't s->rx_frame[sizeof(s->rx_frame)] be off-by-one?
Thank you.
--
Prasad J Pandit / Red Hat Product Security Team
8685 545E B54C 486B C6EB 271E E285 8B5A F050 DE8D
- [PATCH v6 0/2] net: tulip: add checks to avoid OOB access, P J P, 2020/03/23
- [PATCH v6 1/2] net: tulip: check frame size and r/w data length, P J P, 2020/03/23
- Re: [PATCH v6 1/2] net: tulip: check frame size and r/w data length, Li Qiang, 2020/03/23
- Re: [PATCH v6 1/2] net: tulip: check frame size and r/w data length, Jason Wang, 2020/03/24
- Re: [PATCH v6 1/2] net: tulip: check frame size and r/w data length,
P J P <=
- Re: [PATCH v6 1/2] net: tulip: check frame size and r/w data length, Li Qiang, 2020/03/24
- Re: [PATCH v6 1/2] net: tulip: check frame size and r/w data length, Jason Wang, 2020/03/26
- Re: [PATCH v6 1/2] net: tulip: check frame size and r/w data length, Li Qiang, 2020/03/26
- Re: [PATCH v6 1/2] net: tulip: check frame size and r/w data length, Jason Wang, 2020/03/26
- Re: [PATCH v6 1/2] net: tulip: check frame size and r/w data length, Li Qiang, 2020/03/26
- Re: [PATCH v6 1/2] net: tulip: check frame size and r/w data length, P J P, 2020/03/26
[PATCH v6 2/2] net: tulip: add .can_receive routine, P J P, 2020/03/23