diff options
author | Dmitry Kozlov <xeb@mail.ru> | 2013-09-05 10:33:25 +0400 |
---|---|---|
committer | Dmitry Kozlov <xeb@mail.ru> | 2013-09-05 10:33:25 +0400 |
commit | b7f3774031f043bc0c16bc0f5d030a6b7fe4e611 (patch) | |
tree | 972b8aa04b51de9302d2d340e6cb87cae9954435 /accel-pppd/ctrl/ipoe/ipoe.c | |
parent | 3f1680f8c6a27b942796f2f558f700abe93d12ca (diff) | |
download | accel-ppp-b7f3774031f043bc0c16bc0f5d030a6b7fe4e611.tar.gz accel-ppp-b7f3774031f043bc0c16bc0f5d030a6b7fe4e611.zip |
ipoe: send DHCPNAK for DHCPREQUEST without Server-ID if session is not found
Diffstat (limited to 'accel-pppd/ctrl/ipoe/ipoe.c')
-rw-r--r-- | accel-pppd/ctrl/ipoe/ipoe.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/accel-pppd/ctrl/ipoe/ipoe.c b/accel-pppd/ctrl/ipoe/ipoe.c index 4edafcb3..f792e1bc 100644 --- a/accel-pppd/ctrl/ipoe/ipoe.c +++ b/accel-pppd/ctrl/ipoe/ipoe.c @@ -1286,10 +1286,12 @@ static void __ipoe_recv_dhcpv4(struct dhcpv4_serv *dhcpv4, struct dhcpv4_packet dhcpv4_print_packet(pack, 0, log_debug); } - if (serv->opt_shared == 0) { + if (!pack->server_id) + dhcpv4_send_nak(dhcpv4, pack); + + if (serv->opt_shared == 0) ipoe_drop_sessions(serv, NULL); - //dhcpv4_send_nak(dhcpv4, pack); - } else if (opt82_ses) { + else if (opt82_ses) { if (conf_verbose) { log_switch(dhcpv4->ctx, &opt82_ses->ses); log_ppp_warn("mac change detected\n"); |