From 0cd1b376eb93a1097d7018392061cde47467c9bf Mon Sep 17 00:00:00 2001 From: Florian Obser Date: Wed, 22 Nov 2023 18:06:45 +0000 Subject: Recognize option ipv6-only-preferred (RFC8925). "option option-108 00:00:07:08;" is unwieldy and error prone. OK denis, kn, deraadt --- usr.sbin/dhcpd/dhcp-options.5 | 8 ++++++-- usr.sbin/dhcpd/tables.c | 4 ++-- 2 files changed, 8 insertions(+), 4 deletions(-) (limited to 'usr.sbin/dhcpd') diff --git a/usr.sbin/dhcpd/dhcp-options.5 b/usr.sbin/dhcpd/dhcp-options.5 index 25b168fdb21..80e9fe258c6 100644 --- a/usr.sbin/dhcpd/dhcp-options.5 +++ b/usr.sbin/dhcpd/dhcp-options.5 @@ -1,4 +1,4 @@ -.\" $OpenBSD: dhcp-options.5,v 1.32 2022/03/31 17:27:29 naddy Exp $ +.\" $OpenBSD: dhcp-options.5,v 1.33 2023/11/22 18:06:44 florian Exp $ .\" .\" Copyright (c) 1995, 1996, 1997, 1998 The Internet Software Consortium. .\" All rights reserved. @@ -36,7 +36,7 @@ .\" see ``http://www.isc.org/isc''. To learn more about Vixie .\" Enterprises, see ``http://www.vix.com''. .\" -.Dd $Mdocdate: March 31 2022 $ +.Dd $Mdocdate: November 22 2023 $ .Dt DHCP-OPTIONS 5 .Os .Sh NAME @@ -346,6 +346,10 @@ This option specifies whether the client should configure its IP layer for packet forwarding. A value of 0 means disable IP forwarding, and a value of 1 means enable IP forwarding. +.It Ic option ipv6-only-preferred Ar uint32 ; +This option specifies that a NAT64 is available and the pool is IPv6-mostly +capable. +This option is specified in RFC 8925. .It Ic option irc-server Ar ip-address Oo , Ar ip-address ... Oc ; The .Ic irc-server diff --git a/usr.sbin/dhcpd/tables.c b/usr.sbin/dhcpd/tables.c index 6735a332a75..d9364cc7b97 100644 --- a/usr.sbin/dhcpd/tables.c +++ b/usr.sbin/dhcpd/tables.c @@ -1,4 +1,4 @@ -/* $OpenBSD: tables.c,v 1.14 2019/05/08 22:00:55 krw Exp $ */ +/* $OpenBSD: tables.c,v 1.15 2023/11/22 18:06:44 florian Exp $ */ /* Tables of information... */ @@ -184,7 +184,7 @@ struct option dhcp_options[256] = { { "option-105", "X", &dhcp_universe, 105 }, { "option-106", "X", &dhcp_universe, 106 }, { "option-107", "X", &dhcp_universe, 107 }, - { "option-108", "X", &dhcp_universe, 108 }, + { "ipv6-only-preferred", "L", &dhcp_universe, 108 }, { "option-109", "X", &dhcp_universe, 109 }, { "option-110", "X", &dhcp_universe, 110 }, { "option-111", "X", &dhcp_universe, 111 }, -- cgit v1.2.3