SlideShare a Scribd company logo
How our computers
connect to Facebook(or any other website)
Yi Kuo
Internet?
How we access Facebook?
What happened in the second?
Websites?
Language: HTTP HyperText Transfer Protocol
Language: HTTP HyperText Transfer Protocol
GET / HTTP/1.1
Host: www.facebook.com
User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:76.0) Gecko/20100101 Firefox/7
Accept: text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,*/*;q=0.8
Accept-Language: zh-TW,zh;q=0.8,en-US;q=0.5,en;q=0.3
Accept-Encoding: gzip, deflate, br
Connection: keep-alive
Cookie: fr=1KvAgepb7obISMaDy..Bfrpvm.Ej.AAA.0.0.Bfrpvu.AWVbDWhysOw;
sb=5puuX_hOTwOlynW1kzQxecHh; datr=5puuX83dw4nqdIGZy_rBc_8P; wd=1280x198; dpr=1.5
Upgrade-Insecure-Requests: 1
GET / HTTP/1.1
Host: www.facebook.com
User-Agent: Mozilla/5.0 (W
Accept: text/html,applicat
Accept-Language: zh-TW,zh;
Accept-Encoding: gzip, def
GET / HTTP/1.1
Host: www.facebook.com
User-Agent: Mozilla/5.0 (W
Accept: text/html,applicat
Accept-Language: zh-TW,zh;
Accept-Encoding: gzip, def
Request Method
Location
https://www.facebook.com/
HTTP Version
Headers
POST
GET /kuokuoyiyi HTTP/1.1
Host: www.facebook.com
User-Agent: Mozilla/5.0 (W
Accept: text/html,applicat
Accept-Language: zh-TW,zh;
Accept-Encoding: gzip, def
Request Method
Location
https://www.facebook.com/kuokuoyiyi HTTP Version
Headers
Language: HTTP HyperText Transfer Protocol
HTTP/2 200 OK
X-Frame-Options: DENY
X-Xss-Protection: 0
⋮
X-Firefox-Spdy: h2
<!DOCTYPE html>
<html lang="zh-Hant" id="facebook" class="no_js">
<head><meta charset="utf-8" /><meta name="referrer" content="origin-when-
crossorigin" id="meta_referrer" /><script nonce="oX7Z8G3a">window._cstart=+new
Date();</script><script nonce="oX7Z8G3a">function envFlush(a){function
b(b){for(var c in a
HTTP/2 200 OK
X-Frame-Options: DENY
X-Xss-Protection: 0
⋮
X-Firefox-Spdy: h2
<!DOCTYPE html>
HTTP/2 200 OK
X-Frame-Options: DENY
X-Xss-Protection: 0
⋮
X-Firefox-Spdy: h2
<!DOCTYPE html>
Status Code
Response Data
HTTP/2 404 Not Found
X-Frame-Options: DENY
X-Xss-Protection: 0
⋮
X-Firefox-Spdy: h2
<!DOCTYPE html>
Status Code
Response Data
HTTP/2 403 Forbidden
X-Frame-Options: DENY
X-Xss-Protection: 0
⋮
X-Firefox-Spdy: h2
<!DOCTYPE html>
Status Code
Response Data
Connection: TCP Transmission Control Protocol
A
A + B
B
But where is www.facebook.com?
?
IP Address Internet Protocol Address
140.114.197.101
31.13.87.36
2a03:2880:f12d:83:face:b00c:0:25de
(IPv6)
DNS Domain Name System
www.facebook.com 31.13.87.36
www.google.com 216.58.200.36
yikuo.dev 172.67.169.118
Routing – Sending out to the internet
140.114.197.101
My Computer
@ Dorm Hsin
140.114.197.254
Dorm Hsin
Floor 3 / 4 Gateway
140.114.1.85
NTHU Networking
Center
140.114.1.70
NTHU TANet
Gateway
192.192.61.110
TANet
Taiwan Academic Network
To
31.13.87.36
Routing – BGP
140.114.197.101
My Computer
@ Dorm Hsin
140.114.197.254
Dorm Hsin
Floor 3 / 4 Gateway
140.114.1.85
NTHU Networking Center
140.114.1.70
NTHU TANet Gateway
192.192.61.110
TANet
Taiwan Academic Network
TANet
ISP A
Border Gateway Portocal
ISP B
ISP C
The
Facebook
Network
31.13.*.*
Who can get to
31.13.87.36?
I can in
1 step
I can in
2 steps
Who can get to
31.13.87.36?
I can in
1 step
To
31.13.87.36
Reply from
31.13.87.36
Routing – Sending back to sender
140.114.197.101
My Computer
@ Dorm Hsin
140.114.197.254
Dorm Hsin
Floor 3 / 4 Gateway
140.114.1.85
NTHU Networking
Center
140.114.1.70
NTHU TANet
Gateway
192.192.61.110
TANet
Taiwan Academic Network
Reply from
31.13.87.36
Internet Protocol Suite of HTTP
Physical Connection
Routing
TCP
HTTP
Q&A
Thanks for your listening!

More Related Content

Similar to How our computers connect to facebook

Cgi
CgiCgi
How Web Pages Work
How Web Pages Work How Web Pages Work
How Web Pages Work
OneDesignCompany
 
2. [Daily hack] Citrix_waf_bypass
2. [Daily hack] Citrix_waf_bypass2. [Daily hack] Citrix_waf_bypass
2. [Daily hack] Citrix_waf_bypass
defconmoscow
 
Http
HttpHttp
Http
NEATS
 
Web Application Security 101 - 02 The Basics
Web Application Security 101 - 02 The BasicsWeb Application Security 101 - 02 The Basics
Web Application Security 101 - 02 The Basics
Websecurify
 
20190516 web security-basic
20190516 web security-basic20190516 web security-basic
20190516 web security-basic
MksYi
 
OWASP Top 10 - Checkmarx Presentation at Polytechnic Institute of Cávado and Ave
OWASP Top 10 - Checkmarx Presentation at Polytechnic Institute of Cávado and AveOWASP Top 10 - Checkmarx Presentation at Polytechnic Institute of Cávado and Ave
OWASP Top 10 - Checkmarx Presentation at Polytechnic Institute of Cávado and Ave
Checkmarx
 
Rapport mymusicplease.fr
Rapport mymusicplease.frRapport mymusicplease.fr
Rapport mymusicplease.fr
Gaetan Garnier
 
Oss web application and network security
Oss   web application and network securityOss   web application and network security
Oss web application and network security
Rishabh Mehan
 
WebSockets Everywhere: the Future Transport Protocol for Everything (Almost)
WebSockets Everywhere: the Future Transport Protocol for Everything (Almost)WebSockets Everywhere: the Future Transport Protocol for Everything (Almost)
WebSockets Everywhere: the Future Transport Protocol for Everything (Almost)
Ericom Software
 
Computer network (10)
Computer network (10)Computer network (10)
Computer network (10)
NYversity
 
Http header的方方面面
Http header的方方面面Http header的方方面面
Http header的方方面面
Tony Deng
 
Test
TestTest
Php Inside - confoo 2011 - Derick Rethans
Php Inside -  confoo 2011 - Derick RethansPhp Inside -  confoo 2011 - Derick Rethans
Php Inside - confoo 2011 - Derick Rethans
Bachkoutou Toutou
 
HackFest 2015 - Rasp vs waf
HackFest 2015 - Rasp vs wafHackFest 2015 - Rasp vs waf
HackFest 2015 - Rasp vs waf
IMMUNIO
 
HTTP cookie hijacking in the wild: security and privacy implications
HTTP cookie hijacking in the wild: security and privacy implicationsHTTP cookie hijacking in the wild: security and privacy implications
HTTP cookie hijacking in the wild: security and privacy implications
Priyanka Aash
 
Web Terminology
Web TerminologyWeb Terminology
Web Terminology
ibrahimhossen6
 
Type URL, Enter, and Then …
Type URL, Enter, and Then …Type URL, Enter, and Then …
Type URL, Enter, and Then …
Jinglun Li
 
APIs Demystified
APIs DemystifiedAPIs Demystified
APIs Demystified
Brandon West
 
Taking a Quantum Leap with Html 5 WebSocket
Taking a Quantum Leap with Html 5 WebSocketTaking a Quantum Leap with Html 5 WebSocket
Taking a Quantum Leap with Html 5 WebSocket
Shahriar Hyder
 

Similar to How our computers connect to facebook (20)

Cgi
CgiCgi
Cgi
 
How Web Pages Work
How Web Pages Work How Web Pages Work
How Web Pages Work
 
2. [Daily hack] Citrix_waf_bypass
2. [Daily hack] Citrix_waf_bypass2. [Daily hack] Citrix_waf_bypass
2. [Daily hack] Citrix_waf_bypass
 
Http
HttpHttp
Http
 
Web Application Security 101 - 02 The Basics
Web Application Security 101 - 02 The BasicsWeb Application Security 101 - 02 The Basics
Web Application Security 101 - 02 The Basics
 
20190516 web security-basic
20190516 web security-basic20190516 web security-basic
20190516 web security-basic
 
OWASP Top 10 - Checkmarx Presentation at Polytechnic Institute of Cávado and Ave
OWASP Top 10 - Checkmarx Presentation at Polytechnic Institute of Cávado and AveOWASP Top 10 - Checkmarx Presentation at Polytechnic Institute of Cávado and Ave
OWASP Top 10 - Checkmarx Presentation at Polytechnic Institute of Cávado and Ave
 
Rapport mymusicplease.fr
Rapport mymusicplease.frRapport mymusicplease.fr
Rapport mymusicplease.fr
 
Oss web application and network security
Oss   web application and network securityOss   web application and network security
Oss web application and network security
 
WebSockets Everywhere: the Future Transport Protocol for Everything (Almost)
WebSockets Everywhere: the Future Transport Protocol for Everything (Almost)WebSockets Everywhere: the Future Transport Protocol for Everything (Almost)
WebSockets Everywhere: the Future Transport Protocol for Everything (Almost)
 
Computer network (10)
Computer network (10)Computer network (10)
Computer network (10)
 
Http header的方方面面
Http header的方方面面Http header的方方面面
Http header的方方面面
 
Test
TestTest
Test
 
Php Inside - confoo 2011 - Derick Rethans
Php Inside -  confoo 2011 - Derick RethansPhp Inside -  confoo 2011 - Derick Rethans
Php Inside - confoo 2011 - Derick Rethans
 
HackFest 2015 - Rasp vs waf
HackFest 2015 - Rasp vs wafHackFest 2015 - Rasp vs waf
HackFest 2015 - Rasp vs waf
 
HTTP cookie hijacking in the wild: security and privacy implications
HTTP cookie hijacking in the wild: security and privacy implicationsHTTP cookie hijacking in the wild: security and privacy implications
HTTP cookie hijacking in the wild: security and privacy implications
 
Web Terminology
Web TerminologyWeb Terminology
Web Terminology
 
Type URL, Enter, and Then …
Type URL, Enter, and Then …Type URL, Enter, and Then …
Type URL, Enter, and Then …
 
APIs Demystified
APIs DemystifiedAPIs Demystified
APIs Demystified
 
Taking a Quantum Leap with Html 5 WebSocket
Taking a Quantum Leap with Html 5 WebSocketTaking a Quantum Leap with Html 5 WebSocket
Taking a Quantum Leap with Html 5 WebSocket
 

Recently uploaded

Neo4j - Product Vision and Knowledge Graphs - GraphSummit Paris
Neo4j - Product Vision and Knowledge Graphs - GraphSummit ParisNeo4j - Product Vision and Knowledge Graphs - GraphSummit Paris
Neo4j - Product Vision and Knowledge Graphs - GraphSummit Paris
Neo4j
 
Using Xen Hypervisor for Functional Safety
Using Xen Hypervisor for Functional SafetyUsing Xen Hypervisor for Functional Safety
Using Xen Hypervisor for Functional Safety
Ayan Halder
 
Utilocate provides Smarter, Better, Faster, Safer Locate Ticket Management
Utilocate provides Smarter, Better, Faster, Safer Locate Ticket ManagementUtilocate provides Smarter, Better, Faster, Safer Locate Ticket Management
Utilocate provides Smarter, Better, Faster, Safer Locate Ticket Management
Utilocate
 
Webinar On-Demand: Using Flutter for Embedded
Webinar On-Demand: Using Flutter for EmbeddedWebinar On-Demand: Using Flutter for Embedded
Webinar On-Demand: Using Flutter for Embedded
ICS
 
Essentials of Automations: The Art of Triggers and Actions in FME
Essentials of Automations: The Art of Triggers and Actions in FMEEssentials of Automations: The Art of Triggers and Actions in FME
Essentials of Automations: The Art of Triggers and Actions in FME
Safe Software
 
UI5con 2024 - Boost Your Development Experience with UI5 Tooling Extensions
UI5con 2024 - Boost Your Development Experience with UI5 Tooling ExtensionsUI5con 2024 - Boost Your Development Experience with UI5 Tooling Extensions
UI5con 2024 - Boost Your Development Experience with UI5 Tooling Extensions
Peter Muessig
 
openEuler Case Study - The Journey to Supply Chain Security
openEuler Case Study - The Journey to Supply Chain SecurityopenEuler Case Study - The Journey to Supply Chain Security
openEuler Case Study - The Journey to Supply Chain Security
Shane Coughlan
 
Graspan: A Big Data System for Big Code Analysis
Graspan: A Big Data System for Big Code AnalysisGraspan: A Big Data System for Big Code Analysis
Graspan: A Big Data System for Big Code Analysis
Aftab Hussain
 
Neo4j - Product Vision and Knowledge Graphs - GraphSummit Paris
Neo4j - Product Vision and Knowledge Graphs - GraphSummit ParisNeo4j - Product Vision and Knowledge Graphs - GraphSummit Paris
Neo4j - Product Vision and Knowledge Graphs - GraphSummit Paris
Neo4j
 
LORRAINE ANDREI_LEQUIGAN_HOW TO USE ZOOM
LORRAINE ANDREI_LEQUIGAN_HOW TO USE ZOOMLORRAINE ANDREI_LEQUIGAN_HOW TO USE ZOOM
LORRAINE ANDREI_LEQUIGAN_HOW TO USE ZOOM
lorraineandreiamcidl
 
原版定制美国纽约州立大学奥尔巴尼分校毕业证学位证书原版一模一样
原版定制美国纽约州立大学奥尔巴尼分校毕业证学位证书原版一模一样原版定制美国纽约州立大学奥尔巴尼分校毕业证学位证书原版一模一样
原版定制美国纽约州立大学奥尔巴尼分校毕业证学位证书原版一模一样
mz5nrf0n
 
Atelier - Innover avec l’IA Générative et les graphes de connaissances
Atelier - Innover avec l’IA Générative et les graphes de connaissancesAtelier - Innover avec l’IA Générative et les graphes de connaissances
Atelier - Innover avec l’IA Générative et les graphes de connaissances
Neo4j
 
GraphSummit Paris - The art of the possible with Graph Technology
GraphSummit Paris - The art of the possible with Graph TechnologyGraphSummit Paris - The art of the possible with Graph Technology
GraphSummit Paris - The art of the possible with Graph Technology
Neo4j
 
Fundamentals of Programming and Language Processors
Fundamentals of Programming and Language ProcessorsFundamentals of Programming and Language Processors
Fundamentals of Programming and Language Processors
Rakesh Kumar R
 
Vitthal Shirke Java Microservices Resume.pdf
Vitthal Shirke Java Microservices Resume.pdfVitthal Shirke Java Microservices Resume.pdf
Vitthal Shirke Java Microservices Resume.pdf
Vitthal Shirke
 
E-commerce Development Services- Hornet Dynamics
E-commerce Development Services- Hornet DynamicsE-commerce Development Services- Hornet Dynamics
E-commerce Development Services- Hornet Dynamics
Hornet Dynamics
 
SWEBOK and Education at FUSE Okinawa 2024
SWEBOK and Education at FUSE Okinawa 2024SWEBOK and Education at FUSE Okinawa 2024
SWEBOK and Education at FUSE Okinawa 2024
Hironori Washizaki
 
socradar-q1-2024-aviation-industry-report.pdf
socradar-q1-2024-aviation-industry-report.pdfsocradar-q1-2024-aviation-industry-report.pdf
socradar-q1-2024-aviation-industry-report.pdf
SOCRadar
 
ALGIT - Assembly Line for Green IT - Numbers, Data, Facts
ALGIT - Assembly Line for Green IT - Numbers, Data, FactsALGIT - Assembly Line for Green IT - Numbers, Data, Facts
ALGIT - Assembly Line for Green IT - Numbers, Data, Facts
Green Software Development
 
Orion Context Broker introduction 20240604
Orion Context Broker introduction 20240604Orion Context Broker introduction 20240604
Orion Context Broker introduction 20240604
Fermin Galan
 

Recently uploaded (20)

Neo4j - Product Vision and Knowledge Graphs - GraphSummit Paris
Neo4j - Product Vision and Knowledge Graphs - GraphSummit ParisNeo4j - Product Vision and Knowledge Graphs - GraphSummit Paris
Neo4j - Product Vision and Knowledge Graphs - GraphSummit Paris
 
Using Xen Hypervisor for Functional Safety
Using Xen Hypervisor for Functional SafetyUsing Xen Hypervisor for Functional Safety
Using Xen Hypervisor for Functional Safety
 
Utilocate provides Smarter, Better, Faster, Safer Locate Ticket Management
Utilocate provides Smarter, Better, Faster, Safer Locate Ticket ManagementUtilocate provides Smarter, Better, Faster, Safer Locate Ticket Management
Utilocate provides Smarter, Better, Faster, Safer Locate Ticket Management
 
Webinar On-Demand: Using Flutter for Embedded
Webinar On-Demand: Using Flutter for EmbeddedWebinar On-Demand: Using Flutter for Embedded
Webinar On-Demand: Using Flutter for Embedded
 
Essentials of Automations: The Art of Triggers and Actions in FME
Essentials of Automations: The Art of Triggers and Actions in FMEEssentials of Automations: The Art of Triggers and Actions in FME
Essentials of Automations: The Art of Triggers and Actions in FME
 
UI5con 2024 - Boost Your Development Experience with UI5 Tooling Extensions
UI5con 2024 - Boost Your Development Experience with UI5 Tooling ExtensionsUI5con 2024 - Boost Your Development Experience with UI5 Tooling Extensions
UI5con 2024 - Boost Your Development Experience with UI5 Tooling Extensions
 
openEuler Case Study - The Journey to Supply Chain Security
openEuler Case Study - The Journey to Supply Chain SecurityopenEuler Case Study - The Journey to Supply Chain Security
openEuler Case Study - The Journey to Supply Chain Security
 
Graspan: A Big Data System for Big Code Analysis
Graspan: A Big Data System for Big Code AnalysisGraspan: A Big Data System for Big Code Analysis
Graspan: A Big Data System for Big Code Analysis
 
Neo4j - Product Vision and Knowledge Graphs - GraphSummit Paris
Neo4j - Product Vision and Knowledge Graphs - GraphSummit ParisNeo4j - Product Vision and Knowledge Graphs - GraphSummit Paris
Neo4j - Product Vision and Knowledge Graphs - GraphSummit Paris
 
LORRAINE ANDREI_LEQUIGAN_HOW TO USE ZOOM
LORRAINE ANDREI_LEQUIGAN_HOW TO USE ZOOMLORRAINE ANDREI_LEQUIGAN_HOW TO USE ZOOM
LORRAINE ANDREI_LEQUIGAN_HOW TO USE ZOOM
 
原版定制美国纽约州立大学奥尔巴尼分校毕业证学位证书原版一模一样
原版定制美国纽约州立大学奥尔巴尼分校毕业证学位证书原版一模一样原版定制美国纽约州立大学奥尔巴尼分校毕业证学位证书原版一模一样
原版定制美国纽约州立大学奥尔巴尼分校毕业证学位证书原版一模一样
 
Atelier - Innover avec l’IA Générative et les graphes de connaissances
Atelier - Innover avec l’IA Générative et les graphes de connaissancesAtelier - Innover avec l’IA Générative et les graphes de connaissances
Atelier - Innover avec l’IA Générative et les graphes de connaissances
 
GraphSummit Paris - The art of the possible with Graph Technology
GraphSummit Paris - The art of the possible with Graph TechnologyGraphSummit Paris - The art of the possible with Graph Technology
GraphSummit Paris - The art of the possible with Graph Technology
 
Fundamentals of Programming and Language Processors
Fundamentals of Programming and Language ProcessorsFundamentals of Programming and Language Processors
Fundamentals of Programming and Language Processors
 
Vitthal Shirke Java Microservices Resume.pdf
Vitthal Shirke Java Microservices Resume.pdfVitthal Shirke Java Microservices Resume.pdf
Vitthal Shirke Java Microservices Resume.pdf
 
E-commerce Development Services- Hornet Dynamics
E-commerce Development Services- Hornet DynamicsE-commerce Development Services- Hornet Dynamics
E-commerce Development Services- Hornet Dynamics
 
SWEBOK and Education at FUSE Okinawa 2024
SWEBOK and Education at FUSE Okinawa 2024SWEBOK and Education at FUSE Okinawa 2024
SWEBOK and Education at FUSE Okinawa 2024
 
socradar-q1-2024-aviation-industry-report.pdf
socradar-q1-2024-aviation-industry-report.pdfsocradar-q1-2024-aviation-industry-report.pdf
socradar-q1-2024-aviation-industry-report.pdf
 
ALGIT - Assembly Line for Green IT - Numbers, Data, Facts
ALGIT - Assembly Line for Green IT - Numbers, Data, FactsALGIT - Assembly Line for Green IT - Numbers, Data, Facts
ALGIT - Assembly Line for Green IT - Numbers, Data, Facts
 
Orion Context Broker introduction 20240604
Orion Context Broker introduction 20240604Orion Context Broker introduction 20240604
Orion Context Broker introduction 20240604
 

How our computers connect to facebook

  • 1. How our computers connect to Facebook(or any other website) Yi Kuo
  • 3. How we access Facebook? What happened in the second?
  • 5. Language: HTTP HyperText Transfer Protocol
  • 6. Language: HTTP HyperText Transfer Protocol GET / HTTP/1.1 Host: www.facebook.com User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:76.0) Gecko/20100101 Firefox/7 Accept: text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,*/*;q=0.8 Accept-Language: zh-TW,zh;q=0.8,en-US;q=0.5,en;q=0.3 Accept-Encoding: gzip, deflate, br Connection: keep-alive Cookie: fr=1KvAgepb7obISMaDy..Bfrpvm.Ej.AAA.0.0.Bfrpvu.AWVbDWhysOw; sb=5puuX_hOTwOlynW1kzQxecHh; datr=5puuX83dw4nqdIGZy_rBc_8P; wd=1280x198; dpr=1.5 Upgrade-Insecure-Requests: 1
  • 7. GET / HTTP/1.1 Host: www.facebook.com User-Agent: Mozilla/5.0 (W Accept: text/html,applicat Accept-Language: zh-TW,zh; Accept-Encoding: gzip, def
  • 8. GET / HTTP/1.1 Host: www.facebook.com User-Agent: Mozilla/5.0 (W Accept: text/html,applicat Accept-Language: zh-TW,zh; Accept-Encoding: gzip, def Request Method Location https://www.facebook.com/ HTTP Version Headers POST
  • 9. GET /kuokuoyiyi HTTP/1.1 Host: www.facebook.com User-Agent: Mozilla/5.0 (W Accept: text/html,applicat Accept-Language: zh-TW,zh; Accept-Encoding: gzip, def Request Method Location https://www.facebook.com/kuokuoyiyi HTTP Version Headers
  • 10. Language: HTTP HyperText Transfer Protocol HTTP/2 200 OK X-Frame-Options: DENY X-Xss-Protection: 0 ⋮ X-Firefox-Spdy: h2 <!DOCTYPE html> <html lang="zh-Hant" id="facebook" class="no_js"> <head><meta charset="utf-8" /><meta name="referrer" content="origin-when- crossorigin" id="meta_referrer" /><script nonce="oX7Z8G3a">window._cstart=+new Date();</script><script nonce="oX7Z8G3a">function envFlush(a){function b(b){for(var c in a
  • 11. HTTP/2 200 OK X-Frame-Options: DENY X-Xss-Protection: 0 ⋮ X-Firefox-Spdy: h2 <!DOCTYPE html>
  • 12. HTTP/2 200 OK X-Frame-Options: DENY X-Xss-Protection: 0 ⋮ X-Firefox-Spdy: h2 <!DOCTYPE html> Status Code Response Data
  • 13. HTTP/2 404 Not Found X-Frame-Options: DENY X-Xss-Protection: 0 ⋮ X-Firefox-Spdy: h2 <!DOCTYPE html> Status Code Response Data
  • 14. HTTP/2 403 Forbidden X-Frame-Options: DENY X-Xss-Protection: 0 ⋮ X-Firefox-Spdy: h2 <!DOCTYPE html> Status Code Response Data
  • 15. Connection: TCP Transmission Control Protocol A A + B B
  • 16. But where is www.facebook.com? ?
  • 17. IP Address Internet Protocol Address 140.114.197.101 31.13.87.36 2a03:2880:f12d:83:face:b00c:0:25de (IPv6)
  • 18. DNS Domain Name System www.facebook.com 31.13.87.36 www.google.com 216.58.200.36 yikuo.dev 172.67.169.118
  • 19. Routing – Sending out to the internet 140.114.197.101 My Computer @ Dorm Hsin 140.114.197.254 Dorm Hsin Floor 3 / 4 Gateway 140.114.1.85 NTHU Networking Center 140.114.1.70 NTHU TANet Gateway 192.192.61.110 TANet Taiwan Academic Network To 31.13.87.36
  • 20. Routing – BGP 140.114.197.101 My Computer @ Dorm Hsin 140.114.197.254 Dorm Hsin Floor 3 / 4 Gateway 140.114.1.85 NTHU Networking Center 140.114.1.70 NTHU TANet Gateway 192.192.61.110 TANet Taiwan Academic Network TANet ISP A Border Gateway Portocal ISP B ISP C The Facebook Network 31.13.*.* Who can get to 31.13.87.36? I can in 1 step I can in 2 steps Who can get to 31.13.87.36? I can in 1 step To 31.13.87.36 Reply from 31.13.87.36
  • 21. Routing – Sending back to sender 140.114.197.101 My Computer @ Dorm Hsin 140.114.197.254 Dorm Hsin Floor 3 / 4 Gateway 140.114.1.85 NTHU Networking Center 140.114.1.70 NTHU TANet Gateway 192.192.61.110 TANet Taiwan Academic Network Reply from 31.13.87.36
  • 22. Internet Protocol Suite of HTTP Physical Connection Routing TCP HTTP
  • 23. Q&A
  • 24. Thanks for your listening!

Editor's Notes

  1. Hi everyone, my name is Yi. I am from Computer Science department. Today I’m going to share about how our computers connect to Facebook, or any other website
  2. We browse the Internet everyday. But have you wonder how does our computers connect to the Internet? How could images from the other side of the world transits to your computer? I will have a simple introduction of how Internet and website works.
  3. First, lets take Facebook as an example. When we want to watch feeds on Facebook, we simply type www.facebook.com into our browser’s address bar. And within a few seconds, Facebook’s homepage showed up! What happened between those few seconds?
  4. A website is actually servers that send information to our computer, and our browser renders the data and show it. Servers are no different from our computer. To connect to a website, our computer has to communicate with their servers to exchange data
  5. Just like humans, computers also need to have a language to communicate. For websites, this language is HTTP. You can see that websites have the http:// prefix in the address. Actually, you may see https:// more often. They are using the same language but the data is encrypted in HTTPS, thus is safer to use HTTPS.
  6. Lets see how HTTP looks like. This is what our computer says to the server when we connect to Facebook’s home page
  7. This is the HTTP Request header. It has several parts:
  8. First, Request Method. We are only fetching the webpage, so we use the GET method. If we want to send additional data to the server, we use the POST method. Next, there is the Location, which page we are going to request. We are going to request the root page, so it looks like this.
  9. If we want to see my Facebook profile, then it looks like this. And next is the HTTP version and some additional Headers. These Headers provide the server with some additional settings. For example, the User-Agent header tells the server what browser we are using.
  10. This is what Facebook’s server response to us
  11. This is the HTTP Response Header. It is similar to the Request, but there are some additional parts
  12. There is the 200 OK Response Code. There are different codes too, such as the famous 404 code.
  13. The 404 Not Found means the user requested a non existent page, and
  14. The 403 Forbidden means the user does not have permission to view the page Bottom here is the response data, the website’s content and is usually in the HTML format
  15. So now we have the language, but what is the medium for them to talk to each other? So here comes TCP. TCP is like a tunnel that can let computers talk to each other. To establish a connection, computers have to do a handshake Lets see how the handshake works… First, our computer sends a number A, then the server generates a number B and sends back A+B, finally, we send B to the server. This can ensure that both computers can receive from each other correctly
  16. But how does our computer knows where is Facebook? Here comes the Routing.
  17. IP Address are like address in our real life, every computer on the network has an IP Address
  18. And there is the domain name system. The domain name system is like a phone book, that gives the corresponding IP address of the Domain Name Actually you can buy your own domain name too! This is my domain name. It will link to my blog
  19. Now we have Facebook’s IP address, we generates a package. And then we send our package out to the Internet Service Provider In NTHU, our service provider is Taiwan Academic Network
  20. Now it comes to border routing, every circle here is an autonomous system. Every autonomous system controls a part of the IP in the Internet, and we have to send our package to the correct autonomous system. So this is how BGP works: First, our ISP asks who can get to Facebook’s IP address? Since ISP B is not directly connected to Facebook, so it also asks. ISP C replies to B that it can get to Facebook in one step, and B replies to us that it can in 2 steps. And ISP A replies to us that it can in one step. Now we have two choices. We will choose the shortest path: going through ISP A We finally got to Facebook, and Facebook generates the response and throw it back to us.
  21. It will follow the opposite way of how we come from, and finally it gets to our computer!
  22. So what I introduced stacks on each other. First there is Physical Connection, such as copper wire, radio waves or optical fiber Next, packets route to the server with the physical connection. And next, TCP makes a tunnel to let us talk to the server. Last, we use HTTP, which is the language our computer talks.