-
Notifications
You must be signed in to change notification settings - Fork 124
Open
Labels
Description
Hi guys. I am a full blooded PHP dev but I suck at mikrotik stuff. I have a task to do the following
"Add 2 rules. Make sure they are inserted (or moved afterwards) before a rule that has a comment "Block access to internet")
I have no idea how to do that using UTIL class.
I can add rules. My problem is how to insert them or move them afterwards before the stated rule..
$additionalRule = [];
if($fw_rules_comment === 'Allow Teamviewer') {
$additionalRule = $insertRule;
$additionalRule['protocol'] = 'udp';
}
$insertRuleID = $util->add($insertRule);
if(count($additionalRule)) {
$additionalRuleID = $util->add($additionalRule);
}
//make sure both rules are added or moved afterwards BEFORE the rule that has comment "Block access to internet"
Thank you!