Community discussions

MikroTik App
Forum Guru
Forum Guru
Topic Author
Posts: 3819
Joined: Fri May 28, 2004 5:22 pm

cat a file in script

Sat Feb 12, 2005 12:27 am

any way to 'cat' or 'type' a file so I can loop thru entries? Im thinking of using this URL to build a list of bogons for a chain: ... dr-all.txt (way too big obviously) ... dr-all.txt (better subset + the bogons we already filter)

I was trying to ftp this to the firewall and have it generate a 'bogons' chain automatically, but I don't see a way to :foreach a file and loop thru each line. I was going to process it into a script and then ftp it up and execute it, but i'd like to keep everything local on the firewall if possibe (except the uploading of the list with no wget present).

Any ideas?

User avatar
Member Candidate
Member Candidate
Posts: 140
Joined: Fri May 28, 2004 3:26 pm
Location: Norway, Østfold

Wed Feb 16, 2005 1:03 am

Write a shell script wich will login to your routeros and and execute the loop.

Who is online

Users browsing this forum: No registered users and 11 guests