Community discussions

MikroTik App
 
User avatar
Gromit
newbie
Topic Author
Posts: 37
Joined: Tue Jul 24, 2007 11:47 am

modify proxy rule using script

Mon Aug 27, 2007 4:38 pm

Ok, so I want to enable/disable a certain access rule using a script which I can run in the system scheduler. Can anyone tell me what the syntax will be?
 
User avatar
Gromit
newbie
Topic Author
Posts: 37
Joined: Tue Jul 24, 2007 11:47 am

Re: modify proxy rule using script

Tue Aug 28, 2007 9:38 am

Ok so did a bit of searching and came up with this:
{ip proxy access}{print}{disable 8}
ok, so this will disable a specific (number 8 ) proxy rule.

only problem is, it works in the terminal but not if I use the script repository.

Please someone help!!
 
User avatar
mrz
MikroTik Support
MikroTik Support
Posts: 7188
Joined: Wed Feb 07, 2007 12:45 pm
Location: Latvia
Contact:

Re: modify proxy rule using script

Tue Aug 28, 2007 11:01 am

add comment to rule, for example myRule.
After that you must use find to get correct internal number.
/ip proxy access disable [ /ip proxy access find comment="myRule" ] ;
 
User avatar
Gromit
newbie
Topic Author
Posts: 37
Joined: Tue Jul 24, 2007 11:47 am

Re: modify proxy rule using script

Tue Aug 28, 2007 1:17 pm

add comment to rule, for example myRule.
After that you must use find to get correct internal number.
/ip proxy access disable [ /ip proxy access find comment="myRule" ] ;

Thanks, works like a charm

Who is online

Users browsing this forum: No registered users and 10 guests