dhcpcd-discuss

dhcpcd is not sending REQUEST when NoBinding was sent during IA_PD RENEW

Kannekanti, Mohan

Fri Jul 26 21:48:47 2019

Hi Roy,

We are using version 7.2.2.

The CDRouter test suite reported a NoBinding testcase failure for IA_PD.
Below are the steps that are followed.

    step 1. Wait for DHCPv6 client's current prefix binding T1 timer to expire
    step 2. Verify DHCPv6 client sends DHCPv6 Renew
    step 3. Verify Renew contains IA_PD option (26) for same address prefix
    step 4. Send valid DHCPv6 Reply with NoBinding status code (3)
    step 5. Verify DHCPv6 client sends Request message
    step 6. Verify Request contains IA_PD option (26) for same address prefix

    Reference: IETF RFC 3633 Section 12.1 "Requesting router behavior"

The test failing at "step 6". It is expecting that dhcp client should send a REQUEST (as per section 12.1 and 18.1.8 in RFC3315) but the client continue to send RENEW.
In the attached packet capture, you can find the Reply (Packet #2) from the server with NoBinding status for IA_PD followed by Renew packets at T1 interval.

When I checked the code, looks like dhcp6_validatelease() is expecting dhcp6_findia() to return "-1" to invalidate the lease and fallback to discover state.
But, in our case dhcp6_findia() is not returning "-1" thus the client continued to send RENEW.

dhcp6_findia(...) {
    ...
    while (l > sizeof(o)) {
        ....
        l -= sizeof(o) + o.len;
        ....
        if (dhcp6_checkstatusok(ifp, NULL, p, o.len) == -1) {
            e = 1;
            continue;
        }
        ....
        i++;
    }
    ...
    if (i == 0 && e)
        return -1;
    return i;
}

When we receive a valid IA_NA and invalid IA_PD (NoBinding), 'i' value is 1 and 'e' value is '1'.

Are we missing anything here? is it bug in dhcpcd?

Thanks,
Mohan.


-----------------------------------------------------------------------------------------------------------------------
Notice: This e-mail together with any attachments may contain information of Ribbon Communications Inc. that
is confidential and/or proprietary for the sole use of the intended recipient.  Any review, disclosure, reliance or
distribution by others or forwarding without express permission is strictly prohibited.  If you are not the intended
recipient, please notify the sender immediately and then delete all copies, including any attachments.
-----------------------------------------------------------------------------------------------------------------------

Attachment: dhcpcd_ipv6_iapd_renew_nobinding.pcap
Description: dhcpcd_ipv6_iapd_renew_nobinding.pcap


Follow-Ups:
Re: dhcpcd is not sending REQUEST when NoBinding was sent during IA_PD RENEWRoy Marples
Archive administrator: postmaster@marples.name