Computer Network
Computer Network
Definition
A computer network is a group of computers linked to each other that
enables the computer to communicate with another computer and share
their resources, data, and applications.
1. Resource Sharing –
Many organization has a substantial number of computers in
operations, which are located apart. Ex. A group of office workers
can share a common printer, fax, modem, scanner, etc.
2. High Reliability –
If there are alternate sources of supply, all files could be
replicated on two or more machines. If one of them is not
available, due to hardware failure, the other copies could be
used.
3. Inter-process Communication –
Network users, located geographically apart, may converse in an
interactive session through the network. In order to permit this,
the network must provide almost error-free communications.
4. Flexible access –
Files can be accessed from any computer in the network. The
project can be begun on one computer and finished on another.
1. Wired NIC
2. Wireless NIC
Wired NIC: The Wired NIC is present inside the motherboard. Cables and
connectors are used with wired NIC to transfer data.
Wireless NIC: The wireless NIC contains the antenna to obtain the
connection over the wireless network. For example, laptop computer
contains the wireless NIC.
Hub
A Hub is a hardware device that divides the network connection among
multiple devices. When computer requests for some information from a
network, it first sends the request to the Hub through cable. Hub will
broadcast this request to the entire network. All the devices will check
whether the request belongs to them or not. If not, the request will be
dropped.
The process used by the Hub consumes more bandwidth and limits the
amount of communication. Nowadays, the use of hub is obsolete, and it is
replaced by more advanced computer network components such as
Switches, Routers.
Switch
A switch is a hardware device that connects multiple devices on a
computer network. A Switch contains more advanced features than Hub.
The Switch contains the updated table that decides where the data is
transmitted or not. Switch delivers the message to the correct destination
based on the physical address present in the incoming message. A Switch
does not broadcast the message to the entire network like the Hub. It
determines the device to whom the message is to be transmitted.
Therefore, we can say that switch provides a direct connection between
the source and destination. It increases the speed of the network.
Router
Advantages Of Router:
Security: The information which is transmitted to the network
will traverse the entire cable, but the only specified device which
has been addressed can read the data.
Reliability: If the server has stopped functioning, the network
goes down, but no other networks are affected that are served
by the router.
Performance: Router enhances the overall performance of the
network. Suppose there are 24 workstations in a network
generates a same amount of traffic. This increases the traffic
load on the network. Router splits the single network into two
networks of 12 workstations each, reduces the traffic load by
half.
Network range
Modem
Peer-To-Peer network
Client/Server network
Peer-To-Peer network
Client/Server Network
The OSI model is divided into two layers: upper layers and lower
layers.
The upper layer of the OSI model mainly deals with the
application related issues, and they are implemented only in the
software. The application layer is closest to the end user. Both
the end user and the application layer interact with the software
applications. An upper layer refers to the layer just above
another layer.
The lower layer of the OSI model deals with the data transport
issues. The data link layer and the physical layer are
implemented in hardware and software. The physical layer is the
lowest layer of the OSI model and is closest to the physical
medium. The physical layer is mainly responsible for placing the
information on the physical medium.
Model
Physical layer
Data-Link Layer
Framing: The data link layer translates the physical's raw bit
stream into packets known as Frames. The Data link layer adds
the header and trailer to the frame. The header which is added to
the frame contains the hardware destination and source address.
Physical Addressing: The Data link layer adds a header to the
frame that contains a destination address. The frame is
transmitted to the destination address mentioned in the header.
Flow Control: Flow control is the main functionality of the Data-
link layer. It is the technique through which the constant data
rate is maintained on both the sides so that no data get
corrupted. It ensures that the transmitting station such as a
server with higher processing speed does not exceed the
receiving station, with lower processing speed.
Error Control: Error control is achieved by adding a calculated
value CRC (Cyclic Redundancy Check) that is placed to the Data
link layer's trailer which is added to the message frame before it
is sent to the physical layer. If any error seems to occurr, then
the receiver sends the acknowledgment for the retransmission of
the corrupted frames.
Access Control: When two or more devices are connected to
the same communication channel, then the data link layer
protocols are used to determine which device has control over
the link at a given time.
Network Layer
Transport Layer
Session Layer
Application Layer
As shown in the above diagram, the TCP/IP model has 4 layers, while the
OSI model consists of 7 layers. Diagrammatically, it looks that the 4 layers
of the TCP/IP model exactly fit the 7 layers of the OSI model, but this is not
reality. The application layer of the TCP/IP model maps to the first three
layers, i.e., application, session, and presentation layer of the OSI model.
The transport layer of the TCP maps directly to the transport layer of the
OSI model. The internet layer of the TCP/IP model maps directly to the
network layer of the OSI model. The last two layers of the OSI model map
to the network layer of the TCP/IP model. TCP/IP is the most widely used
model as compared to the OSI model for providing communication
between computers over the internet.
Both the models are the logical models and having similar architectures
as both the models are constructed with the layers.
Define standards
Both the layers have defined standards, and they also provide the
framework used for implementing the standards and devices.
Pre-defined standards
The standards and protocols which are already pre-defined; these models
do not redefine them; they just reference or use them. For example, the
Ethernet standards were already defined by the IEEE before the
development of these models; instead of recreating them, models have
used these pre-defined standards.
In this technique, each frame has sent from the sequence number. The
sequence numbers are used to find the missing data in the receiver end.
The purpose of the sliding window technique is to avoid duplicate data, so
it uses the sequence number.
1. Go-Back-N ARQ
2. Selective Repeat ARQ
Go-Back-N ARQ
Go-Back-N ARQ protocol is also known as Go-Back-N Automatic Repeat
Request. It is a data link layer protocol that uses a sliding window method.
In this, if any frame is corrupted or lost, all subsequent frames have to be
sent again.
4.5M
How to Get Linux Kernel 5.0 in Ubuntu 18.04 LTS Right Now
The size of the sender window is N in this protocol. For example, Go-Back-
8, the size of the sender window, will be 8. The receiver window size is
always 1.
If the receiver receives a corrupted frame, it cancels it. The receiver does
not accept a corrupted frame. When the timer expires, the sender sends
the correct frame again. The design of the Go-Back-N ARQ protocol is
shown below.
If the receiver receives a corrupt frame, it does not directly discard it. It
sends a negative acknowledgment to the sender. The sender sends that
frame again as soon as on the receiving negative acknowledgment. There
is no waiting for any time-out to send that frame. The design of the
Selective Repeat ARQ protocol is shown below.
The example of the Selective Repeat ARQ protocol is shown below in the
figure.
Difference between the Go-Back-N ARQ and Selective Repeat
ARQ?
If a frame is corrupted or lost in it,all In this, only the frame is sent again, which
subsequent frames have to be sent corrupted or lost.
again.
It does not require sorting. In this, sorting is done to get the frames in t
correct order.
ARP/RARP/GARP
Address Resolution Protocol (ARP) –
Address Resolution Protocol is a communication protocol used for
discovering physical address associated with given network address.
Typically, ARP is a network layer to data link layer mapping process, which
is used to discover MAC address for given Internet Protocol Address.
In order to send the data to destination, having IP address is necessary
but not sufficient; we also need the physical address of the destination
machine. ARP is used to get the physical address (MAC address) of
destination machine..
A special host configured inside the local area network, called as RARP-
server is responsible to reply for these kind of broadcast packets. Now the
RARP server attempt to find out the entry in IP to MAC address mapping
table. If any entry matches in table, RARP server send the response
packet to the requesting device along with IP address.
LAN technologies like Ethernet, Ethernet II, Token Ring and Fiber
Distributed Data Interface (FDDI) support the Address Resolution
Protocol.
RARP is not being used in today’s networks. Because we have
much great featured protocols like BOOTP (Bootstrap Protocol)
and DHCP( Dynamic Host Configuration Protocol).
Gratuitous ARP –
Gratuitous Address Resolution Protocol is used in advance network
scenarios. It is something performed by computer while booting up. When
the computer booted up (Network Interface Card is powered) for the first
time, it automatically broadcast its MAC address to the entire network.
After Gratuitous ARP MAC address of the computer is known to every
switch and allow DHCP servers to know where to send the IP address if
requested.
Gratuitous ARP could mean both Gratuitous ARP request and Gratuitous
ARP reply, but not needed is all cases. Gratuitous ARP request is a packet
where source and destination IP are both set to IP of the machine issuing
the packet and the destination MAC is the broadcast address ff:ff:ff:ff:ff:ff ;
no reply packet will occur.
Gratuitous ARP is ARP-Reply that was not prompted by an ARP-Request.
Gratuitous Address Resolution Protocol is useful to detect IP conflict.
Gratuitous ARP is also used to update ARP mapping table and Switch port
MAC address table.
Pure Aloha:
When a station sends data it waits for an acknowledgement. If
the acknowledgement doesn’t come within the allotted time then
the station waits for a random amount of time called back-off
time (Tb) and re-sends the data. Since different stations wait for
different amount of time, the probability of further collision
decreases.
Vulnerable Time = 2* Frame transmission time
Throughput = G exp{-2*G}
Slotted Aloha:
It is similar to pure aloha, except that we divide time into slots and
sending of data is allowed only at the beginning of these slots. If a station
misses out the allowed time, it must wait for the next slot. This reduces
the probability of collision.
Throughput = G exp{-*G}
CSMA/CD
CSMA/CD – Carrier sense multiple access with collision detection.
Stations can terminate transmission of data if collision is detected.
Carrier sense multiple access with collision detection (CSMA/CD) –
The CSMA method does not tell us what to do in case there is a collision.
Carrier sense multiple access with collision detection (CSMA/CD) adds on
to the CSMA algorithm to deal with the collision. In CSMA/CD, the size of a
frame must be large enough so that collision can be detected by sender
while sending the frame. So, the frame transmission delay must be at
least two times the maximum propagation delay.
network Layer controls the operation of the subnet. The main aim of this
layer is to deliver packets from source to destination across multiple links
(networks). If two computers (system) are connected on the same link,
then there is no need for a network layer. It routes the signal through
different channels to the other end and acts as a network controller.
It also divides the outgoing messages into packets and to assemble
incoming packets into messages for higher levels.
In broadcast networks, the routing problem is simple, so the network layer
is often thin or even non-existent.
Dijkstra's Algorithm
Bellman-Ford Algorithm
Dijkstra's Algorithm
Dijkstra's algorithm is a centralized routing algorithm that maintains
information in a central location. The objective is to find the least-cost
path from a given source node to all other nodes. This algorithm
determines least-cost paths from a source node to a destination node by
optimizing the cost in multiple iterations. Dijkstra's algorithm is as
follows :
Begin Dijkstra's Algorithm
1. Define:
s =Source node
k ={ s }
² sj = ± sj for j s
3. Next node:
Add x to k .
4. Least-cost paths:
² sj = min( ² sj , ² sx + ± xj ) for j k
If any two nodes i and j are not connected directly, the cost for that link is
infinity, indicated by ² ij =x. Steps 2 and 3 are repeated until paths are
assigned to all nodes. At step 1, k represents s , and ² sj computes the cost
of the least-cost path from s to node j . At step 2, we want to find x among
the neighboring nodes but not in k such that the cost is minimized. At step
3, we simply update the least-cost path. The algorithm ends when all
nodes have been visited and included in the algorithm.
Let us understand with the following example:
The set sptSet is initially empty and distances assigned to vertices are {0,
INF, INF, INF, INF, INF, INF, INF} where INF indicates infinite. Now pick the
vertex with minimum distance value. The vertex 0 is picked, include it
in sptSet. So sptSet becomes {0}. After including 0 to sptSet, update
distance values of its adjacent vertices. Adjacent vertices of 0 are 1 and 7.
The distance values of 1 and 7 are updated as 4 and 8. Following
subgraph shows vertices and their distance values, only the vertices with
finite distance values are shown. The vertices included in SPT are shown
in green colour.
Pick the vertex with minimum distance value and not already included in
SPT (not in sptSET). The vertex 1 is picked and added to sptSet. So sptSet
now becomes {0, 1}. Update the distance values of adjacent vertices of 1.
The distance value of vertex 2 becomes 12.
Pick the vertex with minimum distance value and not already included in
SPT (not in sptSET). Vertex 7 is picked. So sptSet now becomes {0, 1, 7}.
Update the distance values of adjacent vertices of 7. The distance value of
vertex 6 and 8 becomes finite (15 and 9 respectively).
Pick the vertex with minimum distance value and not already included in
SPT (not in sptSET). Vertex 6 is picked. So sptSet now becomes {0, 1, 7,
6}. Update the distance values of adjacent vertices of 6. The distance
value of vertex 5 and 8 are updated.
We repeat the above steps until sptSet does include all vertices of given
graph. Finally, we get the following Shortest Path Tree (SPT).
Bellman-Ford Algorithm
The Bellman-Ford algorithm finds the least-cost path from a source to a
destination by passing through no more than links. The essence of the
algorithm consists of the following steps
1.
Define:
s = Source node
± ij = Cost of the link from node i to node j
² sj ( + 1) = min i [ ² si ( ) + ± ij ]
If any two nodes i and j are not connected directly, ² ij ( ) =x. At step 2,
every value of ² is initialized . At step 3, we increase the number of links
in a sequence of iterations. During each iteration, we find the least-cost
path, given the value of . The algorithm ends when all nodes have been
visited and included in the algorithm.
Example
Let us understand the algorithm with following example graph. The
images are taken from this source.
Let the given source vertex be 0. Initialize all distances as infinite, except
the distance to the source itself. Total number of vertices in the graph is
5, so all edges must be processed 4 times.
Let all edges are processed in the following order: (B, E), (D, B), (B, D), (A,
B), (A, C), (D, C), (B, C), (E, D). We get the following distances when all
edges are processed the first time. The first row shows initial distances.
The second row shows distances when edges (B, E), (D, B), (B, D) and (A,
B) are processed. The third row shows distances when (A, C) is processed.
The fourth row shows when (D, C), (B, C) and (E, D) are processed.
The first iteration guarantees to give all shortest paths which are at most
1 edge long. We get the following distances when all edges are processed
second time (The last row shows final values).
The second iteration guarantees to give all shortest paths which are at
most 2 edges long. The algorithm processes all edges 2 more times. The
distances are minimized after the second iteration, so third and fourth
iterations don’t update the distances.
What is IP?
Here, IP stands for internet protocol. It is a protocol defined in the
TCP/IP model used for sending the packets from source to destination. The
main task of IP is to deliver the packets from source to the destination
based on the IP addresses available in the packet headers. IP defines the
packet structure that hides the data which is to be delivered as well as the
addressing method that labels the datagram with a source and destination
information.
An IP protocol provides the connectionless service, which is accompanied
by two transport protocols, i.e., TCP/IP (Links to an external site.) and
UDP/IP, so internet protocol is also known as TCP/IP (Links to an external
site.) or UDP (Links to an external site.)/IP.
The first version of IP (Internet Protocol) was IPv4. After IPv4, IPv6 came
into the market, which has been increasingly used on the public internet
since 2006.
What is IP Addressing?
An IP address is a unique identifier assigned to the computer which is
connected to the internet. Each IP address consists of a series of
characters like 192.168.1.2. Users cannot access the domain name of
each website with the help of these characters, so DNS resolvers are used
that convert the human-readable domain names into a series of
characters. Each IP packet contains two addresses, i.e., the IP address of
the device, which is sending the packet, and the IP address of the device
which is receiving the packet.
Types of IP addresses
IPv4 addresses are divided into two categories:
Public address
Private address
Public address
The public address is also known as an external address as they are
grouped under the WAN addresses. We can also define the public address
as a way to communicate outside the network. This address is used to
access the internet. The public address available on our computer
provides the remote access to our computer. With the help of a public
address, we can set up the home server to access the internet. This
address is generally assigned by the ISP (Internet Service Provider).
Key points related to public address are:
Private address
A private address is also known as an internal address, as it is grouped
under the LAN addresses. It is used to communicate within the network.
These addresses are not routed on the internet so that no traffic can come
from the internet to this private address. The address space for the
private address is allocated using InterNIC to create our own network.
The private addresses are assigned to mainly those computers, printers,
smartphones, which are kept inside the home or the computers that are
kept within the organization. For example, a private address is assigned to
the printer, which is kept inside our home, so that our family member can
take out the print from the printer.
If the computer is assigned with a private address, then the devices
available within the local network can view the computer through the
private ip address. However, the devices available outside the local
network cannot view the computer through the private IP address, but
they can access the computer if they know the router's public address. To
access the computer directly, NAT (Network Address Translator) is to be
used.
Key points related to private address are:
Classful Addressing
An IP address is 32-bit long. An IP address is divided into sub-classes:
Class A
Class B
Class C
Class D
Class E
Class A
In Class A, an IP address is assigned to those networks that contain a
large number of hosts.
In Class A, the first bit in higher order bits of the first octet is always set to
0 and the remaining 7 bits determine the network ID. The 24 bits
determine the host ID in any network.
Class B
In Class B, an IP address is assigned to those networks that range from
small-sized to large-sized networks.
Class D
In Class D, an IP address is reserved for multicast addresses. It does not
possess subnetting. The higher order bits of the first octet is always set to
1110, and the remaining bits determines the host ID in any network.
Class E
In Class E, an IP address is used for the future use or for the research and
development purposes. It does not possess any subnetting. The higher
order bits of the first octet is always set to 1111, and the remaining bits
determines the host ID in any network.
Address
IPv4 is a 32-bit address. IPv6 is a 128-bit address.
length
IPv6 is an alphanumeric
IPv4 is a numeric address that
address that consists of 8
Fields consists of 4 fields which are
fields, which are separated
separated by dot (.).
by colon.
Encryption
and It does not provide encryption It provides encryption and
Authenticatio and authentication. authentication.
n
TCP
TCP stands for Transmission Control Protocol. It is a transport layer
protocol that facilitates the transmission of packets from source to
destination. It is a connection-oriented protocol that means it establishes
the connection prior to the communication that occurs between the
computing devices in a network. This protocol is used with an IP
o Reliable
This protocol ensures that the data reaches the intended receiver in the
same order in which it is sent. It orders and numbers each segment so
that the TCP layer on the destination side can reassemble them based on
their ordering.
o Connection-oriented
o Full duplex
o Stream-oriented
TCP is a stream-oriented protocol as it allows the sender to send the data
in the form of a stream of bytes and also allows the receiver to accept the
data in the form of a stream of bytes. TCP creates an environment in
which both the sender and receiver are connected by an imaginary tube
known as a virtual circuit. This virtual circuit carries the stream of bytes
across the internet.
Working of TCP
In TCP, the connection is established by using three-way handshaking. The
client sends the segment with its sequence number. The server, in return,
sends its segment with its own sequence number as well as the
acknowledgement sequence, which is one more than the client sequence
number. When the client receives the acknowledgment of its segment,
then it sends the acknowledgment to the server. In this way, the
connection is established between the client and the server.
Advantages of TCP
Disadvantage of TCP
It increases a large amount of overhead as each segment gets its own TCP
header, so fragmentation by the router increases the overhead.
o Window size
It is a 16-bit field. It contains the size of data that the receiver can
accept. This field is used for the flow control between the sender
and receiver and also determines the amount of buffer allocated by
the receiver for a segment. The value of this field is determined by
the receiver.
o Checksum
It is a 16-bit field. This field is optional in UDP, but in the case of
TCP/IP, this field is mandatory.
o Urgent pointer
It is a pointer that points to the urgent data byte if the URG flag is
set to 1. It defines a value that will be added to the sequence
number to get the sequence number of the last urgent byte.
o Options
It provides additional options. The optional field is represented in
32-bits. If this field contains the data less than 32-bit, then padding
is required to obtain the remaining bits.
Application Layer: WWW and
HTTP
WWW stands for World Wide Web. A technical definition of the World
Wide Web is : all the resources and users on the Internet that are using
the Hypertext Transfer Protocol (HTTP).
A broader definition comes from the organization that Web inventor Tim
Berners-Lee helped found, the World Wide Web Consortium (W3C).
The World Wide Web is the universe of network-accessible information, an
embodiment of human knowledge.
In simple terms, The World Wide Web is a way of exchanging information
between computers on the Internet, tying them together into a vast
collection of interactive multimedia resources.
Internet and Web is not the same thing: Web uses internet to pass over
the information.
Evolution
World Wide Web was created by Timothy Berners Lee in 1989
at CERN in Geneva. World Wide Web came into existence as a proposal
by him, to allow researchers to work together effectively and efficiently
at CERN. Eventually it became World Wide Web.
The following diagram briefly defines evolution of World Wide Web:
WWW Architecture
WWW architecture is divided into several layers as shown in the following
diagram:
Identifiers and Character Set
Uniform Resource Identifier (URI) is used to uniquely identify
resources on the web and UNICODE makes it possible to built web pages
that can be read and write in human languages.
Syntax
XML (Extensible Markup Language) helps to define common syntax in
semantic web.
Data Interchange
Resource Description Framework (RDF) framework helps in defining
core representation of data for web. RDF represents data about resource
in graph form.
Taxonomies
RDF Schema (RDFS) allows more standardized description
of taxonomies and other ontological constructs.
Ontologies
Web Ontology Language (OWL) offers more constructs over RDFS. It
comes in following three versions:
OWL Lite for taxonomies and simple constraints.
OWL DL for full description logic support.
OWL for more syntactic freedom of RDF
Rules
RIF and SWRL offers rules beyond the constructs that are available
from RDFs and OWL. Simple Protocol and RDF Query Language
(SPARQL) is SQL like language used for querying RDF data and OWL
Ontologies.
Proof
All semantic and rules that are executed at layers below Proof and their
result will be used to prove deductions.
Cryptography
Cryptography means such as digital signature for verification of the
origin of sources is used.
User Interface and Applications
On the top of layer User interface and Applications layer is built for
user interaction.
WWW Operation
WWW works on client- server approach. Following steps explains how the
web works:
1. User enters the URL (say, http://www.tutorialspoint.com) of
the web page in the address bar of web browser.
2. Then browser requests the Domain Name Server for the IP
address corresponding to www.tutorialspoint.com.
3. After receiving IP address, browser sends the request for web
page to the web server using HTTP protocol which specifies the
way the browser and web server communicates.
4. Then web server receives request using HTTP protocol and
checks its search for the requested web page. If found it returns
it back to the web browser and close the HTTP connection.
5. Now the web browser receives the web page, It interprets it and
display the contents of web page in web browser’s window.
Future
There had been a rapid development in field of web. It has its impact in
almost every area such as education, research, technology, commerce,
marketing etc. So the future of web is almost unpredictable.
Apart from huge development in field of WWW, there are also some
technical issues that W3 consortium has to cope up with.
User Interface
Work on higher quality presentation of 3-D information is under
deveopment. The W3 Consortium is also looking forward to enhance the
web to full fill requirements of global communities which would include all
regional languages and writing systems.
Technology
Work on privacy and security is under way. This would include hiding
information, accounting, access control, integrity and risk management.
Architecture
There has been huge growth in field of web which may lead to overload
the internet and degrade its performance. Hence more better protocol are
required to be developed.
The World Wide Web is about communication between web clients and
web servers.
Clients are often browsers (Chrome, Edge, Safari), but they can be any
type of program or device.
Servers are most often computers in the cloud.
Web Client
Cloud
Web Server
FTP
FTP
Objectives of FTP
Why FTP?
Although transferring files from one system to another is very simple and
straightforward, but sometimes it can cause problems. For example, two
systems may have different file conventions. Two systems may have
different ways to represent text and data. Two systems may have
different directory structures. FTP protocol overcomes these problems by
establishing two connections between hosts. One connection is used for
data transfer, and another connection is used for the control connection.
Mechanism of FTP
The above figure shows the basic model of the FTP. The FTP client has
three components: the user interface, control process, and data transfer
process. The server has two components: the server control process and
the server data transfer process.
There are two types of connections in FTP:
Control Connection: The control connection uses very simple
rules for communication. Through control connection, we can
transfer a line of command or line of response at a time. The
control connection is made between the control processes. The
control connection remains connected during the entire
interactive FTP session.
Data Connection: The Data Connection uses very complex
rules as data types may vary. The data connection is made
between data transfer processes. The data connection opens
when a command comes for transferring the files and closes
when the file is transferred.
FTP Clients
Advantages of FTP:
Disadvantages of FTP:
SSH
SSH stands for Secure Shell or Secure Socket Shell. It is a
cryptographic network protocol that allows two computers to
communicate and share the data over an insecure network such as the
internet. It is used to login to a remote server to execute commands and
data transfer from one machine to another machine.
The SSH protocol was developed by SSH communication security
Ltd to safely communicate with the remote machine.
Secure communication provides a strong password authentication and
encrypted communication with a public key over an insecure channel. It is
used to replace unprotected remote login protocols such as Telnet,
rlogin, rsh, etc., and insecure file transfer protocol FTP.
Its security features are widely used by network administrators for
managing systems and applications remotely.
The SSH protocol protects the network from various attacks such as DNS
spoofing, IP source routing, and IP spoofing.
A simple example can be understood, such as suppose you want to
transfer a package to one of your friends. Without SSH protocol, it can be
opened and read by anyone. But if you will send it using SSH protocol, it
will be encrypted and secured with the public keys, and only the receiver
can open it.
Before SSH:
After SSH:
The basic use of SSH is to connect a remote system for a terminal session
and to do this, following command is used:
1. ssh UserName@SSHserver.test.com
SMTP
SMTP stands for Simple Mail Transfer Protocol.
SMTP is a set of communication guidelines that allow software to
transmit an electronic mail over the internet is called Simple
Mail Transfer Protocol.
It is a program used for sending messages to other computer
users based on e-mail addresses.
It provides a mail exchange between users on the same or
different computers, and it also supports:
o It can send a single message to one or more recipients.
o Sending message can include text, voice, video or
graphics.
o It can also send the messages on networks outside the
internet.
The main purpose of SMTP is used to set up communication rules
between servers. The servers have a way of identifying
themselves and announcing what kind of communication they
are trying to perform. They also have a way of handling the
errors such as incorrect email address. For example, if the
recipient address is wrong, then receiving server reply with an
error message of some kind.
Components of SMTP
First, we will break the SMTP client and SMTP server into two
components such as user agent (UA) and mail transfer agent
(MTA). The user agent (UA) prepares the message, creates the
envelope and then puts the message in the envelope. The mail
transfer agent (MTA) transfers this mail across the internet.
Working of SMTP
1. Composition of Mail: A user sends an e-mail by composing an
electronic mail message using a Mail User Agent (MUA). Mail User
Agent is a program which is used to send and receive mail. The
message contains two parts: body and header. The body is the
main part of the message while the header includes information
such as the sender and recipient address. The header also
includes descriptive information such as the subject of the
message. In this case, the message body is like a letter and
header is like an envelope that contains the recipient's address.
2. Submission of Mail: After composing an email, the mail client
then submits the completed e-mail to the SMTP server by using
SMTP on TCP port 25.
3. Delivery of Mail: E-mail addresses contain two parts: username
of the recipient and domain name. For example,
vivek@gmail.com, where "vivek" is the username of the recipient
and "gmail.com" is the domain name.
If the domain name of the recipient's email address is different
from the sender's domain name, then MSA will send the mail to
the Mail Transfer Agent (MTA). To relay the email, the MTA will
find the target domain. It checks the MX record from Domain
Name System to obtain the target domain. The MX record
contains the domain name and IP address of the recipient's
domain. Once the record is located, MTA connects to the
exchange server to relay the message.
4. Receipt and Processing of Mail: Once the incoming message
is received, the exchange server delivers it to the incoming
server (Mail Delivery Agent) which stores the e-mail where it
waits for the user to retrieve it.
5. Access and Retrieval of Mail: The stored email in MDA can be
retrieved by using MUA (Mail User Agent). MUA can be accessed
by using login and password.
DNS
An application layer protocol defines how the application processes
running on different systems, pass the messages to each other.
Generic Domains
It defines the registered hosts according to their generic
behavior.
Each node in a tree defines the domain name, which is an index
to the DNS database.
It uses three-character labels, and these labels describe the
organization type.
Label Description
aero Airlines and aerospace companies
biz Businesses or firms
com Commercial Organizations
Cooperative business
coop
Organizations
edu Educational institutions
gov Government institutions
info Information service providers
int International Organizations
mil Military groups
museu Museum & other nonprofit
m organizations
name Personal names
net Network Support centers
org Nonprofit Organizations
Professional individual
pro
Organizations
Country Domain
The format of country domain is same as a generic domain, but it uses
two-character country abbreviations (e.g., us for the United States) in
place of three character organizational abbreviations.
Inverse Domain
The inverse domain is used for mapping an address to a name. When the
server has received a request from the client, and the server contains the
files of only authorized clients. To determine whether the client is on the
authorized list or not, it sends a query to the DNS server and ask for
mapping an address to the name.
Working of DNS
DNS is a client/server network communication protocol. DNS
clients send requests to the. server while DNS servers send
responses to the client.
Client requests contain a name which is converted into an IP
address known as a forward DNS lookups while requests
containing an IP address which is converted into a name known
as reverse DNS lookups.
DNS implements a distributed database to store the name of all
the hosts available on the internet.
If a client like a web browser sends a request containing a
hostname, then a piece of software such as DNS resolver sends
a request to the DNS server to obtain the IP address of a
hostname. If DNS server does not contain the IP address
associated with a hostname, then it forwards the request to
another DNS server. If IP address has arrived at the resolver,
which in turn completes the request over the internet protocol.
47.3M
1K
Features of Java - Javatpoint
Following are the types of multiple access protocol that is subdivided into
the different process as:
A. Random Access Protocol
In this protocol, all the station has the equal priority to send the data over
a channel. In random access protocol, one or more stations cannot
depend on another station nor any station control another station.
Depending on the channel's state (idle or busy), each station transmits
the data frame. However, if more than one station sends the data over a
channel, there may be a collision or data conflict. Due to the collision, the
data frame packets may be lost or changed. And hence, it does not
receive by the receiver end.
o Aloha
o CSMA
o CSMA/CD
o CSMA/CA
It is designed for wireless LAN (Local Area Network) but can also be used
in a shared medium to transmit data. Using this method, any station can
transmit data across a network simultaneously when a data frameset is
available for transmission.
Aloha Rules
Pure Aloha
Slotted Aloha
CSMA/ CD
CSMA/ CA
Following are the methods used in the CSMA/ CA to avoid the collision:
Interframe space: In this method, the station waits for the channel to
become idle, and if it gets the channel is idle, it does not immediately
send the data. Instead of this, it waits for some time, and this time period
is called the Interframe space or IFS. However, the IFS time is often used
to define the priority of the station.