Community discussions

Search found 14 matches

by Martin4
Wed Jun 12, 2019 12:52 am
Forum: Scripting
Topic: find in log "assigned" or "deassigned" IP by dhcp
Replies: 7
Views: 413

Re: find in log "assigned" or "deassigned" IP by dhcp

Hi, "print" seems not function...
or maybe i'm not able, but i'm still trying...
by Martin4
Fri Jun 07, 2019 1:45 pm
Forum: Scripting
Topic: find in log "assigned" or "deassigned" IP by dhcp
Replies: 7
Views: 413

Re: find in log "assigned" or "deassigned" IP by dhcp

No.... i try :put from command line (ssh session): :put [ :toarray [ /log find where (message~"assigned" || message~"user") ] ] but the result is a series of... i don't know (hex code? other?) Part of the result: ................. ;*7e4;*7e5;*7e6;*7e7;*7e8;*7e9;*7ea;*7eb;*7ec;*7ed;*7ee;*7ef;*7f0;*7f...
by Martin4
Thu Jun 06, 2019 7:43 pm
Forum: Scripting
Topic: find in log "assigned" or "deassigned" IP by dhcp
Replies: 7
Views: 413

Re: find in log "assigned" or "deassigned" IP by dhcp

Hi, thanks, now i try...
Yes, i only need OR method.
I want only find A or B or C....

I'm not sure to complain :put command.
In the wiki this is not very well explained.
by Martin4
Thu Jun 06, 2019 11:00 am
Forum: Scripting
Topic: find in log "assigned" or "deassigned" IP by dhcp
Replies: 7
Views: 413

find in log "assigned" or "deassigned" IP by dhcp

Hi, like subject... i've already a running script that works fine! It parse the log to find logged users, but if i add keyword to find "assigned" to, it doesn't find it! My code was: :local currentBuf [ :toarray [ /log find where (message~"logged" || message~"login") ] ] Then i semplify in this code...
by Martin4
Thu Jun 06, 2019 10:49 am
Forum: Scripting
Topic: Script doesn't continue after a statement [SOLVED]
Replies: 6
Views: 356

Re: Script doesn't continue after a statement [SOLVED]

ok, thank you very much! :)
by Martin4
Mon Jun 03, 2019 11:37 pm
Forum: Scripting
Topic: Script doesn't continue after a statement [SOLVED]
Replies: 6
Views: 356

Re: Script doesn't continue after a statement

I found! Sorry!!! damn!!! the line offending is: ..... :set messageTime [/log get [ :pick $currentBuf ($currentLineCount - 1) ] time] ; .... if i comment that it works! so, the solution is to add ad this line :totime !!! So, the line, finally, looks like this: :set messageTime [ :totime [/log get [ ...
by Martin4
Mon Jun 03, 2019 11:12 pm
Forum: Scripting
Topic: Script doesn't continue after a statement [SOLVED]
Replies: 6
Views: 356

Re: Script doesn't continue after a statement

Hi msatter thank you,
actually I can also remove the instruction "log..." or doing nothing, but the problem remains.
by Martin4
Mon Jun 03, 2019 9:30 pm
Forum: Scripting
Topic: Script doesn't continue after a statement [SOLVED]
Replies: 6
Views: 356

Script doesn't continue after a statement [SOLVED]

Hi, i've this script. The script works fine! But..... after :foreach {......} statement it doesn't execute nothing other! For example a /log info "...." doesn't works, or a command, or an IF statement.... Nothing works after } of the :foreach statement. I can't realize what is blocking! I tried to a...
by Martin4
Tue Jan 08, 2019 11:17 pm
Forum: Beginner Basics
Topic: chain -> input action -> drop [SOLVED]
Replies: 6
Views: 525

Re: chain -> input action -> drop

ok, all clear, thank you very much solar77.
And thanks to all, .....solved.
by Martin4
Tue Jan 08, 2019 3:29 pm
Forum: Beginner Basics
Topic: chain -> input action -> drop [SOLVED]
Replies: 6
Views: 525

Re: chain -> input action -> drop

thank you anav, all clear. Yeas, i readed wiki but I don't understand some points... if you want, can you read in my before post the points 1, 2, 3, and 4 and clear me that dubts? Point 1 you probably already clear, I understand that then only one goes and at the end? Right? Point 4 is most importan...
by Martin4
Mon Jan 07, 2019 1:47 am
Forum: Beginner Basics
Topic: chain -> input action -> drop [SOLVED]
Replies: 6
Views: 525

Re: chain -> input action -> drop

Hi, thank you for the reply. I had already read the wiki but i continue to not understand, so i wrote... So... 1) the drop rule at he end must be 1 and only 1, right? So, if i add in the future some new rules, i must insert before the "drop all" rule that was at the end, right? I'll must move at the...
by Martin4
Sun Jan 06, 2019 9:54 pm
Forum: Beginner Basics
Topic: chain -> input action -> drop [SOLVED]
Replies: 6
Views: 525

chain -> input action -> drop [SOLVED]

Hi, i can't understand the use of the rule: add chain=input action=drop In particular, i find many firewall rules on internet and some groups of rules have at the end that rule. So, i can't understand if i must write this rule every time i write rules, or if it's sufficient only once at the end of a...
by Martin4
Mon Dec 31, 2018 1:13 am
Forum: Scripting
Topic: Mikrotik and Telegram
Replies: 38
Views: 13926

Re: Mikrotik and Telegram

Hi, if i try to run script tg_cmd_xxxx separately they works fine... when i send /message from telegram to bot, run tg_getUpdates in telnet and i receive "no such item" tg: Load config trusted=xxxxxxxx;trusted=yyyyyyyy botID=zzzzzzzzzzzzzzzzzzzzzzzzzzzzzzz storage=/disk1/ timeout=1 Reading updates.....
by Martin4
Sat Dec 29, 2018 3:54 pm
Forum: Scripting
Topic: user access script contents
Replies: 0
Views: 202

user access script contents

Hi to all, first, sorry for my bad english, then... I've 2 users with full permissions on router. I've some scripts and, in some of this, ther are sensitives data like passwords etc... Is there a method to deny 1 user (with full permissions) to read the contents of the scripts? The scripts have thei...