Skip to content

Instantly share code, notes, and snippets.

View neroxps's full-sized avatar

MarkDownPhotos neroxps

View GitHub Profile
# Support multiple wan port mapping
# 1. Configure the firewall and change the LAN address (192.168.2.2)
# 2. Add the update_wanip script.
# 3. Execute once a minute update_wanip
/ip firewall nat
add action=dst-nat chain=dstnat comment=https dst-port=1443 protocol=tcp to-addresses=192.168.2.2 to-ports=443
add action=dst-nat chain=dstnat comment="https loopback dnat" dst-address-list=wan-ip dst-port=1443 log-prefix=loopback protocol=tcp \
src-address-list=lan-ip to-addresses=192.168.2.2 to-ports=443
# loopback needs masquerade