ipop part A session 1

0.0(0)
Studied by 0 people
call kaiCall Kai
learnLearn
examPractice Test
spaced repetitionSpaced Repetition
heart puzzleMatch
flashcardsFlashcards
GameKnowt Play
Card Sorting

1/112

encourage image

There's no tags or description

Looks like no tags are added yet.

113 Terms

1
New cards
IPv4 address
(IPv4) A 32 bit address that identifies a host's network interface.
2
New cards
IPv6 address
(IPv6) A 128 bit address. It is written as 8 groups of 16 bits.
3
New cards
Prefix length /n
(IPv4) The number of bits at the start of the address that make up the network part. The rest is the host part.
4
New cards
NetID
(IPv4) The network part of an IP address. It says which network the host is in.
5
New cards
HostID
(IPv4) The host part of an IP address. It says which host it is inside the network.
6
New cards
Network address
(IPv4) The first address of a block, where all host bits are 0. It names the network and cannot be given to a host.
7
New cards
Directed broadcast address
(IPv4) The last address of a block, where all host bits are 1. It reaches every host in the network and cannot be given to a host.
8
New cards
Addresses in an IPv4 /n block
(IPv4) 2^(32 − n) addresses.
9
New cards
Usable hosts in an IPv4 /n block
(IPv4) 2^(32 − n) − 2. You subtract the network address and the broadcast address.
10
New cards
/24 mask and block
(IPv4) Mask 255.255.255.0. A block of 256 addresses.
11
New cards
/25 mask and block
(IPv4) Mask 255.255.255.128. A block of 128 addresses.
12
New cards
/26 mask and block
(IPv4) Mask 255.255.255.192. A block of 64 addresses.
13
New cards
/27 mask and block
(IPv4) Mask 255.255.255.224. A block of 32 addresses.
14
New cards
/28 mask and block
(IPv4) Mask 255.255.255.240. A block of 16 addresses.
15
New cards
/29 mask and block
(IPv4) Mask 255.255.255.248. A block of 8 addresses.
16
New cards
/30 mask and block
(IPv4) Mask 255.255.255.252. A block of 4 addresses.
17
New cards
/23 mask and block
(IPv4) Mask 255.255.254.0. A block of 512 addresses, which is 2 steps in the third number.
18
New cards
/22 mask and block
(IPv4) Mask 255.255.252.0. A block of 1024 addresses, which is 4 steps in the third number.
19
New cards
How to find the network address
(IPv4) Find the block size. Then take the biggest multiple of the block size that is not larger than your number.
20
New cards
How to find the broadcast address
(IPv4) Take the network address and add the block size minus 1.
21
New cards
Private IPv4 ranges
(IPv4) 10.0.0.0/8, 172.16.0.0/12 and 192.168.0.0/16. They are not routed on the Internet.
22
New cards
Routing
(Routing) Working out the best paths through the network. Routers do this in the background with a routing protocol.
23
New cards
Forwarding
(Forwarding) Sending each arriving packet out on the right interface, using the forwarding table.
24
New cards
Aggregation
(Forwarding) Merging several routes into one route with a shorter prefix. This makes the forwarding table smaller.
25
New cards
When can two networks be merged?
(Forwarding) When they have the same prefix length n and their first n − 1 bits are equal. Then together they fill one /(n − 1) block exactly.
26
New cards

Blackholing

(Forwarding) Announcing addresses that you do not actually have. Packets sent to those addresses are dropped. It can happen if you merge routes into a block that is too big.

27
New cards
Longest prefix match
(Forwarding) If several rows in the forwarding table match the destination, the row with the longest prefix wins, because it is the most specific.
28
New cards
Default route
(Forwarding) 0.0.0.0/0. It matches every address, so it is only used when no other row matches.
29
New cards
Flag U
(Forwarding) Up. The route works and can be used.
30
New cards
Flag G
(Forwarding) Gateway. The destination is further away, so the packet is handed to the router in the next hop column.
31
New cards
Flag H
(Forwarding) Host. The row points to one single host, not a whole network.
32
New cards
No G flag
(Forwarding) The network is directly connected to this router. The router delivers the packet itself.
33
New cards
MAC address
(Link layer) The hardware address of a network card. On a local network, frames are delivered by MAC address.
34
New cards
Subnet
(IP) One local network. All its hosts have the same network part in their IP addresses.
35
New cards
ARP
(ARP) Address Resolution Protocol. It finds the MAC address that belongs to an IP address, but only inside the same subnet.
36
New cards
ARP request is sent as
(ARP) A broadcast to everyone on the local network, because the sender does not know the MAC address yet.
37
New cards
ARP reply is sent as
(ARP) A unicast, only back to the host that asked.
38
New cards
ARP cache
(ARP) A table of IP to MAC answers the host has already learned. The entries time out after a while.
39
New cards
ARP snooping
(ARP) Hosts that hear an ARP request save the sender's IP and MAC address, even though the request was not for them.
40
New cards
Gratuitous ARP
(ARP) A host sends an ARP request for its own IP address. It announces itself and checks that nobody else uses the address.
41
New cards
Proxy ARP
(ARP) A router answers ARP requests on behalf of a host that sits behind it.
42
New cards
To reach another subnet, a host ARPs for
(ARP) Its router (the default gateway). ARP cannot reach beyond the subnet, so the packet goes to the router first.
43
New cards
Router
(Router) Connects different subnets. It forwards packets by looking at the IP address.
44
New cards
Bridge (switch)
(Bridge) Connects computers inside one subnet. It forwards frames by looking at the MAC address.
45
New cards
How a bridge learns where a MAC is
(Bridge) It reads the source MAC address of each incoming frame and notes which port it came from.
46
New cards
Does a bridge change addresses?
(Bridge) No. It passes frames on without changing the MAC or IP addresses.
47
New cards
What changes when a packet passes a router?
(Router) The MAC addresses. The router writes a new Ethernet header for the next link. The IP addresses stay the same.
48
New cards
ICMP
(ICMP) A protocol that carries error and test messages for IP.
49
New cards
Ping uses
(ICMP) ICMPv4 Echo Request (type 8) and Echo Reply (type 0).
50
New cards
TTL
(IP) Time To Live. A counter in the IP header that each router lowers by 1. When it runs out, the packet is dropped, so packets cannot loop forever.
51
New cards
MTU
(Fragmentation) The largest packet a link can carry.
52
New cards
Fragmentation
(Fragmentation) Cutting an IP datagram into smaller pieces when it is bigger than the MTU of the next link.
53
New cards
IPv4 header size
(IPv4) 20 bytes without options. With options it can be up to 60 bytes.
54
New cards
UDP header size
(UDP) 8 bytes.
55
New cards
TCP header size
(TCP) 20 bytes without options.
56
New cards
Data in a fragment (not the last)
(Fragmentation) Must be a multiple of 8 bytes. Only the last fragment may have any size.
57
New cards
Max data per fragment
(Fragmentation) MTU minus 20 (the IP header), rounded down to a multiple of 8.
58
New cards
Fragment offset is counted in
(Fragmentation) Units of 8 bytes. Offset = the position of the data divided by 8.
59
New cards
MF flag
(Fragmentation) More Fragments. It is 1 on every fragment except the last one.
60
New cards
DF flag
(Fragmentation) Don't Fragment. If it is set and the packet is too big, the router drops it and sends an error back.
61
New cards
Who reassembles fragments?
(Fragmentation) Only the destination host. Routers never put fragments back together.
62
New cards
One fragment is lost
(Fragmentation) The whole datagram is thrown away.
63
New cards
Who fragments in IPv6?
(Fragmentation) Only the sending host. Routers in IPv6 do not fragment.
64
New cards
Transport header (UDP/TCP) sits in
(Fragmentation) Only the first fragment. Add it to the data before you split.
65
New cards
Distance vector
(Routing) Each router sends its list of distances to its neighbours. No router knows the whole map.
66
New cards
Link state
(Routing) Each router floods information about its own links to all routers. So every router knows the whole map and computes the paths itself.
67
New cards
Path vector
(Routing) Like distance vector, but each route also carries the full path to the destination.
68
New cards
IGP
(Routing) Interior Gateway Protocol. Routing inside one network, for example RIP and OSPF.
69
New cards
EGP
(Routing) Exterior Gateway Protocol. Routing between networks, for example BGP.
70
New cards
RIP
(RIP) A routing protocol used inside one network. Every 30 seconds, each router sends its list of distances to its neighbours. The distance is counted in hops, meaning the number of routers on the way.
71
New cards
RIP infinity
(RIP) 16 means "this network cannot be reached", so a route can be at most 15 hops long. When a route stops working, the router sets it to 16 and tells its neighbours straight away, without waiting the usual 30 seconds. This is called a triggered update.
72
New cards
Triggered update
(RIP) Sending a change to the neighbours right away, instead of waiting for the next 30 second update.
73
New cards
Distance vector update
(RIP) New cost = link cost to the neighbour + the neighbour's own cost. The router keeps the new route if it is cheaper.
74
New cards
Count to infinity
(RIP) After a link breaks, two routers keep telling each other old routes, so the cost keeps going up: 3, 4, 5 … It stops when it reaches 16.
75
New cards
Split horizon
(RIP) A router never advertises a route back to the neighbour it learned it from. This stops two routers from fooling each other.
76
New cards
Poison reverse
(RIP) The router does advertise the route back to the neighbour it learned it from, but with cost 16, meaning "do not use me for this".
77
New cards
OSPF
(OSPF) A link state routing protocol used inside one network. Each router computes the paths with Dijkstra's algorithm. The metric is often based on link capacity.
78
New cards
LSA
(OSPF) Link state advertisement. The message in which an OSPF router describes its links. It is flooded to all routers.
79
New cards
OSPF areas
(OSPF) A big network (AS) is split into smaller areas, which are joined through area 0.
80
New cards
BGP
(BGP) The routing protocol between autonomous systems, the separate networks that make up the Internet. It is a path vector protocol and runs over TCP port 179.
81
New cards
Autonomous system (AS)
(BGP) A network with one routing policy and its own AS number.
82
New cards
Why BGP can spot loops
(BGP) Each route lists the AS numbers on the path. If a router sees its own AS in the list, the route is a loop.
83
New cards
Port number
(UDP/TCP) A 16 bit number that says which program on the host the data is for.
84
New cards
UDP
(UDP) Sends single messages without a connection. There are no guarantees: messages can be lost or arrive out of order.
85
New cards
TCP
(TCP) Sets up a connection and gives a reliable byte stream. The data arrives complete and in order.
86
New cards
Pseudoheader
(UDP) Information from the IP header, such as the IP addresses. It is used when computing the checksum but is never sent.
87
New cards
Stop and Wait
(Reliable transfer) The sender sends one packet and waits for its ACK before sending the next.
88
New cards
Go Back N max window
(Reliable transfer) 2^m − 1, where m is the number of bits in the sequence number. The receiver does not keep packets that arrive out of order.
89
New cards
Selective Repeat max window
(Reliable transfer) 2^(m−1). The receiver keeps packets that arrive out of order, so only the lost ones are resent.
90
New cards
Utilisation U
(Reliable transfer) The share of time the link is busy sending. U = N × (L/B) ÷ (RTT + L/B), at most 1. N is the window, L the packet length and B the link speed. For Stop and Wait, N = 1.
91
New cards
How to improve utilisation
(Reliable transfer) Use a bigger window N, so more packets are sent before waiting for an ACK.
92
New cards
TCP sequence numbers count
(TCP) Bytes, not segments.
93
New cards
ACK number
(TCP) The number of the next byte the receiver expects.
94
New cards
SYN
(TCP) The flag used to open a connection.
95
New cards
FIN
(TCP) The flag used to close a connection.
96
New cards
Three way handshake
(TCP) The client sends SYN, the server answers SYN+ACK, and the client answers ACK. Then the connection is open.
97
New cards
SYN and FIN each use
(TCP) One sequence number, even though they carry no data.
98
New cards
MSS
(TCP) Maximum Segment Size. The most data one TCP segment can carry. For IPv4 without options it is MTU − 20 − 20.
99
New cards
RTT
(TCP) Round trip time. The time from sending a segment until its ACK comes back.
100
New cards
RTO
(TCP) Retransmission timeout. How long TCP waits for an ACK before it resends the segment.