Hello, I’m attempting to set up a L2TP/IPsec VPN, but my firewall rules are interfering with internet access. The issue is that I didn’t find a way to permit it and didn’t find the rule blocking it either. What is the best way to do it?
VyOS
set firewall name LAN-LOCAL default-action 'accept'
set firewall name LAN-WAN default-action 'accept'
set firewall name LOCAL-LAN default-action 'accept'
set firewall name LOCAL-WAN default-action 'accept'
set firewall name WAN-LAN default-action 'drop'
set firewall name WAN-LAN rule 5 action 'accept'
set firewall name WAN-LAN rule 5 description 'Allow EST/Related Traffic'
set firewall name WAN-LAN rule 5 state established 'enable'
set firewall name WAN-LAN rule 5 state related 'enable'
set firewall name WAN-LAN rule 20 action 'accept'
set firewall name WAN-LAN rule 20 protocol 'icmp'
set firewall name WAN-LAN rule 20 state new 'enable'
set firewall name WAN-LOCAL default-action 'drop'
set firewall name WAN-LOCAL rule 5 action 'accept'
set firewall name WAN-LOCAL rule 5 description 'Allow EST/Related Traffic'
set firewall name WAN-LOCAL rule 5 state established 'enable'
set firewall name WAN-LOCAL rule 5 state related 'enable'
set firewall name WAN-LOCAL rule 20 action 'accept'
set firewall name WAN-LOCAL rule 20 protocol 'icmp'
set firewall name WAN-LOCAL rule 20 state new 'enable'
set firewall name WAN-LOCAL rule 30 action 'drop'
set firewall name WAN-LOCAL rule 30 destination port '22'
set firewall name WAN-LOCAL rule 30 protocol 'tcp'
set firewall name WAN-LOCAL rule 30 recent count '4'
set firewall name WAN-LOCAL rule 30 recent time 'minute'
set firewall name WAN-LOCAL rule 30 state new 'enable'
set firewall name WAN-LOCAL rule 31 action 'accept'
set firewall name WAN-LOCAL rule 31 destination port '22'
set firewall name WAN-LOCAL rule 31 protocol 'tcp'
set firewall name WAN-LOCAL rule 31 state new 'enable'
set firewall name WAN-LOCAL rule 40 action 'accept'
set firewall name WAN-LOCAL rule 40 protocol 'esp'
set firewall name WAN-LOCAL rule 41 action 'accept'
set firewall name WAN-LOCAL rule 41 destination port '500'
set firewall name WAN-LOCAL rule 41 protocol 'udp'
set firewall name WAN-LOCAL rule 42 action 'accept'
set firewall name WAN-LOCAL rule 42 destination port '4500'
set firewall name WAN-LOCAL rule 42 protocol 'udp'
set firewall name WAN-LOCAL rule 43 action 'accept'
set firewall name WAN-LOCAL rule 43 destination port '1701'
set firewall name WAN-LOCAL rule 43 ipsec match-ipsec
set firewall name WAN-LOCAL rule 43 protocol 'udp'
set firewall zone LAN default-action 'drop'
set firewall zone LAN from LOCAL firewall name 'LOCAL-LAN'
set firewall zone LAN from WAN firewall name 'WAN-LAN'
set firewall zone LAN interface 'eth1'
set firewall zone LOCAL default-action 'drop'
set firewall zone LOCAL from LAN firewall name 'LAN-LOCAL'
set firewall zone LOCAL from WAN firewall name 'WAN-LOCAL'
set firewall zone LOCAL local-zone
set firewall zone WAN default-action 'drop'
set firewall zone WAN from LAN firewall name 'LAN-WAN'
set firewall zone WAN from LOCAL firewall name 'LOCAL-WAN'
set firewall zone WAN interface 'pppoe0'
set interfaces ethernet eth0 hw-id 'xx:xx:xx:xx:xx:5a'
set interfaces ethernet eth1 address 'xxx.xxx.0.1/24'
set interfaces ethernet eth1 description 'LAN'
set interfaces ethernet eth1 hw-id 'xx:xx:xx:xx:xx:5b'
set interfaces ethernet eth1 ip adjust-mss '1452'
set interfaces ethernet eth2 hw-id 'xx:xx:xx:xx:xx:5c'
set interfaces ethernet eth3 hw-id 'xx:xx:xx:xx:xx:5d'
set interfaces loopback lo
set interfaces pppoe pppoe0 authentication password xxxxxx
set interfaces pppoe pppoe0 authentication user xxxxxx
set interfaces pppoe pppoe0 description 'WAN'
set interfaces pppoe pppoe0 dhcpv6-options pd 0 interface eth0 address '1'
set interfaces pppoe pppoe0 dhcpv6-options pd 0 interface eth0 sla-id '0'
set interfaces pppoe pppoe0 dhcpv6-options pd 0 interface eth1 address '100'
set interfaces pppoe pppoe0 dhcpv6-options pd 0 interface eth1 sla-id '0'
set interfaces pppoe pppoe0 dhcpv6-options pd 0 length '56'
set interfaces pppoe pppoe0 ip adjust-mss '1452'
set interfaces pppoe pppoe0 ipv6 address autoconf
set interfaces pppoe pppoe0 ipv6 adjust-mss 'clamp-mss-to-pmtu'
set interfaces pppoe pppoe0 mtu '1492'
set interfaces pppoe pppoe0 source-interface 'eth0'
set nat source rule 100 outbound-interface 'pppoe0'
set nat source rule 100 source address 'xxx.xxx.0.0/24'
set nat source rule 100 translation address 'masquerade'
set nat source rule 110 outbound-interface 'pppoe0'
set nat source rule 110 source address 'xxx.xxx.255.0/24'
set nat source rule 110 translation address 'masquerade'
set policy route MSS description 'TCP MSS Clamping for PPPoE'
set policy route MSS rule 5 protocol 'tcp'
set policy route MSS rule 5 set tcp-mss '1452'
set policy route MSS rule 5 tcp flags syn
set service dhcp-server shared-network-name xxxxxx subnet xxx.xxx.0.0/24 default-router 'xxx.xxx.0.1'
set service dhcp-server shared-network-name xxxxxx subnet xxx.xxx.0.0/24 domain-name xxxxxx
set service dhcp-server shared-network-name xxxxxx subnet xxx.xxx.0.0/24 lease '86400'
set service dhcp-server shared-network-name xxxxxx subnet xxx.xxx.0.0/24 name-server 'xxx.xxx.0.1'
set service dhcp-server shared-network-name xxxxxx subnet xxx.xxx.0.0/24 range 0 start 'xxx.xxx.0.9'
set service dhcp-server shared-network-name xxxxxx subnet xxx.xxx.0.0/24 range 0 stop 'xxx.xxx.0.254'
set service dns forwarding allow-from 'xxx.xxx.0.0/24'
set service dns forwarding cache-size '0'
set service dns forwarding listen-address 'xxx.xxx.0.1'
set service dns forwarding name-server 'xxx.xxx.0.1'
set service dns forwarding name-server 'xxx.xxx.1.1'
set service dns forwarding name-server 'xxx.xxx.4.4'
set service dns forwarding name-server 'xxx.xxx.8.8'
set service router-advert interface eth1 link-mtu '1492'
set service router-advert interface eth1 prefix ::/64 preferred-lifetime '2700'
set service router-advert interface eth1 prefix ::/64 valid-lifetime '5400'
set service ssh dynamic-protection
set service ssh port '22'
set system config-management commit-revisions '100'
set system conntrack modules ftp
set system conntrack modules h323
set system conntrack modules nfs
set system conntrack modules pptp
set system conntrack modules sip
set system conntrack modules sqlnet
set system conntrack modules tftp
set system console device ttyS0 speed '115200'
set system host-name xxxxxx
set system login user xxxxxx authentication encrypted-password xxxxxx
set system name-server 'xxx.xxx.0.1'
set system ntp server xxxxx.tld
set system ntp server xxxxx.tld
set system ntp server xxxxx.tld
set system syslog global facility all level 'info'
set system syslog global facility protocols level 'debug'
set system time-zone 'America/Sao_Paulo'
set vpn ipsec interface 'pppoe0'
set vpn l2tp remote-access authentication local-users username xxxxxx password xxxxxx
set vpn l2tp remote-access authentication mode 'local'
set vpn l2tp remote-access client-ip-pool start 'xxx.xxx.255.2'
set vpn l2tp remote-access client-ip-pool stop 'xxx.xxx.255.254'
set vpn l2tp remote-access ipsec-settings authentication mode 'pre-shared-secret'
set vpn l2tp remote-access ipsec-settings authentication pre-shared-secret xxxxxx
set vpn l2tp remote-access ipsec-settings lifetime '3600'
set vpn l2tp remote-access name-server 'xxx.xxx.8.8'
set vpn l2tp remote-access name-server 'xxx.xxx.1.1'
set vpn l2tp remote-access outside-address 'xxx.xxx.30.2'
set vrf