cancel
Showing results for 
Search instead for 
Did you mean: 

How i can enable access list using only mac address to ssh login

How i can enable access list using only mac address to ssh login

Adnan
New Contributor
Hello

i would like to enable access list using mac address of certain PC

i am asking because i used the same code of access list using only ip address

i used this code

entry AllowManagementIP { if match any { ethernet-source-address F8:A7:BC:E0:D1:AE; } then { permit; } } and it didnt work still eny pc can login using ssh i did refresh policy cammand still the same problem
21 REPLIES 21

Adnan
New Contributor


entry AllowManagementIP { if match any { ethernet-source-address F8:A7:BC:E0:D1:AE; } then { permit; } else {
deny all;
} }

Error again: attribiute deny should not have any arguments , "all " is invalid

AnonymousM
Valued Contributor II
Myabe just a "deny;" would be enough. Didn't play with policy files for quite some time. 😉

AnonymousM
Valued Contributor II
OK. Try to add a deny all at the bottom of the policy

Adnan
New Contributor
entry AllowManagementIP { if match any { ethernet-source-address F8:A7:BC:E0:D1:AE; } then { permit; } else {
deny;
} }

it gives me Error
error policy has else clause , which can be used only in clear flow rules

AnonymousM
Valued Contributor II
you could just try to use

else {
deny;
}

after your then expression
GTM-P2G8KFN