











|  |
| Author |
ACL Blocking 2 ports
|
Bear
Member
Registered: May 2000 Location: Weatherford, tx usa Country: State: Certifications: Working on:
Total Posts: 38
|
|
Could someone please show the steps. I need to block the even address to both ports on a router. I have the following set up.
Source Router A 174.22.0.129
sm 255.255.255.192
Destination Router B s0 174.22.0.66 e0 174.22.0.193
I need to block the even address from Router A from being able to telnet to Router B, I need to block both the s0 and e0 ports and allow the odd addresses to go through.
[This message has been edited by Bear (edited 01-10-2001).]
[This message has been edited by Bear (edited 01-10-2001).]
Report this post to a moderator
|
|
01-10-01 07:49 PM
|
|
MadChef
A Huge Fake
Registered: Sep 2000 Location: Country: USA State: Certifications: Working on: A Sex Farm
Total Posts: 1426
|
|
This is a NetAcad question, isn't it? We've seen it before....
I think this will do it when applied to RouterB S0 inbound.
ip access-list extended MadChef
deny tcp 174.22.0.128 0.0.0.62 any eq telnet
permit ip any any
MadChef
[This message has been edited by MadChef (edited 01-10-2001).]
Report this post to a moderator
|
|
01-10-01 08:46 PM
|
|
comez
Junior Member
Registered: Dec 2000 Location: Toronto,Canada, Country: State: Certifications: Working on:
Total Posts: 13
|
|
what about following?
access-list 101 deny tcp 174.22.0.128 0.0.0.62 destination-network mask eq 23
access-list 101 permit ip any any
Any comments ?
Report this post to a moderator
|
|
01-10-01 08:47 PM
|
|
comez
Junior Member
Registered: Dec 2000 Location: Toronto,Canada, Country: State: Certifications: Working on:
Total Posts: 13
|
|
oopppss, Madchef, I had not seen your post while replying.I'm glad to learn that I did well. I know you're an expert..
Cheers.
Report this post to a moderator
|
|
01-10-01 08:53 PM
|
|
MadChef
A Huge Fake
Registered: Sep 2000 Location: Country: USA State: Certifications: Working on: A Sex Farm
Total Posts: 1426
|
|
I hesitated for a bit while doing the wildcard because I didn't take the time to do the math. (I'm VERY bad at creating masks in my head so I usually end up doing the binary on a piece of paper.) I was glad to see that someone else came up with the same answer. At least I have a shot at being right. 
Report this post to a moderator
|
|
01-10-01 09:01 PM
|
|
Bear
Member
Registered: May 2000 Location: Weatherford, tx usa Country: State: Certifications: Working on:
Total Posts: 38
|
|
quote: Originally posted by MadChef:
I hesitated for a bit while doing the wildcard because I didn't take the time to do the math. (I'm VERY bad at creating masks in my head so I usually end up doing the binary on a piece of paper.) I was glad to see that someone else came up with the same answer. At least I have a shot at being right. 
Mad Chef
It worked could you explain 0.0.0.62 I do not understand this part
Report this post to a moderator
|
|
01-10-01 10:02 PM
|
|
firechicken
Senior Member/Citizen
Registered: Nov 2000 Location: Country: United States State: OR Certifications: Comp TIA D Minus Certified Working on: Food Handler
Total Posts: 467
|
|
For the destination address and wildcard mask in your ACL, use the host 174.22.0.66, or you could use that IP address and 0.0.0.0 as the wildcard mask. (Host and the wildcard mask 0.0.0.0 mean the same thing).
Report this post to a moderator
|
|
01-10-01 10:14 PM
|
|
MadChef
A Huge Fake
Registered: Sep 2000 Location: Country: USA State: Certifications: Working on: A Sex Farm
Total Posts: 1426
|
|
Write out the last octet of the source network and wildcard mask and compare. What happens when you apply those wildcarded bits to your source network?
MadChef
Report this post to a moderator
|
|
01-10-01 10:15 PM
|
|
Bear
Member
Registered: May 2000 Location: Weatherford, tx usa Country: State: Certifications: Working on:
Total Posts: 38
|
|
quote: Originally posted by firechicken:
For the destination address and wildcard mask in your ACL, use the host 174.22.0.66, or you could use that IP address and 0.0.0.0 as the wildcard mask. (Host and the wildcard mask 0.0.0.0 mean the same thing).
I still do not understand why only the 0.0.0.62 works nothing else i tried will work.
Report this post to a moderator
|
|
01-10-01 10:35 PM
|
|
dmaftei
Senior Member M
Registered: Nov 2000 Location: Country: USA State: Certifications: none Working on: none
Total Posts: 2156
|
|
Look at the "deny tcp 174.22.0.128 0.0.0.62" rule. Write the address and the wildcard in binary:
10101110.00010110.00000000.10000000
00000000.00000000.00000000.00111110
Consider a packet going through this filter. The source address is masked with the wildcard. The bits in your address corresponding to "0" in the wildcard must match the corresponding bits in 174.22.0.128. Conversely, the bits corresponding to "1" in the wildcard don't have to match. Let's write an address that matches (174.22.0.178):
10101110.00010110.00000000.10110010
00000000.00000000.00000000.00111110
10101110.00010110.00000000.10XXXXX0
The "X"s on the last line tell you that you may have whatever you want in that position. Note, however, that the last bit MUST be "0" for you address to match. All binary numbers with the last (rightmost) bit "0" are even. That's what you need.
Hope this helps.
[This message has been edited by dmaftei (edited 01-10-2001).]
Report this post to a moderator
|
|
01-10-01 10:58 PM
|
|
|
Forum Rules: Who Can Read The Forum? Any registered user or guest.
Who Can Post New Topics? Any registered user.
Who Can Post Replies? Any registered user.
Changes: Messages can be edited by their author.
Posts: HTML code is OFF. Smilies are ON. vB code is ON. [IMG] code is ON. |
|
ExamNotes forum archive
|