ip access-group
26-86 Authentication and Authorization Configuration
Ifeqportisnotspecified,TCP/UDPportsarenotusedforfiltering.Onlytheprotocol,source,and
destinationareusedforapplyingtherule.
Mode
Globalconfiguration:C3(su)>router(Config)#
Usage
Accesslistsareappliedtointerfacesbyusingtheipaccessgroupcommandasdescribedinip
accessgrouponpage 2686.
Vali daccesslistnumbersforextendedACLsare100to199.ForstandardACLs,valid valuesare1
to99.
Allaccesslistshaveanimplicit“denyanyany”statmentastheirlastentry.
Examples
Thisexampleshowshowtodefineaccesslist145todenyICMPtransmissionsfromanysource
andforanydestination:
C3(su)->router(Config)#access-list 145 deny ICMP any any
Thisexampleappendstoaccesslist145apermitstatementthatallowsthehostwithIPaddress
88.255.255.254todoanSSHremotelogintoanydestinationonTCPport22.
C3(su)->router(Config)#access-list 145 permit tcp host 88.255.255.254 any eq 22
Thisexampleappendstoaccesslist145apermitstatementthatallowsSNMPcontroltraffic(from
UDPport161)tobesentfromIPaddresseswithintherangedefinedby88.255.128.00.0.127.255
toanydestination.
C3(su)->router(Config)#access-list 145 permit udp 88.255.128.0 0.0.127.255 eq 161
any
ip access-group
Usethiscommandtoapplyaccessrestrictionstoinboundframesonaninterfacewhenoperating
inroutermode.Thenoformofthiscommandremovesthespecifiedaccesslist.
Syntax
ip access-group access-list-number in
no ip access-group access-list-number in
Parameters
Defaults
None.
Mode
Interfaceconfiguration:C3(su)>router(Configif(Vlan<vlan_id>))#
accesslistnumber Specifiesthenumberoftheaccesslisttobeappliedtotheaccesslist.This
isadecimalnumberfrom1to199.
in Filtersinboundframes.