Date: Tue, 13 Mar 2018 01:05:53 +0000 From: bugzilla-noreply@freebsd.org To: freebsd-pf@FreeBSD.org Subject: [Bug 226411] PF does not properly keep state with GRE in IPSec Message-ID: <bug-226411-17777-yxPbWcQ1f0@https.bugs.freebsd.org/bugzilla/> In-Reply-To: <bug-226411-17777@https.bugs.freebsd.org/bugzilla/> References: <bug-226411-17777@https.bugs.freebsd.org/bugzilla/>
next in thread | previous in thread | raw e-mail | index | archive | help
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D226411 --- Comment #2 from Eric Dombroski <eric@edombroski.com> --- ################# HOST 1 - ROUTER ################################### root@fbsd12test1:~ # cat /etc/rc.conf hostname=3D"fbsd12test1" ifconfig_vmx0=3D"inet 10.10.10.1 netmask 255.255.255.0" ifconfig_vmx1=3D"inet 10.6.0.1 netmask 255.255.254.0" #lan is a /23 cloned_interfaces=3D"gre0" ifconfig_gre0=3D"inet 10.1.0.1 10.1.0.2 netmask 255.255.255.252 tunnel 10.1= 0.10.1 10.10.10.2 link0 up" gateway_enable=3D"YES" pf_enable=3D"YES" pflog_enable=3D"YES" sshd_enable=3D"YES" # Set dumpdev to "AUTO" to enable crash dumps, "NO" to disable dumpdev=3D"AUTO" strongswan_enable=3D"YES" root@fbsd12test1:~ # cat /etc/pf.conf set block-policy drop set loginterface egress set skip on lo0 set skip on gre0 ### has no apparent effect? ### #default block rules block log all # allow in from other host pass in quick on vmx0 from 10.10.10.0/24 # allow all in from lan subnet pass in quick from 10.6.0.0/23 # pass all output packets pass out quick root@fbsd12test1:~ # cat /usr/local/etc/ipsec.conf config setup uniqueids =3D yes conn bypasslan leftsubnet =3D 10.6.0.0/23 rightsubnet =3D 10.6.0.0/23 authby =3D never type =3D passthrough auto =3D route conn con1 fragmentation =3D yes keyexchange =3D ike reauth =3D yes forceencaps =3D no mobike =3D no rekey =3D yes installpolicy =3D yes type =3D transport dpdaction =3D restart dpddelay =3D 10s dpdtimeout =3D 60s auto =3D route left =3D 10.10.10.1 right =3D 10.10.10.2 leftid =3D 10.10.10.1 ikelifetime =3D 28800s lifetime =3D 3600s ike =3D aes256-sha256-modp4096! esp =3D aes256-sha256-modp4096! leftauth =3D psk rightauth =3D psk rightid =3D 10.10.10.2 aggressive =3D no rightsubnet =3D 10.10.10.2 leftsubnet =3D 10.10.10.1 root@fbsd12test1:~ # cat /usr/local/etc/ipsec.secrets # ipsec.secrets - strongSwan IPsec secrets file %any 10.10.10.2 : PSK "testingtestingtesting" ################# HOST 2 - CLIENT ################################### root@fbsd12test2:~ # cat /etc/rc.conf hostname=3D"fbsd12test2" ifconfig_vmx0=3D"inet 10.10.10.2 netmask 255.255.255.0" cloned_interfaces=3D"gre0" ifconfig_gre0=3D"inet 10.1.0.2 10.1.0.1 netmask 255.255.255.252 tunnel 10.1= 0.10.2 10.10.10.1 link0 up" pf_enable=3D"NO" sshd_enable=3D"YES" # Set dumpdev to "AUTO" to enable crash dumps, "NO" to disable dumpdev=3D"AUTO" strongswan_enable=3D"YES" root@fbsd12test2:~ # cat /usr/local/etc/ipsec.conf config setup uniqueids =3D yes conn con1 fragmentation =3D yes keyexchange =3D ike reauth =3D yes forceencaps =3D no mobike =3D no rekey =3D yes installpolicy =3D yes type =3D transport dpdaction =3D restart dpddelay =3D 10s dpdtimeout =3D 60s auto =3D route left =3D 10.10.10.2 right =3D 10.10.10.1 leftid =3D 10.10.10.2 ikelifetime =3D 28800s lifetime =3D 3600s ike =3D aes256-sha256-modp4096! esp =3D aes256-sha256-modp4096! leftauth =3D psk rightauth =3D psk rightid =3D 10.10.10.1 aggressive =3D no rightsubnet =3D 10.10.10.1 leftsubnet =3D 10.10.10.2 root@fbsd12test2:~ # cat /usr/local/etc/ipsec.secrets # ipsec.secrets - strongSwan IPsec secrets file %any 10.10.10.1 : PSK "testingtestingtesting" root@fbsd12test2:~ # route add -net 10.6.0.0/23 10.1.0.2 Test tcp connection to host on 10.6.0.0/23 (for instance, 10.6.0.10). SYN packet gets through to, ACK doesn't get back. Also, ICMP traffic let throu= gh even if you remove the pass rules that let it go through. --=20 You are receiving this mail because: You are the assignee for the bug.=
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?bug-226411-17777-yxPbWcQ1f0>