Please note, this is a STATIC archive of website developer.mozilla.org from 03 Nov 2016, cach3.com does not collect or store any user information, there is no "phishing" involved.

Revision 691189 of How networks talk with each other

  • Revision slug: Learn/How_networks_talk_with_each_other
  • Revision title: How networks talk with each other
  • Revision id: 691189
  • Created:
  • Creator: Andrew_Pfeiffer
  • Is current revision? No
  • Comment add tags

Revision Content

In this article, we discuss what happens when information traverses the Internet.

Prerequisites: You need to know what a network is.
Objective: Learn how computer networks send data across the Internet.
 

To pass through a network, data must go through many processes to make sure it arrives accurately. The seven layer schema of the OSI model (Open Systems Interconnection) provides a helpful way to conceptualize the journey of data across the network:

  1. The user sees only the first layer, the application layer. This layer converts a message's data into bits and attaches a header identifying the sending and receiving computers.
  2. The presentation layer translates the data into an encoding that the receiving computer can read (often ASCII, a way of encoding text as bits). This layer also compresses and encrypts the data, and adds another header to specify which conventions have been used for encoding, compression, and encryption.
  3. The session layer opens communications. It sets boundaries (called brackets) for the beginning and end of the message and establishes whether the message will be sent half-duplex (the computers take turns sending and receiving) or full-duplex (both computers send and receive at the same time). The details of these decisions are placed in a session header.
  4. The transport layer protects the data being sent. It breaks the data into segments and creates checksum tests (mathematic sums based on the data's contents) that can be used later to check for corruptions in the sent data. The transport layer also makes backup copies of the data, and attaches a header identifying each segment's checksum and position in the message.
  5. The network layer selects a route for the message. It combines segments into packets, counts them, and adds a header containing the sequence of packets and the receiving computer's address.
  6. The data-link layer supervises the transmission. It confirms the checksum, and then addresses and duplicates the packets. This layer keeps a copy of each packet until it receives confirmation that the packet has arrived safely at the next checkpoint.
  7. The physical layer encodes the packets into the medium that will carry them (e.g., analog signal if the message is going across a phone line) and sends the packets along that medium.

At the receiving end, the seven-layered process that sent the message is reversed:

  1. The physical layer reconverts the message into bits.
  2. The data-link layer recalculates the checksum, confirms arrival, and logs in the packets.
  3. The network layer re-counts incoming packets for security.
  4. The transport layer recalculates the checksum and reassembles the message segments.
  5. The session layer assembles the incoming parts of the message and forwards it to the next layer.
  6. The presentation layer decrypts, expands, and translates the message.
  7. The application layer identifies the recipient, converts the bits into readable characters, and directs the data to the proper application. 

         

Revision Source

<p>In this article, we discuss <em>what happens when information traverses the Internet.</em></p>
<table class="standard-table learn-box">
 <tbody>
  <tr>
   <th scope="row">Prerequisites:</th>
   <td>You need to know what a network is.</td>
  </tr>
  <tr>
   <th scope="row">Objective:</th>
   <td>Learn how computer networks send data across the Internet.<br />
    &nbsp;</td>
  </tr>
 </tbody>
</table>
<p><img alt="" src="https://mdn.mozillademos.org/files/8647/7layers.jpg" style="width: 400px; height: 313px;" /></p>
<p>To pass through a network, data must go through many processes to make sure it arrives accurately. The <em><strong>seven layer schema </strong></em>of the OSI model (Open Systems Interconnection) provides a helpful way to conceptualize the journey of data across the network:</p>
<ol>
 <li>The user sees only the first layer, the <strong><em>application layer</em>. </strong>This layer converts a message's data into bits and attaches a header identifying the sending and receiving computers.</li>
 <li>The <em><strong>presentation layer</strong> translates</em> the data into an encoding that the receiving computer can read (often ASCII, a way of encoding text as bits). This layer also <em>compresses </em>and <em>encrypts</em> the data, and adds another header to specify which conventions have been used for encoding, compression, and encryption.</li>
 <li>The <strong><em>session layer</em></strong> <em>opens communications</em>. It sets boundaries (called brackets) for the beginning and end of the message and establishes whether the message will be sent half-duplex (the computers take turns sending and receiving) or full-duplex (both computers send and receive at the same time). The details of these decisions are placed in a session header.</li>
 <li>The&nbsp;<em><strong>transport layer&nbsp;</strong>protects the data being sent</em>. It breaks the data into segments and creates checksum tests (mathematic sums based on the data's contents) that can be used later to check for corruptions in the sent data. The transport layer also makes backup copies of the data, and attaches a header identifying each segment's checksum and position in the message.</li>
 <li>The <strong><em>network layer</em></strong> <em>selects a route</em> for the message. It combines segments into packets, counts them, and adds a header containing the sequence of packets and the receiving computer's address.</li>
 <li>The <em><strong>data-link layer</strong></em> <em>supervises the transmission</em>. It confirms the checksum, and then addresses and duplicates the packets. This layer keeps a copy of each packet until it receives confirmation that the packet has arrived safely at the next checkpoint.</li>
 <li>The <strong><em>physical layer</em></strong> <em>encodes</em> the packets into the medium that will carry them (e.g., analog signal if the message is going across a phone line) and sends the packets along that medium.</li>
</ol>
<p>At the receiving end, the seven-layered process that sent the message is reversed:</p>
<ol>
 <li>The <strong><em>physical layer</em></strong> <em>reconverts the message</em> into bits.</li>
 <li>The <strong><em>data-link layer</em></strong> <em>recalculates </em>the checksum, confirms arrival, and logs in the packets.</li>
 <li>The <em><strong>network layer</strong> re-counts</em> incoming packets for security.</li>
 <li>The <em><strong>transport layer</strong> recalculates</em> the checksum and reassembles the message segments.</li>
 <li>The <strong><em>session layer</em></strong> <em>assembles the incoming parts</em> of the message and forwards it to the next layer.</li>
 <li>The <strong><em>presentation layer</em></strong> <em>decrypts, expands, and translates</em> the message.</li>
 <li>The <strong><em>application layer</em></strong> identifies the recipient, converts the bits into readable characters, and directs the data to the proper application.&nbsp;</li>
</ol>
<p>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;</p>
Revert to this revision