I’ve got this basic script and it is not behaving as expected:
:foreach iplist in=[/ip firewall address-list find where list=“LIST NAME HERE”] do={:local ip “$[/ip firewall address-list get $iplist address ;],$ip”; :put $ip}
I’ve noticed that RouterOS is including the list name in the output, which I’m not sure why and It is not the list name your actually targeting. For me it included the address list name from the list numbered one lower than the first list found.