Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 13 Sep 2012 23:26:48 +0200
From:      =?ISO-8859-1?Q?Olivier_Cochard=2DLabb=E9?= <olivier@cochard.me>
To:        freebsd-pf@freebsd.org
Subject:   Patch for adding "options PF_DEFAULT_TO_DROP" to kernel configuration file
Message-ID:  <CA%2Bq%2BTcqL1e=SLa7fUXpCa5Lpospj0F=%2BcfLnAjWDwHFVFxjAMw@mail.gmail.com>

next in thread | raw e-mail | index | archive | help
--0016e6de0425509dda04c99bf8ba
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: quoted-printable

Hi,
here is a little patch (tested on FreeBSD 9.1-RC1) that add a new
option to the kernel configuration file:
options PF_DEFAULT_TO_DROP

Without this option, with an empty pf.conf:=A0All traffic are permit.
With this option enabled, with an empty pf.conf: All traffic are
dropped by default.

If the attached file is removed, you can found the patch here:
http://www.freebsd.org/cgi/query-pr.cgi?pr=3D171622

Regards,

Olivier

--0016e6de0425509dda04c99bf8ba
Content-Type: application/octet-stream; name="freebsd.pf_drop.patch"
Content-Disposition: attachment; filename="freebsd.pf_drop.patch"
Content-Transfer-Encoding: base64
X-Attachment-Id: f_h72ahf8k0

LS0tIHN5cy9jb250cmliL3BmL25ldC9wZl9pb2N0bC5jLm9yaWcJMjAxMi0wOS0wNiAxNTo0Nzo0
Ny4wMDAwMDAwMDAgKzAyMDAKKysrIHN5cy9jb250cmliL3BmL25ldC9wZl9pb2N0bC5jCTIwMTIt
MDktMDYgMTU6NTY6MTYuMDAwMDAwMDAwICswMjAwCkBAIC0zODYsNyArMzg2LDExIEBACiAKIAkv
KiBkZWZhdWx0IHJ1bGUgc2hvdWxkIG5ldmVyIGJlIGdhcmJhZ2UgY29sbGVjdGVkICovCiAJVl9w
Zl9kZWZhdWx0X3J1bGUuZW50cmllcy50cWVfcHJldiA9ICZWX3BmX2RlZmF1bHRfcnVsZS5lbnRy
aWVzLnRxZV9uZXh0OworCSNpZmRlZiBQRl9ERUZBVUxUX1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