From owner-svn-src-head@freebsd.org Sat Mar 23 15:41:33 2019 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 89141155401E; Sat, 23 Mar 2019 15:41:33 +0000 (UTC) (envelope-from ae@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) server-signature RSA-PSS (4096 bits) client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 2D8036EC5A; Sat, 23 Mar 2019 15:41:33 +0000 (UTC) (envelope-from ae@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 0694BA649; Sat, 23 Mar 2019 15:41:33 +0000 (UTC) (envelope-from ae@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id x2NFfWT0052424; Sat, 23 Mar 2019 15:41:32 GMT (envelope-from ae@FreeBSD.org) Received: (from ae@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id x2NFfWWE052423; Sat, 23 Mar 2019 15:41:32 GMT (envelope-from ae@FreeBSD.org) Message-Id: <201903231541.x2NFfWWE052423@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ae set sender to ae@FreeBSD.org using -f From: "Andrey V. Elsukov" Date: Sat, 23 Mar 2019 15:41:32 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r345450 - in head: libexec/rc/rc.d share/man/man5 X-SVN-Group: head X-SVN-Commit-Author: ae X-SVN-Commit-Paths: in head: libexec/rc/rc.d share/man/man5 X-SVN-Commit-Revision: 345450 X-SVN-Commit-Repository: base MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Rspamd-Queue-Id: 2D8036EC5A X-Spamd-Bar: -- Authentication-Results: mx1.freebsd.org X-Spamd-Result: default: False [-2.97 / 15.00]; local_wl_from(0.00)[FreeBSD.org]; NEURAL_HAM_MEDIUM(-1.00)[-0.999,0]; NEURAL_HAM_SHORT(-0.97)[-0.971,0]; ASN(0.00)[asn:11403, ipnet:2610:1c1:1::/48, country:US]; NEURAL_HAM_LONG(-1.00)[-1.000,0] X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 23 Mar 2019 15:41:33 -0000 Author: ae Date: Sat Mar 23 15:41:32 2019 New Revision: 345450 URL: https://svnweb.freebsd.org/changeset/base/345450 Log: Add ability to automatically load ipfw_nat64, ipfw_nptv6 and ipfw_pmod modules by declaring corresponding variables in rc.conf. Also document them in rc.conf(5). Submitted by: Dries Michiels Differential Revision: https://reviews.freebsd.org/D19673 Modified: head/libexec/rc/rc.d/ipfw head/share/man/man5/rc.conf.5 Modified: head/libexec/rc/rc.d/ipfw ============================================================================== --- head/libexec/rc/rc.d/ipfw Sat Mar 23 14:10:05 2019 (r345449) +++ head/libexec/rc/rc.d/ipfw Sat Mar 23 15:41:32 2019 (r345450) @@ -34,6 +34,15 @@ ipfw_prestart() if checkyesno firewall_nat_enable; then required_modules="$required_modules ipfw_nat" fi + if checkyesno firewall_nat64_enable; then + required_modules="$required_modules ipfw_nat64" + fi + if checkyesno firewall_nptv6_enable; then + required_modules="$required_modules ipfw_nptv6" + fi + if checkyesno firewall_pmod_enable; then + required_modules="$required_modules ipfw_pmod" + fi } ipfw_start() Modified: head/share/man/man5/rc.conf.5 ============================================================================== --- head/share/man/man5/rc.conf.5 Sat Mar 23 14:10:05 2019 (r345449) +++ head/share/man/man5/rc.conf.5 Sat Mar 23 15:41:32 2019 (r345450) @@ -24,7 +24,7 @@ .\" .\" $FreeBSD$ .\" -.Dd December 19, 2018 +.Dd March 21, 2019 .Dt RC.CONF 5 .Os .Sh NAME @@ -573,9 +573,11 @@ equivalent of .Va natd_enable . Setting this to .Dq Li YES -enables kernel NAT. +will automatically load the +.Xr ipfw 8 +NAT kernel module if .Va firewall_enable -must also be set to +is also set to .Dq Li YES . .It Va firewall_nat_interface .Pq Vt str @@ -588,6 +590,36 @@ kernel NAT should run. .It Va firewall_nat_flags .Pq Vt str Additional configuration parameters for kernel NAT should be placed here. +.It Va firewall_nat64_enable +.Pq Vt bool +Setting this to +.Dq Li YES +will automatically load the +.Xr ipfw 8 +NAT64 kernel module if +.Va firewall_enable +is also set to +.Dq Li YES . +.It Va firewall_nptv6_enable +.Pq Vt bool +Setting this to +.Dq Li YES +will automatically load the +.Xr ipfw 8 +NPTv6 kernel module if +.Va firewall_enable +is also set to +.Dq Li YES . +.It Va firewall_pmod_enable +.Pq Vt bool +Setting this to +.Dq Li YES +will automatically load the +.Xr ipfw 8 +pmod kernel module if +.Va firewall_enable +is also set to +.Dq Li YES . .It Va dummynet_enable .Pq Vt bool Setting this to