ITC233 ASG1

16
Contents Question 1:........................................................2 1.1 Define subnet mask (or extended prefix length) for this organization..................................................... 2 1.2 Write IP number for the Subnet number 421 explicitly in binary and decimal notation (Note: The first subnet starts from zero). . .3 1.3 Write explicitly IP address of the host number 68 on the Subnet number 421................................................ 3 1.4 What is the broadcast address for the Subnet number 421?.....3 Question 2: Part I.................................................4 2.1 What is the source port number?..............................4 2.2 What is the destination port number?.........................4 2.3 What is the sequence number?.................................4 2.4 What is the acknowledgment number?...........................4 2.5 What is the length of the header?............................4 2.7 What is the window size?.....................................4 Question 2: Part II................................................5 Question 3:........................................................6 Question 3: Part I - IP address design............................7 Subnet the IP address............................................ 7 State the subnet masks........................................... 7 Choose an IP address for each PC and default gateway in LANs.....7 Question 3: Part II - Global configuration.........................8 Question 3: Part III - Connectivity verify.........................9 Question 3: Part IV - Network extension...........................10 How many useful IP addresses are left and why?..................10 If you are given only one extra device either one router or one switch to do expansion of this network, which one will you choose to obtain the maximum usable IP addresses? And why?.............10

description

Networking fundementals

Transcript of ITC233 ASG1

ContentsQuestion 1:............................................................................................................................................2

1.1 Define subnet mask (or extended prefix length) for this organization........................................2

1.2 Write IP number for the Subnet number 421 explicitly in binary and decimal notation (Note: The first subnet starts from zero)......................................................................................................3

1.3 Write explicitly IP address of the host number 68 on the Subnet number 421...........................3

1.4 What is the broadcast address for the Subnet number 421?......................................................3

Question 2: Part I...................................................................................................................................4

2.1 What is the source port number?................................................................................................4

2.2 What is the destination port number?........................................................................................4

2.3 What is the sequence number?...................................................................................................4

2.4 What is the acknowledgment number?.......................................................................................4

2.5 What is the length of the header?...............................................................................................4

2.7 What is the window size?............................................................................................................4

Question 2: Part II..................................................................................................................................5

Question 3:............................................................................................................................................6

Question 3: Part I - IP address design...................................................................................................7

Subnet the IP address........................................................................................................................7

State the subnet masks.....................................................................................................................7

Choose an IP address for each PC and default gateway in LANs.......................................................7

Question 3: Part II - Global configuration..............................................................................................8

Question 3: Part III - Connectivity verify................................................................................................9

Question 3: Part IV - Network extension.............................................................................................10

How many useful IP addresses are left and why?............................................................................10

If you are given only one extra device either one router or one switch to do expansion of this network, which one will you choose to obtain the maximum usable IP addresses? And why?......10

Question 1:

An organization is assigned the network number 172.10.0.0 /16, and it must create a set of subnets that supports up to 90 hosts on each subnet. Please answer the following questions:

Private IPv4 network rangesStart End No. of addresses

24-bit block (/8 prefix, 1 × A) 10.0.0.0 10.255.255.255 1677721620-bit block (/12 prefix, 16 × B) 172.16.0.0 172.31.255.255 104857616-bit block (/16 prefix, 256 × C) 192.168.0.0 192.168.255.255 65536

8 bit binary conversion table128 64 32 16 8 4 2 1

Class B default subnet mask for 172.10.0.0 /16 = 255.255.0.0

172.10.0.0172 10 0 01010 1100 0000 1010 0000 0000 0000 0000

172.10.0.0/16255 255 0 01111 1111 1111 1111 0000 0000 0000 0000

16bits 8bit 8bit 0bit 0bit

1.1 Define subnet mask (or extended prefix length) for this organization.

Requirements for sub netting – 90 Hosts

Option 1 - /25 (1bit subnet) – 1 subnet 126 hosts per subnet Option 2 - /26 (2bit subnet) – 3 subnets 62 hosts per subnet

Networking ID 172.10.0.0 /25

172.10.0.0/25255 255 255 128111 11111 1111 1111 1111 1111 1000 000

25bit (1bit subnet) 8bit 8bit 8bit 1bit

Subnet mask 255.255.255.128

1.2 Write IP number for the Subnet number 421 explicitly in binary and decimal notation (Note: The first subnet starts from zero)

Subnet NumberSubnet 1 172 10 0 0Subnet 2 172 10 0 128Subnet 3 172 10 1 0Subnet 4 172 10 1 128

Continued….

Subnet 419 172 10 109 0Subnet 420 172 10 209 128Subnet 421 172 10 210 0Subnet 422 172 10 210 128

Odd subnets start the IP range with a 0 (172.10.xxx.1 – 172.10.xxx.127 usable)Even subnets start the IP range with a 128 (172.10.xxx.129 – 172.10.xxx.254 usable)

Subnet ID for Subnet 421172.10.210.0 /25

Subnet 421 172 10 210 0Binary 10101100 0000 1010 1101 0010 0000 0000

1.3 Write explicitly IP address of the host number 68 on the Subnet number 421

172.10.210.0 Reserved for subnet ID Therefore host number 68 would simply be 172.10.210.68

IP 172 10 210 68Binary 10101100 0000 1010 1101 0010 0100 0100

1.4 What is the broadcast address for the Subnet number 421?

Subnet 421 can support up to 126 hosts Subnet 421 has a subnet ID of 172.10.210.0 Therefor subnet 421 will have a broadcast address of 172.10.210.127

Question 2: Part I The following is a dump of a TCP header in hexadecimal format:

00CD0018 00000EF1 00000D5D 502200D1 01BF0010

2.1 What is the source port number?Source Port Bits Hexadecimal Binary Decimal16bits 00CD 11001101 205

2.2 What is the destination port number? Destination Port Bits Hexadecimal Binary Decimal16bits 0018 00011000 24

2.3 What is the sequence number? Sequence Number Bits Hexadecimal Binary Decimal32bits 00000EF1 111011110001 3825

2.4 What is the acknowledgment number? Bits Hexadecimal Binary Decimal32bits 00000D5D 110101011101 3421

2.5 What is the length of the header? Bits Hexadecimal Binary Decimal4bits 5 0101 5

The minimum size header is 5 words and the maximum is 15 words thus giving the minimum size of 20 bytes and maximum of 60 bytes, allowing for up to 40 bytes of options in the header.

Therefor 5 = 20 bytesThe TCP Header Length is 20 Bytes

2.6 Which control bits are set? And what do they represent?

Bits Hexadecimal Binary Decimal000100010 (URG, SYN)

Indicates that the Urgent pointer field is significant Synchronize sequence numbers. Only the first packet sent from each end should have this flag set. Some

other flags change meaning based on this flag, and some are only valid for when it is set, and others when it is clear.

2.7 What is the window size?

Window Size 16bits Hexadecimal Binary Decimal00D1 00D1 11010001 209

Question 2: Part II

2.8 what does the last four digits ‘0010' of the above dump represent? What action will the destination node take when it receives this packet?

As shown in the contents of TCP header table below the final 16bits, in this case 0010 represents the Urgent Pointer.

This field communicates the current value of the urgent pointer as a positive offset from the sequence number in this segment. The urgent pointer points to the sequence number of the octet following the urgent data. This field is only be interpreted in segments with the URG control bit set. Working notes for Question 2

Question 2 notes and working out

Decimal to Hex conversion table

Dec 0 1 2 3 4 5 6 7 8 9 10 1112

13 14 15

Hex 0 1 2 3 4 5 6 7 8 9 A B C D E F

The contents of a TCP Header:

Source Port - 16 bits Destination Port - 16 bitsSequence Number - 32 bits

Acknowledgment Number - 32 bitsData offset - 4 bits / Reserved - 3 bits / Flags - 6 bits Window - 16 bits

Header Checksum - 16 bits Urgent Pointer - 16 bitsOptions

Data offset (4 bits) – specifies the size of the TCP header in 32-bit words.

Data offset

Reserved0 0 0

NS

CWR

ECE

URG

ACK

PSH

RST

SYN

FIN

4bits 3bits 1 bit 1 bit 1 bit 1 bit 11 bit 11 bit 11 bit 11 bit 1 bit

Flags (9 bits) (aka Control bits) – contains 9 1-bit flags

NS (1 bit) – ECN-nonce concealment protection (added to header by RFC 3540). CWR (1 bit) – Congestion Window Reduced (CWR) flag is set by the sending host to indicate that it received a TCP

segment with the ECE flag set and had responded in congestion control mechanism. ECE (1 bit) – ECN-Echo indicates If the SYN flag is set (1), that the TCP peer is ECN capable. If the SYN flag is clear (0), that a packet with Congestion Experienced flag in IP header set is received during

normal transmission (added to header by RFC 3168). URG (1 bit) – indicates that the Urgent pointer field is significant ACK (1 bit) – indicates that the Acknowledgment field is significant. All packets after the initial SYN packet sent by

the client should have this flag set. PSH (1 bit) – Push function. Asks to push the buffered data to the receiving application. RST (1 bit) – Reset the connection SYN (1 bit) – Synchronize sequence numbers. Only the first packet sent from each end should have this flag set.

Some other flags change meaning based on this flag, and some are only valid for when it is set, and others when it is clear.

FIN (1 bit) – No more data from sender

Reference (http://en.wikipedia.org/wiki/Transmission_Control_Protocol)

Question 3:

NotesThis question is designed to test your practical networking skills by using Packet Tracer simulation software. The task is to set-up and configure two networks (LAN1, LAN2) that are connected via a serial connection (WAN1).

Below is a diagram of the network:

The IP address of LAN1 is assigned as 192.168.10.0/24 and LAN2 is 192.168.20.0/24. And the WAN connection between the two routers is 209.1.14.0/24.

LAN 1 will have 14 users (PC1 and PC2 stand for the users with the lowest and highest usable IP), LAN 2 will have 29 users (PC3 and PC4 stands for the users with the lowest and highest usable IP) and the WAN link should have 2 IP addresses individually. Please use VLSM to design the IP address for the device of each LAN and configure the given network. The configuration of this question includes 4 stages; each stage has various tasks to complete.

Question 3: Part I - IP address design

Subnet the IP address

State the subnet masks

Choose an IP address for each PC and default gateway in LANs

Designated NetworksLAN 1 192.168.10.0 /24LAN 1 192.168.20.0 /24WAN 209.1.14.0 /24

Note: The LOWEST IP addresses of each subnet should be given to the two PCs (PC1 and PC3). The second HIGHEST IPs should be given to PC3 and PC4. And the HIGHEST IP addresses of each subnet are given as the default gateway.

LAN 1 192.168.10.0 /24Requirements 14 Users 1 Default Gateway Subnets == 15 IP addresses. Subnet /27 supports 30 hostsPC1 192.168.10.1PC2 192.168.10.14Default Gateway 192.168.10.15Subnet Mask 255.255.255.224IP Range 192.168.20.1 – 192.168.20.29Subnet ID 192.168.20.0Broadcast ID 192.168.20.30

LAN 2 192.168.20.0 /24Requirements 29 Users 1 Default Gateway Subnets == 30 IP addresses. Subnet /27 supports 30 hostsPC3 192.168.20.1PC4 192.168.20.29Default Gateway 192.168.20.30Subnet Mask 255.255.255.224IP Range 192.168.20.1 – 192.168.20.29Subnet ID 192.168.20.0Broadcast ID 192.168.20.30

WAN 209.1.14.0 /24Requirements 2 hosts Subnet /30 supports 2 hostsR1 (Router 1) 209.1.14.1R2 (Router 2) 209.1.14.2Subnet Mask 255.255.255.252Subnet ID 209.1.14.0Broadcast ID 209.1.14.3

Question 3: Part II - Global configuration

Configure Router R1 and R2;

Naming the routers as R1 and R2;

Router> enableRouter# configure terminalRouter(config)# hostname R1 (R2 on Router 2)Router(config)# CTRL-ZR1# copy running-config startup-configR1# exit

Passwords

Setting secret password as class on all routers; Configuring TELNET on the R1 router with a password of ‘xyz123’

R1> enableR1# configure terminalR1(config)# enable secret classR1(config)# line vty 0 4R1(config)# password xyz123R1(config)# line console 0R1(config)# password xyz123R1(config)# CTRL-ZR1# copy running-config startup-configR1# exit

MOTD

MOTD

R1> enableR1# configure terminalR1(config)# banner motd #Welcome to ITC233, Peter Voght’s ASG1#R1(config)# CTRL-ZR1# copy running-config startup-configR1# exit

Question 3: Part III - Connectivity verify

Ping from PC1 in LAN1 to PC4 in LAN2. Record the information flow in EVENT LIST of simulation and explain the PDU information such as TYPE and involved layers in each stage;

PC1 192.168.10.1PC4 192.168.20.29

Question 3: Part IV - Network extension

Using your subnetting how many possible WAN links are LEFT and Why?

WAN 209.1.14.0 /24Requirements 2 hosts Subnet /30 supports 2 hostsR1 (Router 1) 209.1.14.1R2 (Router 2) 209.1.14.2Subnet Mask 255.255.255.252Subnet ID 209.1.14.0Broadcast ID 209.1.14.3

Before the subnet of 255.255.255.252 was applied the network of 209.1.14.0 /24 had a possible range of 209.1.14.1 – 209.1.14.254

However, after applying the subnet mask it cut the number of possible links on that same subnet to 2.

Therefore after using host IPs for R1 and R2, there are no subnets left on this subnet.

How many useful IP addresses are left and why? As mentioned above both IP addresses on the 209.1.14.0 /30 network are being used so there are no free IP addresses.

However on the 209.1.14.0 /24 range there is the possibility for another x63 (209.1.14.*** /30) networks

Which means there is a possibility of (63 subnets) X (2 hosts per subnet) = there is a possibility for 126 IPs left in the 209.1.14.0 /24 network

If you are given only one extra device either one router or one switch to do expansion of this network, which one will you choose to obtain the maximum usable IP addresses? And why?

To expand this network to support the most possible IP addresses would be a switch. The reason is because the router provides a network address and could connect ONE pc to another network where as if we connected a switch to another switch on this network it would give us the potential to use the unallocated IP addresses within the 192.168.10.xx /27 or 192.168.20.xx /27 networks