123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244 |
- <!doctype html>
- <html lang="en">
- <head>
- <meta charset="utf-8">
- <title>Introduzione alle reti</title>
- <meta name="apple-mobile-web-app-capable" content="yes">
- <meta name="apple-mobile-web-app-status-bar-style" content="black-translucent">
- <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no">
- <link rel="stylesheet" href="../reveal-js/css/reset.css">
- <link rel="stylesheet" href="../reveal-js/css/reveal.css"><link rel="stylesheet" href="../reveal-js/css/theme/black.css" id="theme">
- <link rel="stylesheet" href="../highlight-js/solarized-dark.min.css"><link rel="stylesheet" href="../style.css" id="custom_css">
-
- </head>
- <body>
-
- <div class="reveal">
- <div class="slides">
-
- <section><h3 id="intro-sulle-reti">intro sulle reti</h3>
- </section><section>
- <h3 id="come-funziona-linternet">Come funziona l’internet?</h3>
- </section><section>
- <ul>
- <li>via radio</li>
- <li>con le antenne telefoniche</li>
- <li>con cavi sottomarini</li>
- <li>con connessioni satellitari</li>
- </ul>
- </section><section>
- <h5 id="heading"></h5>
- <p><img src="../images/cable_map.png" alt="/images/cable_map.png"></p>
- </section><section>
- <p><img src="../images/datacenter1.jpeg" alt="/images/datacenter1.jpeg"></p>
- </section><section>
- <p><img src="../images/datacenter2.jpeg" alt="/images/datacenter2.jpeg"></p>
- </section><section>
- <h3 id="un-po-di-sigle">Un po di sigle</h3>
- <p>Tanto per confonderci meglio, cerchiamo di capire cosa fanno questi diversi
- elementi</p>
- </section><section>
- <ul>
- <li>ISP</li>
- <li>Router</li>
- <li>WAN</li>
- <li>LAN</li>
- <li>Host(s)</li>
- <li>WLAN</li>
- </ul>
- </section><section>
- <h3 id="stack-isoosi">Stack ISO/OSI</h3>
- <p>Possiamo dividere la rete internet, per come viene vista da un pacchetto,
- si puo’ suddividere in sette “strati”.</p>
- </section><section>
- <img src='../images/iso.png' style='height: 600px;'/>
- </section><section>
- <h3 id="dallalto-verso-il-basso">Dall’alto verso il basso</h3>
- <p><strong>Application Layer</strong></p>
- <ul>
- <li>HTTP (Hypertext Transfer Protocol)</li>
- <li>SMTP (Simple Mail Transfer Protocol)</li>
- </ul>
- <p>ce ne sono un sacco, ma chi decide? <a href="https://datatracker.ietf.org/doc/html/rfc2616">RFC</a>, IETF</p>
- </section><section>
- <h3 id="transport-layer">Transport Layer</h3>
- <p>Come i dati vengono mandati, se controllando o meno gli errori durante la
- connessione.</p>
- <ul>
- <li>TCP (Transmission Control Protocol) - reliable data delivery</li>
- <li>UDP (User Datagram Protocol) - unreliable data delivery</li>
- </ul>
- </section><section>
- <h3 id="network-layer">Network Layer</h3>
- <p>Qui per permettere agli host, più propriamente al sistema operativo,</p>
- <p>Questo layer usa:</p>
- <ul>
- <li>IP (Internet Protocol) - Permette di instradare pacchetti da una host
- all’altro</li>
- <li>ICMP (Internet Control Message Protocol) - Errori, debug, che succede.</li>
- </ul>
- </section><section>
- <h3 id="link-layer">Link Layer</h3>
- <p>Come vengono mandati fisicamente i dati nella ferraglia</p>
- <ul>
- <li>quanti modi vi vengono in mente?</li>
- </ul>
- </section><section>
- <h3 id="paccheti-che-si-instradano">Paccheti che si instradano?</h3>
- <p>Abbiamo trovato un modo molto criptico di dire “dati che si muovono”, ma
- avviene cio'?</p>
- <ul>
- <li>MAC: 8 byte OUI (Organizational unique identifier) 8 univoci per scheda
- fisica</li>
- <li>IP</li>
- <li>Hostname</li>
- </ul>
- </section><section>
- <h3 id="quindi-se-visito-un-sito-che-giro-faccio">Quindi, se visito un sito, che giro faccio?</h3>
- </section><section>
- <h3 id="layer-applicativo">Layer Applicativo</h3>
- <pre><code>* Protocollo HTTP
- * Metodi: GET, POST, vari ed eventuali
- > GET / HTTP/1.1
- > Host: google.com
- </code></pre>
- </section><section>
- <h3 id="layer-di-trasporto">Layer di trasporto</h3>
- <pre><code>- Porte
- - UDP
- - TCP
- </code></pre>
- </section><section>
- <h3 id="layer-di-rete">Layer di Rete</h3>
- <pre><code>- IP: destinazione e sorgente
- </code></pre>
- </section><section>
- <h3 id="layer-fisico">Layer Fisico</h3>
- <pre><code>- Incapsula il pacchetto TCP/IP dentro un frame
- - ARP (Address Resolution Protocol)
- </code></pre>
- </section><section>
- <h3 id="quindi-se-vado-su-un-sito-che-giro-faccio">Quindi se vado su un sito che giro faccio?</h3>
- <p><img src="../images/stackiso.png" alt="Esempio stack ISO/OSI"></p>
- </section><section>
- <h3 id="route-netmask-e-altre-cose-orribili">ROUTE, NETMASK, E ALTRE COSE ORRIBILI</h3>
- <ul>
- <li>Ovvero, di cosa ha bisogno il mio computer per attaccarsi al router?</li>
- <li>IP, lo abbiamo visto</li>
- <li>GATEWAY, “da dove passare”, quindi l’IP del gateway</li>
- <li>NETMASK, il mio PC sa di essere in una sottorete, ma quanto e'
- grande?</li>
- </ul>
- <p>Con questi ingredienti posso collegarmi al router!</p>
- </section><section>
- <h3 id="dhcp">DHCP</h3>
- <p>E’ interessante cercare di capire come fa il router a farci collegare
- in automatico.</p>
- <ul>
- <li>DHCP</li>
- <li>DHCP DISCOVER</li>
- <li>DHCP OFFER</li>
- <li>DHCP REQUEST</li>
- <li>DHCP ACK</li>
- <li>Riusciamo a vederlo con wireshark?</li>
- </ul>
- </section><section>
- <h3 id="http">HTTP</h3>
- <p>Proviamo! Posso usare internet da terminale?</p>
- <p><code>curl https://www.wttr.in/turin </code></p>
- </section><section>
- <h3 id="developer-tools">Developer Tools</h3>
- <p>Ovvero, avevate mai provato a premere <strong>F12</strong> sul browser?</p>
- </section><section>
- <h3 id="get">GET</h3>
- <ul>
- <li>parametri</li>
- <li>escaping</li>
- <li>content-type</li>
- </ul>
- <p>eg. autocompletamento di startpage.com</p>
- </section><section>
- <h3 id="post">POST</h3>
- <ul>
- <li>parametri</li>
- <li>dati</li>
- </ul>
- </section><section>
- <h3 id="live---ws">Live - WS</h3>
- <p>pad.</p>
- </section>
-
- </div>
-
- </div>
- <script type="text/javascript" src=../reveal-hugo/object-assign.js></script>
- <a href="../reveal-js/css/print/" id="print-location" style="display: none;"></a>
- <script type="text/javascript">
- var printLocationElement = document.getElementById('print-location');
- var link = document.createElement('link');
- link.rel = 'stylesheet';
- link.type = 'text/css';
- link.href = printLocationElement.href + (window.location.search.match(/print-pdf/gi) ? 'pdf.css' : 'paper.css');
- document.getElementsByTagName('head')[0].appendChild(link);
- </script>
- <script type="application/json" id="reveal-hugo-site-params">{"custom_css":"style.css","highlight_theme":"solarized-dark"}</script>
- <script type="application/json" id="reveal-hugo-page-params">null</script>
- <script src="../reveal-js/js/reveal.js"></script>
- <script type="text/javascript">
-
-
- function camelize(map) {
- if (map) {
- Object.keys(map).forEach(function(k) {
- newK = k.replace(/(\_\w)/g, function(m) { return m[1].toUpperCase() });
- if (newK != k) {
- map[newK] = map[k];
- delete map[k];
- }
- });
- }
- return map;
- }
-
- var revealHugoDefaults = { center: true, controls: true, history: true, progress: true, transition: "slide" };
- var revealHugoSiteParams = JSON.parse(document.getElementById('reveal-hugo-site-params').innerHTML);
- var revealHugoPageParams = JSON.parse(document.getElementById('reveal-hugo-page-params').innerHTML);
-
- var options = Object.assign({},
- camelize(revealHugoDefaults),
- camelize(revealHugoSiteParams),
- camelize(revealHugoPageParams));
- Reveal.initialize(options);
- </script>
-
-
- <script type="text/javascript" src="../reveal-js/plugin/markdown/marked.js"></script>
-
- <script type="text/javascript" src="../reveal-js/plugin/markdown/markdown.js"></script>
-
- <script type="text/javascript" src="../reveal-js/plugin/highlight/highlight.js"></script>
-
- <script type="text/javascript" src="../reveal-js/plugin/zoom-js/zoom.js"></script>
-
-
- <script type="text/javascript" src="../reveal-js/plugin/notes/notes.js"></script>
-
-
- </body>
- </html>
|