You are on page 1of 3

/ip firewall mangle

add action=mark-connection chain=prerouting comment="PLAN RESIDENCIAL 5 MEGAS" new-


connection-mark=conn_residencial5 passthrough=yes src-address-
list=PLAN_RESIDENCIAL_5M
add action=mark-packet chain=prerouting connection-mark=conn_residencial5 dst-
port="" new-packet-mark=pack_residencial5_www passthrough=no port=80,443
protocol=tcp
add action=mark-packet chain=prerouting connection-mark=conn_residencial5 dst-
port="" new-packet-mark=pack_residencial5_dns passthrough=no port=53 protocol=tcp
add action=mark-packet chain=prerouting connection-mark=conn_residencial5 dst-
port="" new-packet-mark=pack_residencial5_dns_udp passthrough=no port=53
protocol=udp
add action=mark-packet chain=prerouting connection-mark=conn_residencial5 dst-
port="" new-packet-mark=pack_residencial5_correo passthrough=no
port=25,110,993,995,587 \
protocol=tcp
add action=mark-packet chain=prerouting connection-mark=conn_residencial5 new-
packet-mark=pack_residencial5_icmp passthrough=no protocol=icmp
add action=mark-packet chain=prerouting connection-mark=conn_residencial5 dst-
address-list=REDES_SOCIALES new-packet-mark=pack_residencial5_redes
passthrough=no \
src-address-list=""
add action=mark-packet chain=prerouting connection-mark=conn_residencial5 dst-
address-list=VIDEOS new-packet-mark=pack_residencial5_videos passthrough=no
add action=mark-packet chain=prerouting connection-mark=conn_residencial5 new-
packet-mark=pack_residencial5_resto passthrough=no

/ip firewall address-list


add address=192.168.30.2 list=PLAN_RESIDENCIAL_5M
add address=192.168.30.100 list=PLAN_RESIDENCIAL_10M
add address=192.168.30.3 list=PLAN_RESIDENCIAL_5M
add address=192.168.30.4 list=PLAN_RESIDENCIAL_5M
add address=192.168.30.5 list=PLAN_RESIDENCIAL_5M
add address=192.168.30.101 list=PLAN_RESIDENCIAL_10M
add address=192.168.30.102 list=PLAN_RESIDENCIAL_10M
add address=192.168.30.103 list=PLAN_RESIDENCIAL_10M
add address=www.facebbok.com list=REDES_SOCIALES
add address=m.facebbok.com list=REDES_SOCIALES
add address=www.instagram.com list=REDES_SOCIALES
add address=web.whatsapp.com list=REDES_SOCIALES
add address=m.youtube.com list=VIDEOS
add address=www.youtube.com list=VIDEOS

add max-limit=160M name=DOWN_TOTAL parent=LAN


add limit-at=30M max-limit=100M name=DESCARGA_PLAN_HOGAR_5M parent=DOWN_TOTAL
add limit-at=1M max-limit=5M name=DESCARGA_PLAN_HOGAR_VIDEOS packet-mark=\
pack_residencial5_videos parent=DESCARGA_PLAN_HOGAR_5M queue=PCQ_DOWN
add limit-at=512k max-limit=5M name=DESCARGA_PLAN_HOGAR_CORREOS packet-mark=\
pack_residencial5_correo parent=DESCARGA_PLAN_HOGAR_5M queue=PCQ_DOWN
add limit-at=50k max-limit=300k name=DESCARGA_PLAN_HOGAR_ICMP packet-mark=\
pack_residencial5_icmp parent=DESCARGA_PLAN_HOGAR_5M queue=PCQ_DOWN
add limit-at=1M max-limit=5M name=DESCARGA_PLAN_HOGAR_REDES packet-mark=\
pack_residencial5_redes parent=DESCARGA_PLAN_HOGAR_5M queue=PCQ_DOWN
add limit-at=1M max-limit=5M name=DESCARGA_PLAN_HOGAR_RESTO packet-mark=\
pack_residencial5_resto parent=DESCARGA_PLAN_HOGAR_5M queue=PCQ_DOWN
add limit-at=1M max-limit=5M name=DESCARGA_PLAN_HOGAR_WWW packet-mark=\
pack_residencial5_www parent=DESCARGA_PLAN_HOGAR_5M queue=PCQ_DOWN
add limit-at=1M max-limit=5M name=DESCARGA_PLAN_HOGAR_DNS packet-mark=\
pack_residencial5_dns parent=DESCARGA_PLAN_HOGAR_5M queue=PCQ_DOWN
add limit-at=1M max-limit=5M name=DESCARGA_PLAN_HOGAR_UDP packet-mark=\
pack_residencial5_dns_udp parent=DESCARGA_PLAN_HOGAR_5M queue=PCQ_DOWN

add max-limit=160M name=UP_TOTAL parent=LAN


add limit-at=30M max-limit=100M name=CARGA_PLAN_HOGAR_5M parent=UP_TOTAL
add limit-at=1M max-limit=5M name=CARGA_PLAN_HOGAR_VIDEOS packet-mark=\
pack_residencial5_videos parent=CARGA_PLAN_HOGAR_5M queue=PCQ_UP
add limit-at=512k max-limit=5M name=CARGA_PLAN_HOGAR_CORREOS packet-mark=\
pack_residencial5_correo parent=CARGA_PLAN_HOGAR_5M queue=PCQ_UP
add limit-at=50k max-limit=300k name=CARGA_PLAN_HOGAR_ICMP packet-mark=\
pack_residencial5_icmp parent=CARGA_PLAN_HOGAR_5M queue=PCQ_UP
add limit-at=1M max-limit=5M name=CARGA_PLAN_HOGAR_REDES packet-mark=\
pack_residencial5_redes parent=CARGA_PLAN_HOGAR_5M queue=PCQ_UP
add limit-at=1M max-limit=5M name=CARGA_PLAN_HOGAR_RESTO packet-mark=\
pack_residencial5_resto parent=CARGA_PLAN_HOGAR_5M queue=PCQ_UP
add limit-at=1M max-limit=5M name=CARGA_PLAN_HOGAR_WWW packet-mark=\
pack_residencial5_www parent=CARGA_PLAN_HOGAR_5M queue=PCQ_UP
add limit-at=1M max-limit=5M name=CARGA_PLAN_HOGAR_DNS packet-mark=\
pack_residencial5_dns parent=CARGA_PLAN_HOGAR_5M queue=PCQ_UP
add limit-at=1M max-limit=5M name=CARGA_PLAN_HOGAR_UDP packet-mark=\
pack_residencial5_dns_udp parent=CARGA_PLAN_HOGAR_5M queue=PCQ_UP

add action=mark-connection chain=prerouting comment="PLAN RESIDENCIAL 10 MEGAS"


new-connection-mark=conn_residencial5 passthrough=yes src-address-
list=PLAN_RESIDENCIAL_5M
add action=mark-packet chain=prerouting connection-mark=conn_residencial10 dst-
port="" new-packet-mark=pack_residencial5_www passthrough=no port=80,443
protocol=tcp
add action=mark-packet chain=prerouting connection-mark=conn_residencial10 dst-
port="" new-packet-mark=pack_residencial5_dns passthrough=no port=53 protocol=tcp
add action=mark-packet chain=prerouting connection-mark=conn_residencial10 dst-
port="" new-packet-mark=pack_residencial5_dns_udp passthrough=no port=53
protocol=udp
add action=mark-packet chain=prerouting connection-mark=conn_residencial10 dst-
port="" new-packet-mark=pack_residencial5_correo passthrough=no
port=25,110,993,995,587 \
protocol=tcp
add action=mark-packet chain=prerouting connection-mark=conn_residencial10 new-
packet-mark=pack_residencial5_icmp passthrough=no protocol=icmp
add action=mark-packet chain=prerouting connection-mark=conn_residencial10 dst-
address-list=REDES_SOCIALES new-packet-mark=pack_residencial5_redes
passthrough=no \
src-address-list=""
add action=mark-packet chain=prerouting connection-mark=conn_residencial10 dst-
address-list=VIDEOS new-packet-mark=pack_residencial5_videos passthrough=no
add action=mark-packet chain=prerouting connection-mark=conn_residencial10 new-
packet-mark=pack_residencial5_resto passthrough=no

add action=mark-routing chain=prerouting comment="RESIDENCIAL 5 MEGAS" new-routing-


mark=conn-res-5m passthrough=yes src-address-list=PLAN_RESIDENCIAL_5M
add action=mark-packet chain=prerouting connection-mark=conn_residencial5 new-
packet-mark=pack-res-5m passthrough=no

You might also like