# apr/02/2024 10:53:30 by RouterOS 7.9.1
# software id =
#
/interface bridge
add name=bridge1
/interface wireguard
add listen-port=13299 mtu=1420 name=wireguard1
/interface wireless security-profiles
set [ find default=yes ] supplicant-identity=MikroTik
/ip pool
add name=dhcp_pool0 ranges=10.10.100.1-10.10.100.253
/ip dhcp-server
add address-pool=dhcp_pool0 interface=bridge1 name=dhcp1
/port
set 0 name=serial0
/interface bridge port
add bridge=bridge1 interface=ether2
add bridge=bridge1 interface=ether3
add bridge=bridge1 interface=ether4
add bridge=bridge1 interface=ether5
add bridge=bridge1 interface=ether6
/interface wireguard peers
add allowed-address=0.0.0.0/0 endpoint-address=192.168.216.135 endpoint-port=\
13299 interface=wireguard1 public-key=\
"sdfdsfsdfsd"
add allowed-address=0.0.0.0/0 endpoint-address=192.168.216.138 endpoint-port=\
13299 interface=wireguard1 public-key=\
"sdfdsfsdfsd="
add allowed-address=0.0.0.0/0 endpoint-address=192.168.216.136 endpoint-port=\
13299 interface=wireguard1 public-key=\
"sdfdsfsdfsd="
/ip address
add address=10.10.100.254/24 interface=bridge1 network=10.10.100.0
add address=172.16.0.100/24 interface=wireguard1 network=172.16.0.0
/ip dhcp-client
add interface=ether1
/ip dhcp-server network
add address=10.10.100.0/24 gateway=10.10.100.254
/ip firewall filter
add action=accept chain=input disabled=yes dst-port=13299 protocol=udp \
src-port=""
/ip route
add comment="Connection to xy" disabled=no distance=1 dst-address=\
10.20.100.0/24 gateway=wireguard1 pref-src="" routing-table=main scope=30 \
suppress-hw-offload=no target-scope=10
add comment="connection to zy" disabled=no distance=1 dst-address=\
10.30.100.0/24 gateway=wireguard1 pref-src="" routing-table=main scope=30 \
suppress-hw-offload=no target-scope=10
add disabled=no dst-address=10.40.100.0/24 gateway=wireguard1 routing-table=\
main suppress-hw-offload=no
/system identity
set name="MT SPINE WG"
/system note
set show-at-login=no
# apr/02/2024 10:53:44 by RouterOS 7.9.1
# software id =
#
/interface bridge
add name=bridge1
/interface wireguard
add listen-port=13299 mtu=1420 name=wireguard1
/interface wireless security-profiles
set [ find default=yes ] supplicant-identity=MikroTik
/ip pool
add name=dhcp_pool0 ranges=10.20.100.1-10.20.100.253
/ip dhcp-server
add address-pool=dhcp_pool0 interface=bridge1 name=dhcp1
/port
set 0 name=serial0
/interface bridge port
add bridge=bridge1 interface=ether2
add bridge=bridge1 interface=ether3
add bridge=bridge1 interface=ether4
/interface wireguard peers
add allowed-address=0.0.0.0/0 endpoint-address=192.168.216.137 endpoint-port=\
13299 interface=wireguard1 public-key=\
"papapapaapa"
/ip address
add address=10.20.100.254/24 interface=bridge1 network=10.20.100.0
add address=172.16.0.200/24 interface=wireguard1 network=172.16.0.0
/ip dhcp-client
add interface=ether1
/ip dhcp-server network
add address=10.20.100.0/24 gateway=10.20.100.254
/ip firewall filter
add action=accept chain=input dst-port=13299 protocol=tcp
/ip route
add disabled=no distance=1 dst-address=10.10.100.0/24 gateway=wireguard1 \
pref-src="" routing-table=main scope=30 suppress-hw-offload=no \
target-scope=10
/system identity
set name="MT Leaf1 WG"
/system note
set show-at-login=no
# apr/02/2024 10:53:56 by RouterOS 7.9.1
# software id =
#
/interface bridge
add name=bridge1
/interface wireguard
add listen-port=13299 mtu=1420 name=wireguard1
/interface wireless security-profiles
set [ find default=yes ] supplicant-identity=MikroTik
/ip pool
add name=dhcp_pool1 ranges=10.30.100.1-10.30.100.253
/ip dhcp-server
add address-pool=dhcp_pool1 interface=bridge1 name=dhcp1
/port
set 0 name=serial0
/interface bridge port
add bridge=bridge1 interface=ether2
add bridge=bridge1 interface=ether3
add bridge=bridge1 interface=ether4
/interface wireguard peers
add allowed-address=0.0.0.0/0 endpoint-address=10.10.100.254 endpoint-port=\
13299 interface=wireguard1 public-key=\
"bkakakakakaa"
/ip address
add address=10.30.100.254/24 interface=bridge1 network=10.30.100.0
add address=172.16.0.110/24 interface=wireguard1 network=172.16.0.0
/ip dhcp-client
add interface=ether1
/ip dhcp-server network
add address=10.30.100.0/24 gateway=10.30.100.254
/ip firewall filter
add action=accept chain=input dst-port=13299 protocol=udp
/ip route
add disabled=no dst-address=10.10.100.0/24 gateway=wireguard1 routing-table=\
main suppress-hw-offload=no
/system identity
set name="MT Leaf2 WG"
/system note
set show-at-login=no
you mean... you have a 'ready to go' solution?just use zerotier + romon is much simpler and use routing if you need no reach LAN subnet, just my 0.2$
In-my-opinion , WireGuard is far easier to setup and far more efficent to run when KISS is applied .... but if you are a Rocket Scientist then ZeroTier is your cup of Tea.ZeroTier is easier to setup, but even if idle it ZeroTier does use more bandwidth than WG.
KISS = acronym “keep it simple” = ZeroTier ;- )
It's kinda "pick your poison" situation if you ask me. All involve some complexity. . Plus you need ARM-based routers for ZT, which can be a big blocker to using ZeroTier...In-my-opinion , WireGuard is far easier to setup and far more efficent to run when KISS is applied .... but if you are a Rocket Scientist then ZeroTier is your cup of Tea.ZeroTier is easier to setup, but even if idle it ZeroTier does use more bandwidth than WG.
how many aliases do you have anav?how easy is it to integrate PRO WG MGMT with MT devices??
# apr/03/2024 15:35:50 by RouterOS 7.9.1
# software id =
#
/interface bridge
add name=bridge1
/interface wireguard
add listen-port=13299 mtu=1420 name=wireguard-S
/interface list
add name=LAN
/interface wireless security-profiles
set [ find default=yes ] supplicant-identity=MikroTik
/ip pool
add name=dhcp_pool0 ranges=10.10.100.1-10.10.100.253
/ip dhcp-server
add address-pool=dhcp_pool0 interface=bridge1 name=dhcp1
/port
set 0 name=serial0
/interface bridge port
add bridge=bridge1 interface=ether5
add bridge=bridge1 interface=ether6
/interface list member
add interface=ether6 list=LAN
add interface=ether5 list=LAN
add interface=ether2 list=LAN
add interface=ether3 list=LAN
add interface=ether4 list=LAN
/interface wireguard peers
add allowed-address=172.16.0.200/32,10.20.100.0/24 comment=Leaf1 \
endpoint-address=192.168.216.135 endpoint-port=13299 interface=\
wireguard-S public-key="lalalalalala"
add allowed-address=172.16.0.110/32,10.30.100.0/24 comment=leaf2 \
endpoint-address=192.168.216.136 endpoint-port=13299 interface=\
wireguard-S public-key="lalalalalala="
add allowed-address=172.16.0.150/32,10.40.100.0/24 comment=leaf3 \
endpoint-address=192.168.216.138 endpoint-port=13299 interface=\
wireguard-S public-key="lalalalalala="
/ip address
add address=10.10.100.254/24 interface=bridge1 network=10.10.100.0
add address=172.16.0.100/24 interface=wireguard-S network=172.16.0.0
/ip dhcp-client
add interface=ether1
/ip dhcp-server network
add address=10.10.100.0/24 gateway=10.10.100.254
/ip firewall filter
add action=accept chain=input dst-port=13299 protocol=udp src-port=""
add action=accept chain=forward in-interface-list=LAN out-interface=\
wireguard-S
/ip route
add comment="Connection to leaf1" disabled=no distance=1 dst-address=\
10.20.100.0/24 gateway=wireguard-S pref-src="" routing-table=main scope=\
30 suppress-hw-offload=no target-scope=10
add comment="connection to leaf2" disabled=no distance=1 dst-address=\
10.30.100.0/24 gateway=wireguard-S pref-src="" routing-table=main scope=\
30 suppress-hw-offload=no target-scope=10
add comment=leaf3 disabled=no distance=1 dst-address=10.40.100.0/24 gateway=\
wireguard-S pref-src="" routing-table=main scope=30 suppress-hw-offload=\
no target-scope=10
add comment="connection to leaf2" disabled=no distance=1 dst-address=\
10.40.100.0/24 gateway=wireguard-S pref-src="" routing-table=main scope=\
30 suppress-hw-offload=no target-scope=10
/system identity
set name="MT SPINE WG"
/system note
set show-at-login=no
# apr/03/2024 15:35:27 by RouterOS 7.9.1
# software id =
#
/interface bridge
add name=bridge1
/interface wireguard
add listen-port=13299 mtu=1420 name=wireguard-leaf1
/interface list
add name=LAN
/interface wireless security-profiles
set [ find default=yes ] supplicant-identity=MikroTik
/ip pool
add name=dhcp_pool0 ranges=10.20.100.1-10.20.100.253
/ip dhcp-server
add address-pool=dhcp_pool0 interface=bridge1 name=dhcp1
/port
set 0 name=serial0
/interface bridge port
add bridge=bridge1 interface=ether3
add bridge=bridge1 interface=ether4
/interface list member
add interface=ether4 list=LAN
add interface=ether3 list=LAN
add interface=ether2 list=LAN
/interface wireguard peers
add allowed-address=0.0.0.0/0 comment="connect to Spine" endpoint-address=\
192.168.216.137 endpoint-port=13299 interface=wireguard-leaf1 \
persistent-keepalive=45s public-key="lalalalalalala="
/ip address
add address=10.20.100.254/24 interface=bridge1 network=10.20.100.0
add address=172.16.0.200/24 interface=wireguard-leaf1 network=172.16.0.0
/ip dhcp-client
add interface=ether1
/ip dhcp-server network
add address=10.20.100.0/24 gateway=10.20.100.254
/ip route
add disabled=no distance=1 dst-address=10.10.100.0/24 gateway=wireguard-leaf1 \
pref-src="" routing-table=main scope=30 suppress-hw-offload=no \
target-scope=10
/system identity
set name="MT Leaf1 WG"
/system note
set show-at-login=no
# apr/03/2024 15:34:46 by RouterOS 7.9.1
# software id =
#
/interface bridge
add name=bridge1
/interface wireguard
add listen-port=13299 mtu=1420 name=wireguard-leaf2
/interface list
add name=LAN
/interface wireless security-profiles
set [ find default=yes ] supplicant-identity=MikroTik
/ip pool
add name=dhcp_pool1 ranges=10.30.100.1-10.30.100.253
/ip dhcp-server
add address-pool=dhcp_pool1 interface=bridge1 name=dhcp1
/port
set 0 name=serial0
/interface bridge port
add bridge=bridge1 interface=ether3
add bridge=bridge1 interface=ether4
/interface list member
add interface=ether2 list=LAN
add interface=ether3 list=LAN
add interface=ether4 list=LAN
/interface wireguard peers
add allowed-address=0.0.0.0/0 endpoint-address=192.168.216.137 endpoint-port=\
13299 interface=wireguard-leaf2 persistent-keepalive=45s public-key="lalalalala="
/ip address
add address=10.30.100.254/24 interface=bridge1 network=10.30.100.0
add address=172.16.0.110/24 interface=wireguard-leaf2 network=172.16.0.0
/ip dhcp-client
add interface=ether1
/ip dhcp-server network
add address=10.30.100.0/24 dns-server=10.30.100.254 gateway=10.30.100.254
/ip route
add disabled=no dst-address=10.10.100.0/24 gateway=wireguard-leaf2 \
routing-table=main suppress-hw-offload=no
/system identity
set name="MT Leaf2 WG"
/system note
set show-at-login=no
1. I was guided by the logic that if the interface is under wireguard, then it should not be in the bridge.Is this assumption wrong?Attention to detail my friend!
SPINE
1. You need to add ether 2,3,4 to the bridge ports! ( assuming they are part of your LAN as you have no other ports or addressess delineated )
2. If the Spine is behind another router fine, if not, pull the ethernet cable from the modem, as you have no firewall rules and its not secure.
With no firewall rules entered, the default is allow everything .
Leaf1
3. Suggest add ether2 to bridge maybe?? ( as I dont know the purpose of ether2)
Leaf2
4. Suggest add ether2 to bridge maybe?? ( as I dont know the purpose of ether2)
+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
In terms of WIREGUARD SETUP, some disturbing entries that I didnt suggest/include so not sure what you are doing??
SPINE:
Allowed IPs does NOT contain endpoint address or port for client peers............. remove them
/interface wireguard peers
add allowed-address=172.16.0.200/32,10.20.100.0/24 comment=Leaf1 \
endpoint-address=192.168.216.135 endpoint-port=13299 interface=\
wireguard-S public-key="lalalalalala"
add allowed-address=172.16.0.110/32,10.30.100.0/24 comment=leaf2 \
endpoint-address=192.168.216.136 endpoint-port=13299 interface=\
wireguard-S public-key="lalalalalala="
add allowed-address=172.16.0.150/32,10.40.100.0/24 comment=leaf3 \
endpoint-address=192.168.216.138 endpoint-port=13299 interface=\
wireguard-S public-key="lalalalalala="
should be
/interface wireguard peers
add allowed-address=172.16.0.200/32,10.20.100.0/24 comment=Leaf1 \
interface=wireguard-S public-key="lalalalalal="
add allowed-address=172.16.0.110/32,10.30.100.0/24 comment=leaf2 \
interface=wireguard-S public-key="ckckckckc="
add allowed-address=172.16.0.150/32,10.40.100.0/24 comment=leaf3 \
interface=wireguard-S public-key="pqpqpqpqp="
LEAF1 and LEAF2
Your endpoint address is wrong, It needs to point to the publicly reachable address of the SPine Router.
a. if its static it should be X.X.X.X
b. if its dynamic, then a dyndns address like the IP cloud name for exampl.e
/interface wireguard peers
add allowed-address=0.0.0.0/0 comment="connect to Spine" endpoint-address=\
192.168.216.137 endpoint-port=13299 interface=wireguard-leaf1 \
persistent-keepalive=45s public-key="lalalalalalala="
/interface wireguard peers
add allowed-address=0.0.0.0/0 endpoint-address=192.168.216.137 endpoint-port=\
13299 interface=wireguard-leaf2 persistent-keepalive=45s public-key="lalalalala="
JUST a reminder that with WireGuard -- KISS - Simple & Easy-to-useThis has nothing to with your attempt to assign wireguard to ports vice users/devices etc...
What you are talking now is simply to access remote routers for config purposes.
If you also need to access subnets at remote devices that will require a bit more work but not that much.
Cryptokey RoutingThere is no need to manage connections, be concerned about state, manage daemons, or worry about what's under the hood. WireGuard presents an extremely basic yet powerful interface.
Because all packets sent on the WireGuard interface are encrypted and authenticated, and because there is such a tight coupling between the identity of a peer and the allowed IP address of a peer, system administrators do not need complicated firewall extensions, such as in the case of IPsec, but rather they can simply match on "is it from this IP? on this interface?", and be assured that it is a secure and authentic packet. This greatly simplifies network management and access control, and provides a great deal more assurance that your iptables rules are actually doing what you intended for them to do.
That's a bit unfair. But these "protocol wars" are silly. e.g.another example of the eternal crusade of the evangelists of Zerotier, acting like there is no other VPN type in the world
the hype for something new in a race to deprecate anything previously existent
“If the only tool you have is a hammer, you tend to see every problem as a nail."JUST a reminder that with WireGuard -- KISS - Simple & Easy-to-use