Hey all!
I have a raspberry pi 4 with an extra USB dongle serving as my router and I wanted to use my SamKnows Whitebox 8 as a managed switch (both running OpenWRT). I just need one of the ports of the SamKnows Whitebox 8 to connect to a VPN instead of my main VLAN and that is exactly what is not working for me.
I’ve tried to configure the WAN port as trunk and also one of the lan ports, but when I connect a device to the VPN port I never get and IP, so I have no internet at all.
This is my raspberry pi:
config interface 'loopback'
option device 'lo'
option proto 'static'
option ipaddr '127.0.0.1'
option netmask '255.0.0.0'
config globals 'globals'
option ula_prefix 'fdc3:a5f5:27de::/48'
option packet_steering '1'
config device
option name 'br-lan'
option type 'bridge'
list ports 'eth0'
config interface 'lan'
option device 'br-lan'
option proto 'static'
option ipaddr '192.168.28.1'
option netmask '255.255.255.0'
config interface 'WAN'
option proto 'dhcp'
option device 'eth1'
config interface 'tailscale'
option proto 'none'
option device 'tailscale0'
config interface 'vpn_lan'
option proto 'static'
option device 'br-lan.38'
option ipaddr '192.168.38.1'
option netmask '255.255.255.0'
config interface 'pia_tun'
option proto 'none'
option device 'tun0'
and this is my SamKnows Whitebox 8:
config interface 'loopback'
option device 'lo'
option proto 'static'
option ipaddr '127.0.0.1'
option netmask '255.0.0.0'
config globals 'globals'
option ula_prefix 'fdb0:e34:f::/48'
option packet_steering '0'
config device
option name 'br-lan'
option type 'bridge'
option vlan_filtering '0'
list ports 'lan1'
list ports 'lan2'
list ports 'lan3'
list ports 'lan4'
config interface 'lan'
option device 'br-lan'
option proto 'static'
option ipaddr '192.168.28.254'
option netmask '255.255.255.0'
option ip6assign '60'
option gateway '192.168.28.1'
list dns '192.168.28.1'
config device 'brlan38_dev'
option name 'br-lan.38'
option type '8021q'
option ifname 'br-lan'
option vid '38'
config device 'vpn_dev'
option name 'br-vpn'
option type 'bridge'
list ports 'br-lan.38'
list ports 'wan'
config interface 'vpn'
option device 'br-vpn'
option proto 'none'
option auto '1'
option force_link '1'
the firewall on my raspberry pi:
config defaults
option input 'REJECT'
option output 'ACCEPT'
option forward 'REJECT'
option synflood_protect '1'
option flow_offloading '1'
option drop_invalid '1'
config zone
option name 'lan'
option input 'ACCEPT'
option output 'ACCEPT'
option forward 'ACCEPT'
list network 'lan'
config zone
option name 'wan'
option input 'REJECT'
option output 'ACCEPT'
option forward 'REJECT'
option masq '1'
option mtu_fix '1'
list network 'wan'
list network 'wan6'
list network 'WAN'
config forwarding
option src 'lan'
option dest 'wan'
config rule
option name 'Allow-DHCP-Renew'
option src 'wan'
option proto 'udp'
option dest_port '68'
option target 'ACCEPT'
option family 'ipv4'
config rule
option name 'Allow-Ping'
option src 'wan'
option proto 'icmp'
option icmp_type 'echo-request'
option family 'ipv4'
option target 'ACCEPT'
config rule
option name 'Allow-IGMP'
option src 'wan'
option proto 'igmp'
option family 'ipv4'
option target 'ACCEPT'
config rule
option name 'Allow-DHCPv6'
option src 'wan'
option proto 'udp'
option dest_port '546'
option family 'ipv6'
option target 'ACCEPT'
config rule
option name 'Allow-MLD'
option src 'wan'
option proto 'icmp'
option src_ip 'fe80::/10'
list icmp_type '130/0'
list icmp_type '131/0'
list icmp_type '132/0'
list icmp_type '143/0'
option family 'ipv6'
option target 'ACCEPT'
config rule
option name 'Allow-ICMPv6-Input'
option src 'wan'
option proto 'icmp'
list icmp_type 'echo-request'
list icmp_type 'echo-reply'
list icmp_type 'destination-unreachable'
list icmp_type 'packet-too-big'
list icmp_type 'time-exceeded'
list icmp_type 'bad-header'
list icmp_type 'unknown-header-type'
list icmp_type 'router-solicitation'
list icmp_type 'neighbour-solicitation'
list icmp_type 'router-advertisement'
list icmp_type 'neighbour-advertisement'
option limit '1000/sec'
option family 'ipv6'
option target 'ACCEPT'
config rule
option name 'Allow-ICMPv6-Forward'
option src 'wan'
option dest '*'
option proto 'icmp'
list icmp_type 'echo-request'
list icmp_type 'echo-reply'
list icmp_type 'destination-unreachable'
list icmp_type 'packet-too-big'
list icmp_type 'time-exceeded'
list icmp_type 'bad-header'
list icmp_type 'unknown-header-type'
option limit '1000/sec'
option family 'ipv6'
option target 'ACCEPT'
config rule
option name 'Allow-IPSec-ESP'
option src 'wan'
option dest 'lan'
option proto 'esp'
option target 'ACCEPT'
config rule
option name 'Allow-ISAKMP'
option src 'wan'
option dest 'lan'
option dest_port '500'
option proto 'udp'
option target 'ACCEPT'
config redirect 'adblock_lan53'
option name 'Adblock DNS (lan, 53)'
option src 'lan'
option proto 'tcp udp'
option src_dport '53'
option dest_port '53'
option target 'DNAT'
option family 'any'
config zone
option name 'tailscale_fw'
option input 'ACCEPT'
option output 'ACCEPT'
option forward 'ACCEPT'
option masq '1'
option mtu_fix '1'
list network 'tailscale'
config forwarding
option src 'tailscale_fw'
option dest 'lan'
config forwarding
option src 'tailscale_fw'
option dest 'wan'
config forwarding
option src 'lan'
option dest 'tailscale_fw'
config zone
option name 'vpn_fw'
option input 'ACCEPT'
option output 'ACCEPT'
option forward 'REJECT'
list network 'vpn_lan'
config zone
option name 'vpn_wan'
option input 'REJECT'
option output 'ACCEPT'
option forward 'REJECT'
list network 'pia_tun'
option masq '1'
option mtu_fix '1'
config forwarding
option src 'vpn_fw'
option dest 'vpn_wan'
Do you need to see anything else?
Thank you so much in advance!