bertinho79
Usuari@ ADSLzone
- Mensajes
- 7
Un post te refieres a un tema nuevo o que exponga aquí mi problema? Porque esto último ya lo he hecho y he adjuntado el export también 
Sí, me refería a que abrieras un tema nuevo con tu problema, no a que asaltéis este constantemente.Un post te refieres a un tema nuevo o que exponga aquí mi problema? Porque esto último ya lo he hecho y he adjuntado el export también![]()
Efectivamente... era una tonteria lo que me faltaba jajaja. Ni mire eso porque al principio del tutorial ya pones que antes de nada hay que poner :local iptv y la ip, y eso hice pero no se el porque no me lo añade en esa tabla. Lo meti en ese apartado donde me dices.Sí, me refería a que abrieras un tema nuevo con tu problema, no a que asaltéis este constantemente.
No obstante, tu problema es sencillo (ya di con el export al que te referías): te falta la dirección de IPTV, no la tienes en IP > Address.
Además de lo anterior, te sugiero que te ciñas a direcciones de tipo C (192.168.x.y) para tu LAN, puesto que tu operador usa las de tipo B para su infraestructura.
Saludos!
Lo puedes mantener como lo tienes, pero te recomiendo usar direcciones de tipo 192.168.x.y para tu red local, y así evitas el problema de colisionar. Si miras tu tabla de rutas, verás que tu operador usa direcciones de tipo 10.x.y.z para voip e iptv, así como 172.23 para los emisores de tráfico multicast. Por eso no es bueno usar direcciones de esos segmentos, a menos que sepas a ciencia cierta que no se usan por parte de tu operador par nada.Efectivamente... era una tonteria lo que me faltaba jajaja. Ni mire eso porque al principio del tutorial ya pones que antes de nada hay que poner :local iptv y la ip, y eso hice pero no se el porque no me lo añade en esa tabla. Lo meti en ese apartado donde me dices.
En cuando a usar direcciones tipo C porque es recomendable? en que me puede afectar si lo mantengo asi?
Un saludo y muchisimas gracias de nuevo! estaba desesperado ya.
Si tu red doméstica es simple, probablemente no sólo no la hay, sino que es un cristo importante el cambio, dado que los parámetros de conexión no son de dominio público unes un dolor de cabeza sacarlos. Si a eso sumas cambiar un equipo (router todo en uno) por tres (ont + router + ata-sip), y que te quedas sin el soporte por parte del operador, al dejar de usar los equipos que él ha certificado para su red, cada vez se diluye más y más dicha ventaja.Buenas,
Después de unos días haciendo pruebas, la configuración que me ha pasado POCOYO va de cine, vamos sin ningún problema en internet y ningún problema en iptv, tanto en directo como en U7D.
No consigo de ninguna manera que me funcione la Voip pero .... poco a poco.
Sin embargo, no encuentro mejoría ninguna en el funcionamiento de mi red de como lo tenía antes.
A saber, router de VF con la iptv y la voip y conectado al Mikrotik solo, el Router de VF con DMZ al mikrotik y este se encarga de toda la red de casa, hace de firewall, me actualiza la dirección dinamica, me gestiona el Harpin interno, etc.
Donde está la ventaja de poner el Mikrotik quitando el router de vodafone? vamos yo no la estoy viendo en mi caso.
Saludos,
Lo acabo de probar en un HGU recientemente actualizado (de mi "Paco") y aún no aparece ninguna IPv6.Hola @pokoyo
Parece que Movistar empieza a usar ipv6, entonces hay que añadirlo a la config del router.
¿Las mismas lineas de la config de ipv6 para digi, valdrían para Movistar?
Muchas gracias
Creo que necesitas una aplicación tipo Zoiper o similarNo sé si este seria el local correcto para esta consulta... pero el telefono fijo de mi casa ha muerto (dispositivo) y estoy pensando que ya es hora de matarlo de por vida... la cosa es, como configuro la VoIP en iphone? La idea llevarlo siempre en cima usando la vpn.
Tengo un RB4011 con wireguard ya configurado y el iphone conecta sin problema, la única duda ahora es en la configuración cliente y datos linea... ni idea por donde empezar...
# jan/28/2023 12:14:32 by RouterOS 7.7
# software id = XBIC-ERVV
#
# model = RB4011iGS+
/interface bridge
add admin-mac=18:FD:74:C2:A7:DB auto-mac=no comment=defconf \
ingress-filtering=no name=bridge vlan-filtering=yes
add ingress-filtering=no name=bridge1 vlan-filtering=yes
add name=bridgemng
/interface vlan
add interface=bridge name=vlan-domotica vlan-id=78
add interface=bridge name=vlan-home vlan-id=17
add interface=bridge name=vlan-invitados vlan-id=79
add interface=ether1 name=vlan3-telefono vlan-id=3
add interface=ether1 name=vlan6-internet vlan-id=6
/interface pppoe-client
add add-default-route=yes disabled=no interface=vlan6-internet name=internet \
use-peer-dns=yes user=adslppp@telefonicanetpa
/interface list
add comment=defconf name=WAN
add comment=defconf name=LAN
add name=ISOLATED
/interface lte apn
set [ find default=yes ] ip-type=ipv4 use-network-apn=no
/interface wireless security-profiles
set [ find default=yes ] supplicant-identity=MikroTik
/ip pool
add name=default-dhcp ranges=192.168.9.10-192.168.9.254
add name=dhcp-home ranges=192.168.17.10-192.168.17.254
add name=dhcp-domotica ranges=192.168.78.10-192.168.78.254
add name=dhcp-invitados ranges=192.168.79.10-192.168.79.254
add name=rescate ranges=192.168.86.20-192.168.86.35
/ip dhcp-server
add address-pool=default-dhcp interface=bridge name=defconf
add address-pool=dhcp-home interface=vlan-home name=dhcp-home
add address-pool=dhcp-domotica interface=vlan-domotica name=dhcp-domotica
add address-pool=dhcp-invitados interface=vlan-invitados name=dhcp-invitados
add address-pool=rescate interface=bridge1 name=dhcp-rescate
/port
set 0 name=serial0
set 1 name=serial1
/routing rip instance
add afi=ipv4 disabled=no name=rip
/interface bridge filter
# in/out-bridge-port matcher not possible when interface (vlan-domotica) is not slave
add action=drop chain=forward in-interface=vlan-domotica
# in/out-bridge-port matcher not possible when interface (vlan-domotica) is not slave
add action=drop chain=forward out-interface=vlan-domotica
/interface bridge port
add bridge=bridge comment=defconf ingress-filtering=no interface=ether2
add bridge=bridge comment=defconf ingress-filtering=no interface=ether3 pvid=\
17
add bridge=bridge comment=defconf ingress-filtering=no interface=ether4
add bridge=bridge comment=defconf ingress-filtering=no interface=ether5 pvid=\
78
add bridge=bridge comment=defconf frame-types=\
admit-only-untagged-and-priority-tagged ingress-filtering=no interface=\
ether6 pvid=17
add bridge=bridge comment=defconf frame-types=\
admit-only-untagged-and-priority-tagged ingress-filtering=no interface=\
ether7 pvid=17
add bridge=bridge comment=defconf frame-types=\
admit-only-untagged-and-priority-tagged ingress-filtering=no interface=\
ether8 pvid=17
add bridge=bridge comment=defconf frame-types=\
admit-only-untagged-and-priority-tagged ingress-filtering=no interface=\
ether9 pvid=17
add bridge=bridge1 comment=defconf ingress-filtering=no interface=ether10
add bridge=bridge1 comment=defconf ingress-filtering=no interface=\
sfp-sfpplus1
/ip neighbor discovery-settings
set discover-interface-list=LAN
/ip settings
set max-neighbor-entries=8192
/ipv6 settings
set disable-ipv6=yes max-neighbor-entries=8192
/interface bridge vlan
add bridge=bridge comment=home tagged=bridge,ether2,ether3,ether4,ether5 \
vlan-ids=17
add bridge=bridge comment=domotica tagged=bridge,ether2,ether3,ether4,ether5 \
vlan-ids=78
add bridge=bridge comment=invitados tagged=bridge,ether2,ether3,ether4,ether5 \
vlan-ids=79
/interface list member
add comment=defconf interface=bridge list=LAN
add comment=defconf interface=internet list=WAN
add comment=Aislados interface=vlan-domotica list=ISOLATED
add interface=bridge1 list=LAN
add interface=vlan-home list=LAN
add interface=vlan-invitados list=ISOLATED
/interface ovpn-server server
set auth=sha1,md5
/ip address
add address=192.168.9.1/24 comment=defconf interface=bridge network=\
192.168.9.0
add address=192.168.17.1/24 interface=vlan-home network=192.168.17.0
add address=192.168.78.1/24 interface=vlan-domotica network=192.168.78.0
add address=192.168.79.1/24 interface=vlan-invitados network=192.168.79.0
add address=192.168.86.1/24 comment="Por si pierdo acceso" interface=bridge1 \
network=192.168.86.0
/ip cloud
set ddns-enabled=yes
/ip dhcp-client
add comment=defconf interface=ether1
add add-default-route=no interface=vlan3-telefono use-peer-dns=no \
use-peer-ntp=no
/ip dhcp-server network
add address=192.168.9.0/24 comment="Por defecto" gateway=192.168.9.1
add address=192.168.17.0/24 comment=home gateway=192.168.17.1
add address=192.168.78.0/24 comment=domotica gateway=192.168.78.1 netmask=32
add address=192.168.79.0/24 comment=invitados dns-server=8.8.8.8,8.8.4.4 \
gateway=192.168.79.1
add address=192.168.86.0/24 comment=rescate dns-server=1.1.1.1,1.0.0.1 \
gateway=192.168.86.1
/ip dns
set allow-remote-requests=yes
/ip dns static
add address=192.168.88.1 comment=defconf name=router.lan
/ip firewall filter
add action=accept chain=input comment=\
"defconf: accept established,related,untracked" connection-state=\
established,related,untracked
add action=drop chain=input comment="defconf: drop invalid" connection-state=\
invalid
add action=accept chain=input comment="defconf: accept ICMP" protocol=icmp
add action=accept chain=input comment=\
"defconf: accept to local loopback (for CAPsMAN)" dst-address=127.0.0.1
add action=accept chain=input comment="voip: accept rip multicast traffic" \
dst-address=224.0.0.9 dst-port=520 in-interface=vlan3-telefono protocol=\
udp
add action=drop chain=input comment="defconf: drop all not coming from LAN" \
in-interface-list=!LAN
add action=accept chain=forward comment="defconf: accept in ipsec policy" \
ipsec-policy=in,ipsec
add action=accept chain=forward comment="defconf: accept out ipsec policy" \
ipsec-policy=out,ipsec
add action=fasttrack-connection chain=forward comment="defconf: fasttrack" \
connection-state=established,related hw-offload=yes
add action=accept chain=forward comment=\
"defconf: accept established,related, untracked" connection-state=\
established,related,untracked
add action=drop chain=forward comment="defconf: drop invalid" \
connection-state=invalid
add action=drop chain=forward comment=\
"defconf: drop all from WAN not DSTNATed" connection-nat-state=!dstnat \
connection-state=new in-interface-list=WAN
add action=reject chain=forward comment="vlans: can only access internet" \
in-interface-list=ISOLATED out-interface-list=!WAN reject-with=\
icmp-network-unreachable
/ip firewall mangle
add action=set-priority chain=postrouting new-priority=4 out-interface=\
vlan3-telefono
add action=set-priority chain=postrouting new-priority=1 out-interface=\
internet
/ip firewall nat
add action=masquerade chain=srcnat comment="defconf: masquerade" \
ipsec-policy=out,none out-interface-list=WAN
add action=masquerade chain=srcnat comment="voip: masq voip" out-interface=\
vlan3-telefono
/ip firewall raw
add action=drop chain=prerouting src-address-list=blacklist
/ip firewall service-port
set sip disabled=yes
/ip service
set telnet disabled=yes
set ftp disabled=yes
set www port=8081
set ssh disabled=yes
set api disabled=yes
set api-ssl disabled=yes
/routing rip interface-template
add instance=rip interfaces=vlan3-telefono mode=passive
/system clock
set time-zone-name=Europe/Madrid
/system identity
set name=RouterOS
/system resource irq rps
set sfp-sfpplus1 disabled=no
/system script
add dont-require-permissions=no name=lista-bloqueo-ips owner=ardase policy=\
ftp,reboot,read,write,policy,test,password,sniff,sensitive,romon source="d\
elay 15\r\
\nip firewall address-list\r\
\n:local update do={\r\
\n:do {\r\
\n:local data ([:tool fetch url=\$url output=user as-value]->\"data\")\r\
\n:local array [find dynamic list=blacklist]\r\
\n:foreach value in=\$array do={:set array (array,[get \$value address])}\
\r\
\n:while ([:len \$data]!=0) do={\r\
\n:if ([:pick \$data 0 [:find \$data \"\\n\"]]~\"^[0-9]{1,3}\\\\.[0-9]{1,3\
}\\\\.[0-9]{1,3}\\\\.[0-9]{1,3}\") do={\r\
\n:local ip ([:pick \$data 0 [:find \$data \$delimiter]].\$cidr)\r\
\n:do {add list=blacklist address=\$ip comment=\$description timeout=1d} o\
n-error={\r\
\n:do {set (\$array->([:find \$array \$ip]-[:len \$array]/2)) timeout=1d} \
on-error={}\r\
\n}\r\
\n}\r\
\n:set data [:pick \$data ([:find \$data \"\\n\"]+1) [:len \$data]]\r\
\n}\r\
\n} on-error={:log warning \"Address list <\$description> update failed\"}\
\r\
\n}\r\
\n\$update url=http://feeds.dshield.org/block.txt description=DShield deli\
miter=(\"\\t\") cidr=/24\r\
\n\$update url=http://www.spamhaus.org/drop/drop.txt description=\"Spamhau\
s DROP\" delimiter=(\"\\_\")\r\
\n\$update url=http://www.spamhaus.org/drop/edrop.txt description=\"Spamha\
us EDROP\" delimiter=(\"\\_\")\r\
\n\$update url=https://sslbl.abuse.ch/blacklist/sslipblacklist.txt descrip\
tion=\"Abuse.ch SSLBL\" delimiter=(\"\\r\")\r\
\n\$update url=https://raw.githubusercontent.com/ktsaou/blocklist-ipsets/m\
aster/firehol_level2.netset description=\"FireHOL Level2\" delimiter=(\"\\\
n\")\r\
\n\$update url=https://lists.blocklist.de/lists/all.txt description=\"Bloc\
kList.de\" delimiter=(\"\\n\")"
/tool mac-server
set allowed-interface-list=LAN
/tool mac-server mac-winbox
set allowed-interface-list=LAN
Me suena que las ubiquiti se llevan regular con el tráfico multicast. Tienes alguna cagada con el bridge y con el vlan filtering, pero el tema RIP parece correcto. ¿Ves que RIP mueva tráfico e instale rutas dinámicas con distancia 110? Sin las rutas dinámicas que instale RIP, la VoIP no funciona, aunque la interfaz de la vlan3 obtenga IP.
Saludos!
Si no ves las rutas con distancia 110 pon la huawei a currar, porque eso es por la ONT casi seguro, si la vlan3 te está dando IP.
Relativo a los errores:
- tienes tres bridges, pero sólo un en uso.
- el "bridge1" es innecesario, puesto que en el "bridge" principal no tienes quitada la vlan1 por defecto (tienes el flag de frame-types = admit all, así que esa vlan1 sigue habilita). La IP que le das al "bridge1", se la podrías dar al "bridge" (que de hecho ya tiene otra subred encima, la 192.168.9.1/24), puesto que este sigue en la lista LAN y permites el tráfico sin VLAN en él, así que mientras no cambies ese frame-types, eso va a seguir funcionando y con acceso al equipo. Los puertos sobre los que no mapees una vlan en la tabla de vlans y dejes con el PVID=1 (por defecto) pertenecerán a dicha vlan1, tal y como tienes ahora mismo ether10 y sfp-sfpplus1 en bridge1.
- La tabla de vlans está mal construída. Según tu tabla de vlans, los puertos ether2, ether3, ether4 y ether5 son trunks con todas las vlans. Sin embargo, según el listado de puertos de Bridge -> Ports, ether2 y ether4 son trunks, mientras que ether3 y ether5 so híbridos.
- Tienes dos reglas por ahí perdidas de filtrado en el bridge que el propio export te indican que son incorrectas. Estas vienen heredadas de la config original, de haber creado una segunda wifi de invitados, donde el tráfico de dichas interfaces se controlaba que no saltase a la red principal mediante reglas de filtrado. En tu setup original, carecen de sentido. Puedes borrarlas en Bridge -> Filters.
Saludos!
Yo tengo una entrada estatica en el mikrotik:No funciona la VOIP ( No registra "Request Timeout") con O2 con ONT Ufiber Nano G
Veo que asigna IP por la Vlan 3
copio el export, a ver si hay algo mal, lo he copiado de este mismo hilo
Código:# jan/28/2023 12:14:32 by RouterOS 7.7 # software id = XBIC-ERVV # # model = RB4011iGS+ /interface bridge add admin-mac=18:FD:74:C2:A7:DB auto-mac=no comment=defconf \ ingress-filtering=no name=bridge vlan-filtering=yes add ingress-filtering=no name=bridge1 vlan-filtering=yes add name=bridgemng /interface vlan add interface=bridge name=vlan-domotica vlan-id=78 add interface=bridge name=vlan-home vlan-id=17 add interface=bridge name=vlan-invitados vlan-id=79 add interface=ether1 name=vlan3-telefono vlan-id=3 add interface=ether1 name=vlan6-internet vlan-id=6 /interface pppoe-client add add-default-route=yes disabled=no interface=vlan6-internet name=internet \ use-peer-dns=yes user=adslppp@telefonicanetpa /interface list add comment=defconf name=WAN add comment=defconf name=LAN add name=ISOLATED /interface lte apn set [ find default=yes ] ip-type=ipv4 use-network-apn=no /interface wireless security-profiles set [ find default=yes ] supplicant-identity=MikroTik /ip pool add name=default-dhcp ranges=192.168.9.10-192.168.9.254 add name=dhcp-home ranges=192.168.17.10-192.168.17.254 add name=dhcp-domotica ranges=192.168.78.10-192.168.78.254 add name=dhcp-invitados ranges=192.168.79.10-192.168.79.254 add name=rescate ranges=192.168.86.20-192.168.86.35 /ip dhcp-server add address-pool=default-dhcp interface=bridge name=defconf add address-pool=dhcp-home interface=vlan-home name=dhcp-home add address-pool=dhcp-domotica interface=vlan-domotica name=dhcp-domotica add address-pool=dhcp-invitados interface=vlan-invitados name=dhcp-invitados add address-pool=rescate interface=bridge1 name=dhcp-rescate /port set 0 name=serial0 set 1 name=serial1 /routing rip instance add afi=ipv4 disabled=no name=rip /interface bridge filter # in/out-bridge-port matcher not possible when interface (vlan-domotica) is not slave add action=drop chain=forward in-interface=vlan-domotica # in/out-bridge-port matcher not possible when interface (vlan-domotica) is not slave add action=drop chain=forward out-interface=vlan-domotica /interface bridge port add bridge=bridge comment=defconf ingress-filtering=no interface=ether2 add bridge=bridge comment=defconf ingress-filtering=no interface=ether3 pvid=\ 17 add bridge=bridge comment=defconf ingress-filtering=no interface=ether4 add bridge=bridge comment=defconf ingress-filtering=no interface=ether5 pvid=\ 78 add bridge=bridge comment=defconf frame-types=\ admit-only-untagged-and-priority-tagged ingress-filtering=no interface=\ ether6 pvid=17 add bridge=bridge comment=defconf frame-types=\ admit-only-untagged-and-priority-tagged ingress-filtering=no interface=\ ether7 pvid=17 add bridge=bridge comment=defconf frame-types=\ admit-only-untagged-and-priority-tagged ingress-filtering=no interface=\ ether8 pvid=17 add bridge=bridge comment=defconf frame-types=\ admit-only-untagged-and-priority-tagged ingress-filtering=no interface=\ ether9 pvid=17 add bridge=bridge1 comment=defconf ingress-filtering=no interface=ether10 add bridge=bridge1 comment=defconf ingress-filtering=no interface=\ sfp-sfpplus1 /ip neighbor discovery-settings set discover-interface-list=LAN /ip settings set max-neighbor-entries=8192 /ipv6 settings set disable-ipv6=yes max-neighbor-entries=8192 /interface bridge vlan add bridge=bridge comment=home tagged=bridge,ether2,ether3,ether4,ether5 \ vlan-ids=17 add bridge=bridge comment=domotica tagged=bridge,ether2,ether3,ether4,ether5 \ vlan-ids=78 add bridge=bridge comment=invitados tagged=bridge,ether2,ether3,ether4,ether5 \ vlan-ids=79 /interface list member add comment=defconf interface=bridge list=LAN add comment=defconf interface=internet list=WAN add comment=Aislados interface=vlan-domotica list=ISOLATED add interface=bridge1 list=LAN add interface=vlan-home list=LAN add interface=vlan-invitados list=ISOLATED /interface ovpn-server server set auth=sha1,md5 /ip address add address=192.168.9.1/24 comment=defconf interface=bridge network=\ 192.168.9.0 add address=192.168.17.1/24 interface=vlan-home network=192.168.17.0 add address=192.168.78.1/24 interface=vlan-domotica network=192.168.78.0 add address=192.168.79.1/24 interface=vlan-invitados network=192.168.79.0 add address=192.168.86.1/24 comment="Por si pierdo acceso" interface=bridge1 \ network=192.168.86.0 /ip cloud set ddns-enabled=yes /ip dhcp-client add comment=defconf interface=ether1 add add-default-route=no interface=vlan3-telefono use-peer-dns=no \ use-peer-ntp=no /ip dhcp-server network add address=192.168.9.0/24 comment="Por defecto" gateway=192.168.9.1 add address=192.168.17.0/24 comment=home gateway=192.168.17.1 add address=192.168.78.0/24 comment=domotica gateway=192.168.78.1 netmask=32 add address=192.168.79.0/24 comment=invitados dns-server=8.8.8.8,8.8.4.4 \ gateway=192.168.79.1 add address=192.168.86.0/24 comment=rescate dns-server=1.1.1.1,1.0.0.1 \ gateway=192.168.86.1 /ip dns set allow-remote-requests=yes /ip dns static add address=192.168.88.1 comment=defconf name=router.lan /ip firewall filter add action=accept chain=input comment=\ "defconf: accept established,related,untracked" connection-state=\ established,related,untracked add action=drop chain=input comment="defconf: drop invalid" connection-state=\ invalid add action=accept chain=input comment="defconf: accept ICMP" protocol=icmp add action=accept chain=input comment=\ "defconf: accept to local loopback (for CAPsMAN)" dst-address=127.0.0.1 add action=accept chain=input comment="voip: accept rip multicast traffic" \ dst-address=224.0.0.9 dst-port=520 in-interface=vlan3-telefono protocol=\ udp add action=drop chain=input comment="defconf: drop all not coming from LAN" \ in-interface-list=!LAN add action=accept chain=forward comment="defconf: accept in ipsec policy" \ ipsec-policy=in,ipsec add action=accept chain=forward comment="defconf: accept out ipsec policy" \ ipsec-policy=out,ipsec add action=fasttrack-connection chain=forward comment="defconf: fasttrack" \ connection-state=established,related hw-offload=yes add action=accept chain=forward comment=\ "defconf: accept established,related, untracked" connection-state=\ established,related,untracked add action=drop chain=forward comment="defconf: drop invalid" \ connection-state=invalid add action=drop chain=forward comment=\ "defconf: drop all from WAN not DSTNATed" connection-nat-state=!dstnat \ connection-state=new in-interface-list=WAN add action=reject chain=forward comment="vlans: can only access internet" \ in-interface-list=ISOLATED out-interface-list=!WAN reject-with=\ icmp-network-unreachable /ip firewall mangle add action=set-priority chain=postrouting new-priority=4 out-interface=\ vlan3-telefono add action=set-priority chain=postrouting new-priority=1 out-interface=\ internet /ip firewall nat add action=masquerade chain=srcnat comment="defconf: masquerade" \ ipsec-policy=out,none out-interface-list=WAN add action=masquerade chain=srcnat comment="voip: masq voip" out-interface=\ vlan3-telefono /ip firewall raw add action=drop chain=prerouting src-address-list=blacklist /ip firewall service-port set sip disabled=yes /ip service set telnet disabled=yes set ftp disabled=yes set www port=8081 set ssh disabled=yes set api disabled=yes set api-ssl disabled=yes /routing rip interface-template add instance=rip interfaces=vlan3-telefono mode=passive /system clock set time-zone-name=Europe/Madrid /system identity set name=RouterOS /system resource irq rps set sfp-sfpplus1 disabled=no /system script add dont-require-permissions=no name=lista-bloqueo-ips owner=ardase policy=\ ftp,reboot,read,write,policy,test,password,sniff,sensitive,romon source="d\ elay 15\r\ \nip firewall address-list\r\ \n:local update do={\r\ \n:do {\r\ \n:local data ([:tool fetch url=\$url output=user as-value]->\"data\")\r\ \n:local array [find dynamic list=blacklist]\r\ \n:foreach value in=\$array do={:set array (array,[get \$value address])}\ \r\ \n:while ([:len \$data]!=0) do={\r\ \n:if ([:pick \$data 0 [:find \$data \"\\n\"]]~\"^[0-9]{1,3}\\\\.[0-9]{1,3\ }\\\\.[0-9]{1,3}\\\\.[0-9]{1,3}\") do={\r\ \n:local ip ([:pick \$data 0 [:find \$data \$delimiter]].\$cidr)\r\ \n:do {add list=blacklist address=\$ip comment=\$description timeout=1d} o\ n-error={\r\ \n:do {set (\$array->([:find \$array \$ip]-[:len \$array]/2)) timeout=1d} \ on-error={}\r\ \n}\r\ \n}\r\ \n:set data [:pick \$data ([:find \$data \"\\n\"]+1) [:len \$data]]\r\ \n}\r\ \n} on-error={:log warning \"Address list <\$description> update failed\"}\ \r\ \n}\r\ \n\$update url=http://feeds.dshield.org/block.txt description=DShield deli\ miter=(\"\\t\") cidr=/24\r\ \n\$update url=http://www.spamhaus.org/drop/drop.txt description=\"Spamhau\ s DROP\" delimiter=(\"\\_\")\r\ \n\$update url=http://www.spamhaus.org/drop/edrop.txt description=\"Spamha\ us EDROP\" delimiter=(\"\\_\")\r\ \n\$update url=https://sslbl.abuse.ch/blacklist/sslipblacklist.txt descrip\ tion=\"Abuse.ch SSLBL\" delimiter=(\"\\r\")\r\ \n\$update url=https://raw.githubusercontent.com/ktsaou/blocklist-ipsets/m\ aster/firehol_level2.netset description=\"FireHOL Level2\" delimiter=(\"\\\ n\")\r\ \n\$update url=https://lists.blocklist.de/lists/all.txt description=\"Bloc\ kList.de\" delimiter=(\"\\n\")" /tool mac-server set allowed-interface-list=LAN /tool mac-server mac-winbox set allowed-interface-list=LAN