Hello forum, and Happy New Year
For a while I've been playing with a MT RB750GR3, running 7.1. I've managed to get an IPSEC VPN going for my IP phone to connect to the office and I was able to get a Wireguard VPN going that still needs some work, but that is not my concern at the moment.
Since I only have access to one managed PoE (DLINK) switch, it is segmented (VLAN'd) off into five VLANS:
VLAN 10 - 192.168.10.0/24 - LAN
VLAN 20 - 192.168.20.0/24 - Wifi
VLAN 30 - 192.168.30.0/24 - Guest Wifi
VLAN 40 - 192.168.40.0/24 - Voice
VLAN 50 - 192.168.40.0/24 - Spouse's "work from home" network
The above VLANs use a total of 9 access ports on the switch. The 10th and last port is a trunk port on the switch that connects to the MT on ethernet 2. Essentially, I have created a ROS set up, however, I need to stop traffic
between the VLANs, with the exception of VLAN 10 needing access to everything since I will use my PC on that subnet to manage Access Points on the other VLANs/subnets.
To complicate matters, I have setup Pi-hole on a raspberry Pi. All networks use its IP address, 192.168.10.11, for DNS. With tutorials and articles online, I was able to set it up that no matter what a (savvy) user would change on their system, they will always wind up using Pi-hole for DNS. I would like this to stay the same also, so that doesn't make things easier, I think.
The articles I've read so far are confusing to me in that I don't know if my model of MT should be able to separate the traffic between the VLANs in this ROS setup, or not? If it should automatically do so, something is definitely wrong in my configuration.
And I have not created a bridge. Articles I've read (
https://wiki.mikrotik.com/wiki/Manual:Bridge_VLAN_Table) shows a diagram of what looks like to be a ROS setup but then the configuration steps go on to say:
/interface bridge port
add bridge=bridge1 interface=ether1
add bridge=bridge1 interface=ether2 pvid=20
add bridge=bridge1 interface=ether3 pvid=30
... which is confusing the heck out of me - why are now more than one interface involved, when only
one interface is involved in a ROS setup?
I have tried to block traffic between ie. VLAN 10 and VLAN 20 by adding the following, without success in blocking the traffic from VLAN 20 to VLAN 10:
action=drop chain=forward connection-nat-state="" connection-state=new dst-address=192.168.10.0/24 src-address=192.168.20.0/24
I would like to know if I should be creating a bridge when only one interface is being used, or am I going about this the wrong way altogether? Clearly I am missing some important steps, but I can't wrap my head around what I am not doing, or doing correct.
Here is my complete current configuration (added comments and spaces in between sections for clarity)
#==========================================================
# jan/03/2022 11:56:09 by RouterOS 7.1
# software id = 72VR-1FM3
#
# model = RB750Gr3
# serial number = D5030E3E8970
/interface ethernet
set [ find default-name=ether1 ] name=ether1-WAN
set [ find default-name=ether5 ] comment="Management port" name=ether5-access
/interface wireguard
add listen-port=13231 mtu=1420 name=wireguard1
#VLAN interfaces:
/interface vlan
add interface=ether2 name=GuestWifi vlan-id=30
add interface=ether2 name=LAN vlan-id=10
add interface=ether2 name=Phone vlan-id=40
add interface=ether2 name=Spouse-work vlan-id=50
add interface=ether2 name=Wifi vlan-id=20
/interface lte apn
set [ find default=yes ] ip-type=ipv4
/interface wireless security-profiles
set [ find default=yes ] supplicant-identity=MikroTik
# IPSEC section;
/ip ipsec peer
add address=184.69.46.238/32 local-address=184.68.82.26 name=XXXXXXXXXX
/ip ipsec profile
set [ find default=yes ] dh-group=modp1024 dpd-interval=10s enc-algorithm=3des hash-algorithm=md5 lifetime=8h name=XXXXXXXXXX nat-traversal=no
/ip ipsec proposal
set [ find default=yes ] disabled=yes
add enc-algorithms=3des lifetime=8h name=XXXXXXXXXX
/ip pool
add comment=VLAN-10 name=LAN ranges=192.168.10.40-192.168.10.60
add comment=Management name=Ether5-access ranges=192.168.100.10-192.168.100.20
add comment=VLAN-20 name=Wifi ranges=192.168.20.2-192.168.20.254
add comment=VLAN-30 name=GuestWifi ranges=192.168.30.2-192.168.30.254
add comment=VLAN-40 name=Phone ranges=192.168.40.2-192.168.40.254
add comment=VLAN-50 name=Spouse-work ranges=192.168.50.2-192.168.50.254
/ip dhcp-server
add address-pool=LAN interface=LAN name=LAN
add address-pool=Ether5-access interface=ether5-access name=dhcp1
add address-pool=Wifi interface=Wifi name=Wifi
add address-pool=GuestWifi interface=GuestWifi name=GuestWifi
add address-pool=Phone interface=Phone name=Phone
add address-pool=Spouse-work interface=Spouse-work name=dhcp2
/port
set 0 name=serial0
/routing bgp template
set default as=65530 disabled=no name=default output.network=bgp-networks
/routing ospf instance
add name=default-v2
/routing ospf area
add disabled=yes instance=default-v2 name=backbone-v2
/ipv6 settings
set disable-ipv6=yes max-neighbor-entries=8192
/interface wireguard peers
add allowed-address=192.168.60.2/24,192.168.60.3/24 interface=wireguard1 public-key="XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX="
/ip address
add address=172.16.16.1/24 disabled=yes interface=ether5-access network=172.16.16.0
add address=192.168.10.1/24 interface=LAN network=192.168.10.0
add address=192.168.20.1/24 interface=Wifi network=192.168.20.0
add address=192.168.30.1/24 interface=GuestWifi network=192.168.30.0
add address=192.168.40.1/24 interface=Phone network=192.168.40.0
add address=192.168.50.1/24 interface=Spouse-work network=192.168.50.0
add address=192.168.60.1/24 interface=wireguard1 network=192.168.60.0
add address=184.68.82.26/29 interface=ether1-WAN network=184.68.82.24
add address=192.168.100.1/24 interface=ether5-access network=192.168.100.0
/ip dhcp-server lease
add address=192.168.10.4 client-id=1:18:c0:4d:26:b8:1d comment="Marcel's PC" mac-address=18:C0:4D:26:B8:1D server=LAN
add address=192.168.10.2 client-id=ff:5e:4f:ac:2d:0:1:0:1:29:60:9d:fc:e0:d5:5e:4f:ac:2d comment="File server" mac-address=E0:D5:5E:4F:AC:2D server=LAN
/ip dhcp-server network
add address=192.168.10.0/24 dns-server=192.168.10.11 gateway=192.168.10.1
add address=192.168.20.0/24 dns-server=192.168.10.11 gateway=192.168.20.1
add address=192.168.30.0/24 dns-server=192.168.10.11 gateway=192.168.30.1
add address=192.168.40.0/24 dns-server=192.168.10.11 gateway=192.168.40.1
add address=192.168.50.0/24 dns-server=192.168.10.11 gateway=192.168.50.1
add address=192.168.100.0/24 dns-server=8.8.8.8 gateway=192.168.100.1
/ip dns
set servers=192.168.10.11
/ip firewall filter
add action=accept chain=input dst-port=13231 protocol=udp
add action=accept chain=forward
add action=drop chain=forward connection-nat-state="" connection-state=new dst-address=192.168.10.0/24 src-address=192.168.20.0/24
add action=drop chain=forward connection-nat-state="" connection-state=new dst-address=192.168.10.0/24 src-address=192.168.30.0/24
add action=drop chain=forward connection-state=established dst-address=192.168.10.0/24 src-address=192.168.40.0/24
add action=drop chain=forward connection-state=established dst-address=192.168.10.0/24 src-address=192.168.50.0/24
add action=drop chain=forward disabled=yes dst-address=192.168.10.0/24 src-address=192.168.60.0/24
/ip firewall nat
add action=accept chain=srcnat comment="IP phone NAT rule" dst-address=10.1.2.0/24 src-address=192.168.40.0/24
add action=masquerade chain=srcnat comment="LAN to Internet MASQuerading"
add action=dst-nat chain=dstnat comment=Pihole dst-address=!192.168.10.11 dst-port=53 in-interface=!ether1-WAN protocol=udp src-address=!192.168.10.11 to-addresses=192.168.10.11
add action=dst-nat chain=dstnat comment=Pihole dst-address=!192.168.10.11 dst-port=53 in-interface=!ether1-WAN protocol=tcp src-address= !192.168.10.11 to-addresses=192.168.10.11
add action=masquerade chain=srcnat comment=Pihole dst-address=192.168.10.11 dst-port=53 protocol=udp src-address=192.168.10.0/24
add action=masquerade chain=srcnat comment=Pihole dst-address=192.168.10.11 dst-port=53 protocol=tcp src-address=192.168.10.0/24
#This is added for the IP phone to have two-way voice traffic:
/ip firewall raw
add action=notrack chain=prerouting dst-address=10.1.2.0/24 src-address=192.168.40.0/24
add action=notrack chain=prerouting dst-address=192.168.40.0/24 src-address=10.1.2.0/24
/ip firewall service-port
set ftp disabled=yes
set tftp disabled=yes
set irc disabled=yes
set h323 disabled=yes
set sip disabled=yes
set pptp disabled=yes
set udplite disabled=yes
set dccp disabled=yes
set sctp disabled=yes
/ip ipsec identity
add peer=XXXXXXXXXX
/ip ipsec policy
add dst-address=10.1.2.0/24 peer=XXXXXXXXXX proposal=XXXXXXXXXX src-address=192.168.40.0/24 tunnel=yes
set 1 disabled=yes
/ip route
add disabled=no distance=1 dst-address=0.0.0.0/0 gateway=184.68.82.25 pref-src="" routing-table=main scope=30 suppress-hw-offload=no target-scope=10
/ip service
set telnet disabled=yes
set ftp disabled=yes
set www disabled=yes
set ssh disabled=yes
set api disabled=yes
set api-ssl disabled=yes
/system clock
set time-zone-name=America/Winnipeg
/tool sniffer
set file-name=Wireshark filter-interface=ether1-WAN memory-limit=1000KiB
#==========================================================
Thank you in advance for taking the time to point me in the right direction.