diff options
author | Dmitry Kozlov <xeb@mail.ru> | 2016-03-19 20:17:02 +0300 |
---|---|---|
committer | Dmitry Kozlov <xeb@mail.ru> | 2016-03-19 20:17:02 +0300 |
commit | 64e5c04c0d9aa4b46235c5f0da45d22abf9cce1c (patch) | |
tree | c0e09acd376ca98f5024528c360f66408bb2da32 /drivers | |
parent | 39c7832eac5f3fe6f58bd188df23e677be8ee9bd (diff) | |
download | accel-ppp-64e5c04c0d9aa4b46235c5f0da45d22abf9cce1c.tar.gz accel-ppp-64e5c04c0d9aa4b46235c5f0da45d22abf9cce1c.zip |
ipoe: send arp reply for sessions started by arp request
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/ipoe/ipoe.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/drivers/ipoe/ipoe.c b/drivers/ipoe/ipoe.c index 5bafde6..059b139 100644 --- a/drivers/ipoe/ipoe.c +++ b/drivers/ipoe/ipoe.c @@ -736,9 +736,16 @@ static rx_handler_result_t ipoe_recv(struct sk_buff **pskb) return RX_HANDLER_PASS; arph = (struct _arphdr *)skb_network_header(skb); + if (arph->ar_op != htons(ARPOP_REQUEST)) return RX_HANDLER_PASS; + if (arph->ar_hrd != htons(ARPHRD_ETHER)) + return RX_HANDLER_PASS; + + if (arph->ar_pro != htons(ETH_P_IP)) + return RX_HANDLER_PASS; + saddr = arph->ar_sip; } else return RX_HANDLER_PASS; |