05.01.2013 Views

CCNA Cisco Certified Network Associate Study Guide - FTP Server

CCNA Cisco Certified Network Associate Study Guide - FTP Server

CCNA Cisco Certified Network Associate Study Guide - FTP Server

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.

Access Lists 445<br />

Now, that was the easy part. What if you want to specify only a small<br />

range of subnets? This is where the block sizes come in. You have to specify<br />

the range of values in a block size. In other words, you can’t choose to specify<br />

20 networks. You can only specify the exact amount as the block size value.<br />

For example, the range would either have to be 16 or 32, but not 20.<br />

Let’s say that you want to block access to part of network that is in the<br />

range from 172.16.8.0 through 172.16.15.0. That is a block size of 8. Your<br />

network number would be 172.16.8.0, and the wildcard would be<br />

0.0.7.255. Whoa! What is that? The 7.255 is what the router uses to determine<br />

the block size. The network and wildcard tell the router to start at<br />

172.16.8.0 and go up a block size of eight addresses to network 172.16.15.0.<br />

It is actually easier than it looks. I could certainly go through the binary<br />

math for you, but actually all you have to do is remember that the wildcard<br />

is always one number less than the block size. So, in our example, the wildcard<br />

would be 7 since our block size is 8. If you used a block size of 16, the<br />

wildcard would be 15. Easy, huh?<br />

We’ll go through some examples to help you really understand it. The following<br />

example tells the router to match the first three octets exactly but that<br />

the fourth octet can be anything.<br />

RouterA(config)#access-list 10 deny 172.16.10.0 0.0.0.255<br />

The next example tells the router to match the first two octets and that the<br />

last two octets can be any value.<br />

RouterA(config)#access-list 10 deny 172.16.0.0 0.0.255.255<br />

Try to figure out this next line:<br />

RouterA(config)#access-list 10 deny 172.16.16.0 0.0.3.255<br />

The above configuration tells the router to start at network 172.16.16.0<br />

and use a block size of 4. The range would then be 172.16.16.0 through<br />

172.16.19.0.<br />

The example below shows an access list starting at 172.16.16.0 and going<br />

up a block size of 8 to 172.16.23.0.<br />

RouterA(config)#access-list 10 deny 172.16.16.0 0.0.7.255<br />

The next example starts at network 172.16.32.0 and goes up a block size<br />

of 32 to 172.16.63.0.<br />

RouterA(config)#access-list 10 deny 172.16.32.0 0.0.31.255

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

Saved successfully!

Ooh no, something went wrong!