From owner-freebsd-net@freebsd.org Sun Jun 21 21:10:11 2020 Return-Path: Delivered-To: freebsd-net@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 7EB653342A4 for ; Sun, 21 Jun 2020 21:10:11 +0000 (UTC) (envelope-from melifaro@ipfw.ru) Received: from mailman.nyi.freebsd.org (unknown [127.0.1.3]) by mx1.freebsd.org (Postfix) with ESMTP id 49qlYb0Bl8z4dSQ for ; Sun, 21 Jun 2020 21:10:11 +0000 (UTC) (envelope-from melifaro@ipfw.ru) Received: by mailman.nyi.freebsd.org (Postfix) id 029D533422E; Sun, 21 Jun 2020 21:10:11 +0000 (UTC) Delivered-To: net@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 01FA63343AA; Sun, 21 Jun 2020 21:10:11 +0000 (UTC) (envelope-from melifaro@ipfw.ru) Received: from forward500o.mail.yandex.net (forward500o.mail.yandex.net [IPv6:2a02:6b8:0:1a2d::610]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 49qlYY5mQ6z4dbY; Sun, 21 Jun 2020 21:10:09 +0000 (UTC) (envelope-from melifaro@ipfw.ru) Received: from mxback11q.mail.yandex.net (mxback11q.mail.yandex.net [IPv6:2a02:6b8:c0e:1b4:0:640:1f0c:10f2]) by forward500o.mail.yandex.net (Yandex) with ESMTP id 9789560271; Mon, 22 Jun 2020 00:10:05 +0300 (MSK) Received: from localhost (localhost [::1]) by mxback11q.mail.yandex.net (mxback/Yandex) with ESMTP id TFmiyBxwDr-A5d8jKxO; Mon, 22 Jun 2020 00:10:05 +0300 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ipfw.ru; s=mail; t=1592773805; bh=TS0jrS5jUdXWVvGUuGphirAta648X8DmAsnipM2Oydo=; h=References:Date:Message-Id:Subject:In-Reply-To:To:From; b=RTW8CDWHuGk6D5M+J2Qh8FiOFuwoVqzdPCCK8c7/q7ibF6RtUfFCncNhZCpaazjLP ii5UUqsbevQmprciA3pCS3I5FJsNOBFPdT1OXuA3x25g7bDzGhq6eNTPvczJsg8W08 n6Cl42+n+Fx0uR6nhGXgoqdgJW+oQJI/8HR/lkwo= Received: by vla1-5413378edd9f.qloud-c.yandex.net with HTTP; Mon, 22 Jun 2020 00:10:04 +0300 From: Alexander V. Chernikov To: "current@FreeBSD.org" , net , freebsd-hackers In-Reply-To: <626011592740709@mail.yandex.ru> References: <626011592740709@mail.yandex.ru> Subject: Re: net.inet6.ip6.deembed_scopeid removal MIME-Version: 1.0 X-Mailer: Yamail [ http://yandex.ru ] 5.0 Date: Sun, 21 Jun 2020 22:10:04 +0100 Message-Id: <645741592773762@mail.yandex.ru> Content-Transfer-Encoding: 7bit Content-Type: text/plain X-Rspamd-Queue-Id: 49qlYY5mQ6z4dbY X-Spamd-Bar: -- Authentication-Results: mx1.freebsd.org; dkim=pass header.d=ipfw.ru header.s=mail header.b=RTW8CDWH; dmarc=none; spf=pass (mx1.freebsd.org: domain of melifaro@ipfw.ru designates 2a02:6b8:0:1a2d::610 as permitted sender) smtp.mailfrom=melifaro@ipfw.ru X-Spamd-Result: default: False [-2.88 / 15.00]; ARC_NA(0.00)[]; TO_DN_EQ_ADDR_SOME(0.00)[]; R_DKIM_ALLOW(-0.20)[ipfw.ru:s=mail]; NEURAL_HAM_MEDIUM(-1.01)[-1.012]; FROM_HAS_DN(0.00)[]; RCPT_COUNT_THREE(0.00)[3]; R_SPF_ALLOW(-0.20)[+ip6:2a02:6b8:0:1000::/52:c]; TO_MATCH_ENVRCPT_ALL(0.00)[]; MIME_GOOD(-0.10)[text/plain]; DMARC_NA(0.00)[ipfw.ru]; NEURAL_HAM_LONG(-1.04)[-1.045]; TO_DN_SOME(0.00)[]; RCVD_COUNT_THREE(0.00)[3]; DKIM_TRACE(0.00)[ipfw.ru:+]; NEURAL_HAM_SHORT(-0.22)[-0.221]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+]; RCVD_TLS_LAST(0.00)[]; ASN(0.00)[asn:13238, ipnet:2a02:6b8::/32, country:RU]; RCVD_IN_DNSWL_LOW(-0.10)[2a02:6b8:0:1a2d::610:from] X-BeenThere: freebsd-net@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: Networking and TCP/IP with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 21 Jun 2020 21:10:11 -0000 [re-sending email with as non-html] Hey, I would like to deprecate net.inet6.ip6.deembed_scopeid sysctl while leaving the current default behaviour. This sysctl controls whether IPv6 scope is embedded in the IPv6 address or not when reading or writing route/interface/ifaddr data via rtsock/sysctl. Embedding scope in the address is a hack, that overwrites some of the bits that can be used otherwise. It was probably implemented that way to simplify route table interactions, as rtable uses this hack to add link-local addresses to the same radix tree. The change to fix the userland api by filling in sin6_scopeid and avoid touching IPv6 address was added in r243187, 7 years ago. It provided the sysctl in question, allowing to preserve compatibility with older applications, by reverting to the old behavior. 7 years looks like enough timeframe for the applications to be adjusted. Unless any major objections arise, I'm going to remove the code and make de-embedded IPv6 addresses the only option on July 5 2020. /Alexander