openwrt / odhcpd

This repository is a mirror of https://git.openwrt.org/?p=project/odhcpd.git. Pull requests will be accepted which will be merged in odhcpd.git
GNU General Public License v2.0
160 stars 96 forks source link

DHCPV6 Reply IA Address Preferred lifetime is infinity #146

Closed applebaba closed 4 years ago

applebaba commented 4 years ago

Frame 88: 170 bytes on wire (1360 bits), 170 bytes captured (1360 bits) on interface 0 Ethernet II, Src: 8c:ec:4c:b3:a3:08 (8c:ec:4c:b3:a3:08), Dst: Dell_c0:a6:bb (8c:ec:4b:c0:a6:bb) Internet Protocol Version 6, Src: fe80::8eec:4cff:feb3:a308, Dst: fe80::95e1:e406:acb8:8c89 User Datagram Protocol, Src Port: 547, Dst Port: 546 DHCPv6 Message type: Reply (7) Transaction ID: 0xd59dbe Server Identifier Option: Server Identifier (2) Length: 10 Value: 000300018cec4cb3a308 DUID: 000300018cec4cb3a308 DUID Type: link-layer address (3) Hardware type: Ethernet (1) Link-layer address: 8c:ec:4c:b3:a3:08 Client Identifier Option: Client Identifier (1) Length: 14 Value: 0001000123deec3a8cec4bc0a6bb DUID: 0001000123deec3a8cec4bc0a6bb DUID Type: link-layer address plus time (1) Hardware type: Ethernet (1) DUID Time: Jan 26, 2019 18:00:26.000000000 中国标准时间 Link-layer address: 8c:ec:4b:c0:a6:bb SOL_MAX_RT Option: SOL_MAX_RT (82) Length: 4 Value: 0000003c DNS recursive name server Option: DNS recursive name server (23) Length: 16 Value: fd597010081900000000000000000001 1 DNS server address: fd59:7010:819::1 Identity Association for Non-temporary Address Option: Identity Association for Non-temporary Address (3) Length: 40 Value: 068cec4b000054600000870000050018fd59701008190000… IAID: 068cec4b T1: 21600 T2: 34560 IA Address Option: IA Address (5) Length: 24 Value: fd597010081900000000000000000d80ffffffffffffffff IPv6 address: fd59:7010:819::d80 Preferred lifetime: infinity Preferred lifetime: infinity

applebaba commented 4 years ago

Can I configure the Preferred lifetime?

dedeckeh commented 4 years ago

Implementation has been changed so that the preferred and valid lifetime can be configured via the DHCP leasetime uci parameter (https://git.openwrt.org/?p=project/odhcpd.git;a=commit;h=6db312a698e920ff61505ef1f42469880829774d). Unless infinite is specified as leasetime value the preferred/valid lifetimes won't have infinite anymore as value