test import

Categories

Ad Home

Responsive Ads Here

Labels

642-813 SWITCH (2) 642-902 ROUTE (2) 643-832 TSHOOT (1) Access Based Enumeration (1) access list (2) AIX (1) Anti Malware (16) AutoIT (1) backtrack (4) Basic Networking (3) Blogspot (2) bootable USB (1) can not download attach file from gmail (1) ccna (9) CCNA Lab (19) centos (3) Check (1) Check_MK (3) cisco (51) Dell (1) DHCP (1) Download (2) Dynamic Host Configuration Protocol (1) ebook (2) Ebooks (18) eigrp (1) encapsulation (3) esxi5 (2) exam (13) exchange server 2010 (3) facebook (2) firewall-cmd (1) firewall-config (1) firewalld (1) Frame Relay (4) Free Router Simulator Softwares (1) FreeNAS (1) GhostSurf (1) gns3 (1) Hacking Security (5) hardware (1) hotspot (1) How to Change Windows 2008 R2 SID (1) How to create VPN network on Linux (1) How to install openSSH on AIX 5.3 (1) How to Install the Microsoft Core Fonts on Fedora 19 (1) HP (1) IBM (1) Infrastructure Monitoring (3) InterVLAN (1) ip routing (3) IPSec (2) ipv6 (1) IT (122) joomla (1) Kiến thức (278) LAN Technology (3) life skills for (1) lifeskills (2) linux (13) Linux-Unix (24) mac address (1) Magazine (9) Mail (2) mail server (1) MCSA (7) Microsoft (28) mikrotik (3) Multipoint (1) Nagios (3) NAT (1) nested (1) Network (1) Network Load Balancing (1) News (1) Nghệ thuật sống (1) O365 (4) Office 365 (4) OSPF (1) Packet tracer (19) Pass4sure (1) Point to Point (1) Point-to-Point Protocol (PPP) – CHAP (1) Point-to-Point Protocol (PPP) – PAP (1) Policy (3) Port Security (1) Practice Labs (19) Prerequisites (1) proxy (1) relax (7) rhel7 (1) RIP (1) routerOS (3) Routing (1) SAN (1) SAN Storage (1) Scripts (6) Server (1) server room (1) Sharepoint Server 2007 (1) Sharepoint Server 2010 (1) Spanning Tree Protocol (1) SSH login without password (1) Static Default Route (1) Storage (1) subnet (1) switch (1) System Requirements for Windows Server 2012 (1) Tản mạn (2) tcp-ip (1) telnet (1) TestInside (1) Thư giãn (4) Thủ thuật (2) tip (3) Tips + Tricks (29) trick (1) Tutorial (29) Tutorialvirtual server HighAvailability (1) ubuntu (4) unix (3) Unix-Linux (8) usb (1) Virtual Private Network (VPN) - IPsec (Site-to-Site) (1) Virtual Trunking Protocol (1) Virtualization (2) Virtualization HighAvailability (1) virus (5) vmware (6) vpn (4) vpn client (1) vpn client to site (2) vpn site to site (2) vSphere 5 (6) vSphere 5.1 (1) WAN Technology (13) Warranty (1) wildcard mask (1) windows 7 (1) windows 8 (1) windows server 2008 (3) Windows Server 8 (1)

Facebook

Ethereum

Subscribe for New Post Notifications

Ripple

Ethereum Price

Monday Tuesday Wednesday
$402.89 $384.06 $396.34

Contact Form

Name

Email *

Message *

Bitcoin

Litecoin

Browsing Category " access list "

CCNA LAB - 4.6 Access List

CCNA LAB - 4.6 Access List


LAB 4-6: Access Control List (ACL)

You are the network administrator at Ranet, and have to config router Ranet-HQ to connect its LAN
to Branch network and Internet, and to config Access-List to control traffic as below:
(via its console)
1. Enable and set IP address on LAN interface to be the first assignable IP of this subnet.

2. Enable and set IP address on each serial interface to be the last assignable IP of its own subnet.

3. Set RIPv2 to be the router protocol on this router to exchange route with Ranet-BR

4. Set default route to allow the connection with internet.

5. Set access-list to prevent the connection from hosts in LAN as:
- allow only Admin-Host to telnet to Ranet-CoreSW (password: ranetpass)
- Not permit only User-Host1 to connect to any site in the internet.
- Any traffic beside these should be allow.

Remark: Use ACL no.100 only!, and use as short as possible to gain %Completion

Solution:


Ranet-HQ config:

(copy & paste these command below to Ranet-HQ)
en
conf t
int fa0/0
no sh
ip add 172.22.3.33 255.255.255.224
int s0/0/0
no sh
ip add 172.22.3.98 255.255.255.252
int s0/1/0
no sh
ip add 203.144.7.254 255.255.255.252
exit

router rip
version 2
network 172.22.0.0
no auto-summary
exit

ip route 0.0.0.0 0.0.0.0 s0/1/0
access-list 100 deny tcp 172.22.3.52 0.0.0.3 host 172.22.3.90 eq 23
access-list 100 deny tcp host 172.22.3.53 any eq 80
access-list 100 permit ip any any
int fa0/0
ip access-group 100 in

Ranet-HQ#copy run start
Destination filename [startup-config]?
Building configuration...
[OK]
.
----------------------- The End ---------------------

Everything is OK.

You can view and download this solution here.
Copyright by http://www.lecuong.info

Tính Wildcard Mask trong ACLs

Các bài toán tính wildcard mask

1. Wildcard mask match 1 host

Vd: Tính wildcard mask match host 192.168.1.1
Theo nguyên tắc: bit 0 kiểm tra – bit 1 bỏ qua
-> Địa chỉ IP: 192.168.1.1 0.0.0.0 hoặc từ khóa “host”

2. Wildcard mask match tất cả địa chỉ IP

Vd: Tính wildcard mask match tất cả địa chỉ IP
Theo nguyên tắc: bit 0 kiểm tra – bit 1 bỏ qua
-> Địa chỉ IP: 192.168.1.1 255.255.255.255 hoặc từ khóa “any”

3. Wildcard mask match 1 subnet

Vd: Tính wildcard mask match subnet 192.168.1.0/24
Cách tính: Lấy 255.255.255.255 trừ đi subnet mask của subnet
-> Địa chỉ IP: 192.168.1.1 0.0.0.255

4. Tính Wildcard mask match range địa chỉ IP liên tục

Vd: Tính wildcard mask match range từ 192.168.2.0 đến 192.168.4.255
Cách tính: Lấy địa chỉ cuối trừ địa chỉ đầu
-> Địa chỉ IP: 192.168.2.0 0.0.2.255

5. Tính widcard mask match 1 số IP add đầu tiên



Vd: Cho địa chỉ IP 192.168.1.0, tính wildcard mask match X host đầu tiên
-> Dải địa chỉ cần match: 192.168.1.0 - > 192.168.1.X
-> wildcard mask: 0.0.0.X (lấy địa chỉ cuối trừ địa chỉ đầu)
-> Địa chỉ IP: 192.168.1.0 0.0.0.X

6. Tính wildcard mask của nửa trên (upper half) hoặc nửa dưới (lower half) 1 dải mạng:

Vd: Cho địa chỉ IP 192.168.1.0, tính wildcard mask match nửa dải IP phía trên và dưới:
-> Dải địa chỉ nửa trên: 192.168.1.0 - > 192.168.1.127
-> wildcard mask: 0.0.0.127 (lấy địa chỉ cuối trừ địa chỉ đầu)
-> Địa chỉ IP: 192.168.1.0 0.0.0.127

-> Dải địa chỉ nửa dưới: 192.168.1.128 - > 192.168.1.255
-> wildcard mask: 0.0.0.127 (lấy địa chỉ cuối trừ địa chỉ đầu)
-> Địa chỉ IP: 192.168.1.128 0.0.0.127

7. Tính wildcard mask match IP lẻ, hoặc IP chẵn

1 địa chỉ Ip lẻ / chẳn là địa chỉ có octet cuối cùng dạng thập phân là số lẻ / chẳn

Vd:     IP lẻ - 192.168.1.1
          IP chẵn – 192.168.1.2
Nhận xét: bit cuối cùng của IP lẻ luôn là bit 1, bit cuối cùng của IP chẵn luôn là bit 0. Vậy wildcard mask thỏa mãn phải tạo ra một dải địa chỉ IP có bit cuối của octet cuối không đổi bằng 0 hoặc 1.

Giải pháp: để router luôn match bit cuối của octet cuối của địa chỉ IP, bit tương ứng trên wildcard mask phải là bit 0

Vd1: Cho địa chỉ IP: 192.168.1.0, tính wildcard mask match tất cả IP chẵn:
-> wildcard mask: 0.0.0.254 (dạng nhị phân: 00000000.00000000.00000000.11111110)
-> Địa chỉ IP: 192.168.1.0 0.0.0.254 (IP chẵn có bit cuối luôn bằng 0)

Vd2: Cho địa chỉ IP: 192.168.1.0, tính wildcard mask match tất cả IP lẻ
-> wildcard mask: 0.0.0.254 (dạng nhị phân: 00000000.00000000.00000000.11111110)
-> Địa chỉ IP: 192.168.1.1 0.0.0.254 (IP lẻ có bit cuối luôn bằng 1)

8. Tính wildcard mask match 1 range IP address không liên tục

Đây là dạng toán tính wildcard mask phức tạp nhất vì admin không có cách nào sử dụng 1 wildcard mask để tạo thành địa chỉ IP match tất cả dải IP ban đầu:

Vd: Tính wildcard mask match dải: 192.168.1.15 - > 192.168.1.75

Nhận xét: Đây là một dải IP không liên tục , không có 1 wildcard mask nào có thể thỏa mãn dải không liên tục. Tuy nhiên đối với những dải IP liên tục thì luôn có wildcard mask thỏa mãn.

Giải pháp: Chia dải IP ban đầu thành những dải nhỏ mà trong đó luôn tìm được 1 wildcard mask thỏa mãn mỗi dải. Vậy cách chia như thế nào? Nhắc lại: mỗi bit trong octet phần host đại diện cho một nhóm các host gọi là một block size. Bit cuối cùng là block size 1 vì nó thể hiện 1 host, tương tự bit đầu tiên là block size 128. Và, mỗi block size luôn tìm được 1 wildcard mask thỏa mãn.

Chia dải thành các block size:
- 192.168.1.15 (1)
- 192.168.1.16 - > 192.168.1.31 (2)
- 192.168.1.32 - > 192.168.1.63 (3)
- 192.168.1.64 -> 192.168.75 (4)

Tính wildcard mask cho mỗi block size:
- (1): 192.168.1.15 0.0.0.0 - > IP host
- (2): 192.168.1.16 0.0.0.15
- (3): 192.168.1.32 0.0.0.31
- (4): Chưa có wildcard mask phù hợp, ta phân tích dạng nhị phân octet cuối để tách tiếp wildcard mask:
.64: 01000000
.75: 01001011
-> Ta tách thành: 01000000 -> 01000111 (5)
01001000 -> 01001011 (6)
-> (5): 192.168.1.64 0.0.0.7
(6): 192.168.1.72 0.0.0.3

Tổng kết: Như vậy, từ dải IP ban đầu, ta tách thành 6 dải nhỏ (1)(2)(3)(4)(5)(6). Quả thật là một công trình “vĩ đại”…


(st)
Copyright by http://www.lecuong.info