From cba64fd45faf3f8d7981a8e28b0f21881d0f7eb5 Mon Sep 17 00:00:00 2001
From: Mohit Agarwal <mohit.agarwal@sky.com>
Date: Sun, 10 Oct 2021 15:12:23 +0100
Subject: Writing notes and questions.

---
 notes/networks.tex | 105 +++++++++++++++++++++++++++++++++++++++++++++++++++++
 1 file changed, 105 insertions(+)

(limited to 'notes/networks.tex')

diff --git a/notes/networks.tex b/notes/networks.tex
index a41c844..e01c094 100644
--- a/notes/networks.tex
+++ b/notes/networks.tex
@@ -92,3 +92,108 @@ point of failure and can be eavesdropped on, leading to the compromise
 of all data. Data sent by one device is received by all other devices
 thus compromising privacy and only one device can send data on the
 backbone at a time, thus slowing the network.
+
+\subsection{Star topology}
+
+
+\begin{center}
+\begin{tikzpicture}
+    \filldraw (0,0) circle (3pt);
+    \draw [-o] (0,0) -- (7,0);
+    \draw [-o] (0,0) -- (5,3);
+    \draw [-o] (0,0) -- (-4,2);
+    \draw [-o] (0,0) -- (-3,-1);
+    \draw [-o] (0,0) -- (2,-2);
+    \draw [-o] (0,0) -- (0,2.5);
+\end{tikzpicture}
+\end{center}
+
+The star topology is designed with a central device; either a
+\textbf{hub} or a \textbf{switch}. All devices are connected to this
+central device. Naturally, this uses far more cable than the bus
+topology. A hub will take data and send it to all other nodes in the
+network, which creates excess traffic, lends itself to eavesdropping,
+and is quite slow. However, hubs are generally outdated and switches
+are used. A switch will only route data to the correct segment.
+Switches are high performance, secure, scalable, and reliable,
+however, they and the cost of cable in the star topology can be quite
+expensive. Furthermore, although the backbone of the bus is no longer
+a single point of failure, the hub or switch can be.
+
+Modern networks are generally modified versions of the star topology
+with a switch in the centre.
+
+\section{The TCP/IP stack and protocols}
+
+A protocol is an agreed method of communication for sharing data.
+The \textit{TCP/IP network stack} is perhaps the most popular and
+commonly used network protocol stack. Therefore, we consider the stack
+and a simplified model of how data is transferred. These are the
+\textit{layers} of the stack in order:
+
+\subsection{Application layer}
+
+The application layer is where the user interacts. Because of this the
+most commonly known protocols exist on this layer. \textit{Hypertext
+Transfer Protocol} (HTTP) is perhaps the most well known protocol. It
+is used to describe web pages in a way that is understandable by
+humans. Many websites today use HTTPS, the secure version of HTTP
+which includes encryption so that a communication that is eavesdropped
+on cannot be understood. Other protocols in this layer include the
+\textit{File Transfer Protocol} (FTP), and the protcolos used for
+email: the \textit{Internet Message Access Protocol} (IMAP) which
+receives mail, the \textit{Simple Mail Transfer Protocol} (SMTP) which
+sends mail, and the older \textit{Post Office Protocol 3} which also
+receives mail.
+
+\subsection{Transport later}
+
+The transport layer establishes basic communications channels,
+might ensure that data arrives in the correct order by numbering data,
+and potentially ensuring reliability through error checking
+information.
+
+The \textit{Transmission Control Protocol} (TCP) is at this layer and
+sends data with error checking and ordering information. Data is
+ordered at the receiving end and if it is found incorrect by error
+checking, then it requested by again. The TCP specifies a
+\textit{handshake} procedure that the process must begin with in order
+to establish the communication properly. This is therefore a very
+reliable protocol, making it useful for message based communications
+or transfer of data where there should not be mistakes.
+
+The \textit{User Datagram Protocol} (UDP) is another protocol at this
+layer. There is no handshake process, and data is simply sent as a
+continuous \textit{bite stream}. If the data received contains errors
+or is missing there is no process to repair this. The protocol is
+therefore very fast but not as reliable as TCP. Therefore, it is used
+in cases such as video streaming, where small errors or some missing
+data is acceptable.
+
+\subsection{Network layer}
+
+The network layer is responsible for addressing and routing packets of
+data. Each packet contains a source, destination, a small amount of
+data, and error checking information. The \textit{Internet Protocol}
+(IP) is the standard protocol at this layer, and specifies addresses
+with the IPv4 standard, which uses a 32 bit address giving around 4.3
+billion unique addresses. This is being replaced by IPv6 which uses
+128 bit addresses to yield around $3.4 \times 10^{38}$ unique
+addresses
+\footnote{\url{https://en.wikipedia.org/wiki/Internet_Protocol}}.
+
+\subsection{Data link layer}
+
+The data link layer converts the data produced by the above layers
+into signals that will be sent over the network. This consists of the
+network hardware. In particular, networked computers have a
+\textit{Network Interface Card}, which turns the data into electrical
+signals. Consumer systems today typically contain a \textit{Wireless
+Network Interface Card} which allows communications through Wi-Fi and
+Bluetooth.
+
+\subsection{Physical layer}
+
+The physical layer is the communication media and method by which
+data is transferred, such as the Ethernet standard over twisted pair
+or Wi-Fi by the use of radio waves.
-- 
cgit v1.2.3

