summaryrefslogtreecommitdiff
path: root/drivers
diff options
context:
space:
mode:
authorDmitry Kozlov <xeb@mail.ru>2016-03-19 20:17:02 +0300
committerDmitry Kozlov <xeb@mail.ru>2016-03-19 20:17:02 +0300
commit64e5c04c0d9aa4b46235c5f0da45d22abf9cce1c (patch)
treec0e09acd376ca98f5024528c360f66408bb2da32 /drivers
parent39c7832eac5f3fe6f58bd188df23e677be8ee9bd (diff)
downloadaccel-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.c7
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;