routeros_bogon_update
Both sides previous revisionPrevious revisionNext revision | Previous revisionNext revisionBoth sides next revision | ||
routeros_bogon_update [2015/04/19 11:58] – [RouterOS 6.x - Update bogon list automatically] admin | routeros_bogon_update [2021/10/30 07:55] – admin | ||
---|---|---|---|
Line 1: | Line 1: | ||
{{tag> | {{tag> | ||
- | ~~TOC~~ | ||
=====RouterOS 6.x - Update bogon list automatically===== | =====RouterOS 6.x - Update bogon list automatically===== | ||
+ | |||
+ | * Download CA certificates and upload to RouterOS, or with next command (not encrypted by TLS!):< | ||
* Create a new script: < | * Create a new script: < | ||
* Edit new script:< | * Edit new script:< | ||
Line 22: | Line 23: | ||
:log info " | :log info " | ||
- | :while ($lineEnd < $contentLen) | + | :do { |
- | | + | |
- | :if ([:len $lineEnd] = 0) do={ | + | |
- | :set lineEnd $contentLen; | + | |
- | } | + | |
- | :set line [:pick $content $lastEnd $lineEnd]; | + | |
- | | + | |
- | | + | |
- | | + | } while ($lineEnd < $contentLen)</ |
- | /ip firewall address-list add list=bogons address="$line" | + | |
- | | + | |
- | }</ | + | |
* Test run script:< | * Test run script:< | ||
* Schedule script:< | * Schedule script:< | ||
routeros_bogon_update.txt · Last modified: 2021/10/31 14:40 by admin