28.06.2014 Views

Learning by Doing: CISCO Certified Network ... - SCN Research

Learning by Doing: CISCO Certified Network ... - SCN Research

Learning by Doing: CISCO Certified Network ... - SCN Research

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

Now we just need to do the second step: apply it to an interface. Since this is a standard<br />

ACL we want to apply it as close to the destination as possible using “out.” If we look at<br />

our diagram we can see that the Ethernet interface 0/0 is the closest to the destination<br />

network.<br />

Router(config)#interface e0/0<br />

Router(config-if)#ip access-group 1 out<br />

Extended ACL’s<br />

An extended ACL controls access to specific ports for IP addresses. Here we are doing<br />

basically the same thing but restricting access for something specific like ftp access,<br />

telnet access, or even icmp access. Using our lab diagram again let’s write an ACL for<br />

the EGR network to have no (deny) telnet access to the HR network:<br />

(1) Create the ACL:<br />

a. Router(config)#access-list 100 deny tcp 192.168.30.0 0.0.0.255 any eq 23<br />

b. Router(config)#access-list 100 permit ip any any<br />

(2) Apply the ACL to an interface:<br />

a. Router(config)int e0/2<br />

b. Router(config-if)#ip access-group 100 in<br />

Using our lab diagram again let’s write an ACL for the EGR network to have no (deny)<br />

ability to ping (icmp) to the HR network:<br />

(1) Create the ACL:<br />

a. Router(config)#access-list 100 deny icmp 192.168.30.0 0.0.0.255<br />

b. Router(config)#access-list 100 permit icmp any any<br />

(2) Apply the ACL to an interface:<br />

a. Router(config)int e0/2<br />

b. Router(config-if)#ip access-group 100 in<br />

Named ACL’s<br />

A named ACL uses a name instead of a number to do the same thing as standard or<br />

extended ACL’s. Let’s write a named ACL to for hosts on the sales network to be denied<br />

access to the HR server, but allow them access to the marketing network and the WWW.<br />

Notice the changes in the prompt.<br />

(1) Create the ACL:<br />

a. Router(config)#ip access-list standard no_salesHR<br />

b. Router(config-std-nacl)#deny 192.168.40.0 0.0.0.255<br />

c. Router(config-std-nacl)#permit ip any<br />

(2) Apply the ACL to an interface:<br />

a. Router(config)#interface e0/0<br />

b. Router(config-if)#ip access-group no_salesHR out<br />

339

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!