SlideShare une entreprise Scribd logo
1  sur  36
Lecture 2
           • Internet
           • HTTP
           • HTML
           • Cookies
           • Web servers




02/28/11     ΗΥ359 - Διαδικτυοκεντρικός Προγραμματισμός   1
                          Δημήτρης Κοτζίνος
History of the Internet
• ARPAnet
     – Implemented in late 1960’s by ARPA (Advanced
       Research Projects Agency of DOD)
     – Networked computer systems of a dozen universities
       and institutions with 56KB communications lines
     – Grandparent of today’s Internet
     – Intended to allow computers to be shared
     – Became clear that key benefit was allowing fast
       communication between researchers – electronic-mail
       (email)

02/28/11          ΗΥ359 - Διαδικτυοκεντρικός Προγραμματισμός   2
                               Δημήτρης Κοτζίνος
History of the Internet (II)
  • ARPA’s goals
       – Allow multiple users to send and receive info at
         same time
       – Network operated packet switching technique
           • Digital data sent in small packages called packets
           • Packets contained data, address info, error-control info
             and sequencing info
           • Greatly reduced transmission costs of dedicated
             communications lines
       – Network designed to be operated without
         centralized control
           • If portion of network fails, remaining portions still able to
             route packets

02/28/11               ΗΥ359 - Διαδικτυοκεντρικός Προγραμματισμός            3
                                    Δημήτρης Κοτζίνος
History of the Internet (III)
• Transmission Control Protocol (TCP)
     – Name of protocols for communicating over ARPAnet
     – Ensured that messages were properly routed and that
       they arrived intact
• Organizations implemented own networks
     – Used both for intra-organization and communication




02/28/11          ΗΥ359 - Διαδικτυοκεντρικός Προγραμματισμός   4
                               Δημήτρης Κοτζίνος
History of the Internet (IV)
• Huge variety of networking hardware and
  software appeared
      – ARPA achieved inter-communication between all
        platforms with development of the IP
           • Internetworking Protocol
           • Current architecture of Internet
      – Combined set of protocols called TCP/IP
• The Internet
      – Limited to universities and research institutions
      – Military became big user
      – Next, government decided to access Internet for
        commercial purposes
02/28/11               ΗΥ359 - Διαδικτυοκεντρικός Προγραμματισμός   5
                                    Δημήτρης Κοτζίνος
History of the Internet (V)
• Internet traffic grew
     – Businesses spent heavily to improve Internet
           • Better service their clients
     – Fierce competition among communications carriers and
       hardware and software suppliers
     – Result
           • Bandwidth (info carrying capacity) of Internet increased
             tremendously
           • Costs plummeted



02/28/11                ΗΥ359 - Διαδικτυοκεντρικός Προγραμματισμός      6
                                     Δημήτρης Κοτζίνος
Growing of the Internet
• In 1988 when the Internet was first plugged into
  a T1 backbone, there were a total of about
  50,000 hosts.
• In 1993, when the World Wide Web came
  online, the number of hosts had just passed 1
  million mark.
• In 2001, there are more than 100 million hosts
  on the Internet. The Internet is growing in a fast
  speed.
• The most recent survey can be found at
  http://www.isc.org/ds/.

02/28/11       ΗΥ359 - Διαδικτυοκεντρικός Προγραμματισμός   7
                            Δημήτρης Κοτζίνος
Major Events in Internet History (I)
Year       Event

1957       USSR launches Sputnik

1968       First Packet Switching Network

1969       ARPANET Starts

1972       First Public Demo of ARPANET

           Internet Mail Invented

1979       UseNet Starts

1983       ARPANET Changes Over to TCP/IP
           ARPANET Splits into ARPANET & MILNET

1984       Internet Exceeds 1.000 Hosts


           Domain Name Server Introduced


1987       Internet Exceeds 10.000 Hosts

1988       Worm Attacks 6.000 of Internet’s 60.000 Hosts

02/28/11           ΗΥ359 - Διαδικτυοκεντρικός Προγραμματισμός   8
                                Δημήτρης Κοτζίνος
Major Events in Internet History (II)
  Year       Event
  1989       Internet Exceeds 100,000 Hosts
  1990       ARPANET Dismantled Archie Starts
  1986       NSFNET Created
  1991       WAIS Started


             Gopher Started
             NSF Lifts Commercial Ban
  1992       Internet Exceeds 1 million Hosts
             Web Invented by Tim Berners-Lee
  1993       MOSAIC Developed by Marc Andreesen
             InterNIC Founded by NSF




02/28/11          ΗΥ359 - Διαδικτυοκεντρικός Προγραμματισμός   9
                               Δημήτρης Κοτζίνος
Client/Server
• A program running on the end-user
  workstation is called a client.
• A program running on the service part is
  called a server.
• Client/server describes the relationship
  between two computer programs in which
  one program, the client, makes a service
  request from another program, the server,
  which fulfills the request.
02/28/11    ΗΥ359 - Διαδικτυοκεντρικός Προγραμματισμός   10
                         Δημήτρης Κοτζίνος
History of the World Wide Web
 • WWW
       – Allows computer users to locate and view
         multimedia-based documents
       – Introduced in 1990 by Tim Berners-Lee
       – HyperText (Nielsen, 1965)
 • Internet today
       – Mixes computing and communications technologies
       – Makes information constantly and instantly available
         to anyone with a connection



02/28/11            ΗΥ359 - Διαδικτυοκεντρικός Προγραμματισμός   11
                                 Δημήτρης Κοτζίνος
Standard Bodies
•   Internet Society (www.isoc.org)
•   Internet Architecture Board (www.isi.edu/iab)
•   Internet Engineering Task Force (IETF) (www.ietf.org)
•   Internet Research Task Force (IRTF) (www.irtf.org)
•   Internet network Information Center (InterNIC):
     Domain Names (www.internic.net)
• Internet Assigned Numbers Authority (IANA):
     IP addresses (www.iana.org)
• World Wide Wed Concortium (W3C) (www.w3c.org)



02/28/11            ΗΥ359 - Διαδικτυοκεντρικός Προγραμματισμός   12
                                 Δημήτρης Κοτζίνος
World Wide Web Consortium
              (W3C)
 • Founded in 1994 by Tim Berners-Lee
       – Devoted to developing non-proprietary and interoperable
         technologies for the World Wide Web and making the Web
         universally accessible
 • Standardization
       – W3C Recommendations: technologies standardized by W3C
           • include Extensible HyperText Markup Language (XHTML), Cascading
             Style Sheets (CSS) and the Extensible Markup Language (XML)
       – Document must pass through Working Draft, Candidate
         Recommendation and Proposed Recommendation phases before
         considered for W3C Recommendation


02/28/11               ΗΥ359 - Διαδικτυοκεντρικός Προγραμματισμός          13
                                    Δημήτρης Κοτζίνος
World Wide Web Consortium
            (W3C) (II)
• W3C Structure
     – 3 Hosts
           • Massachusetts Institute of Technology (MIT)
           • INRIA (Institut National de Recherche en Informatique et
             Automatique)
           • Keio University of Japan
     – 400 Members (including Deitel & Associates)
• W3C homepage at www.w3c.org
• W3C Goals
     – User Interface Domain
     – Technology and Society Domain
     – Architecture Domain and Web Accessibility Initiatives

02/28/11                 ΗΥ359 - Διαδικτυοκεντρικός Προγραμματισμός     14
                                      Δημήτρης Κοτζίνος
TCP/IP: The Internet Protocol

           Application Layer (HTTP, FTP, SMTP)


               Transport Layer (TCP, UDP)


                     Internet Layer (IP)


                      Physical Network

02/28/11          ΗΥ359 - Διαδικτυοκεντρικός Προγραμματισμός   15
                               Δημήτρης Κοτζίνος
TCP/IP

           FPT        HTTP      TELNET              SNMP          MBONE



                      TCP                                   UDP

                 Connection-                             Connectionles
                  oriented                                    s
                                         IP
                                   (ICMP, IGMP)


                                     Internet
                                    addressing
                                   Physical Layer
                                                    Physical wiring




02/28/11              ΗΥ359 - Διαδικτυοκεντρικός Προγραμματισμός          16
                                   Δημήτρης Κοτζίνος
Uniform Resource Locator - URL
• <scheme>:<scheme-specific name>
• <protocol>://<user>:<password>@<host>:
  <port>/<path>
• http://<user>:<passowrd>:www.csd.uoc.gr
  :80/~kotzino




02/28/11    ΗΥ359 - Διαδικτυοκεντρικός Προγραμματισμός   17
                         Δημήτρης Κοτζίνος
IP addresses




                Octets: network classification
                          216.27.61.137
           11011000.00011011.00111101.10001001

02/28/11      ΗΥ359 - Διαδικτυοκεντρικός Προγραμματισμός   18
                           Δημήτρης Κοτζίνος
Name Servers
• DNS (Domain Names System, 1983,
  University of Wisconsin)
• Domain Names
     – .org, .com, .net, .gov, .edu, .mil
     – .gr




02/28/11          ΗΥ359 - Διαδικτυοκεντρικός Προγραμματισμός   19
                               Δημήτρης Κοτζίνος
HyperText Transfer Protocol (HTTP)
   www.w3c.org/protocols/HTTP
• Client / Server (browser / web server)
• Stateless
• MIME (binary data support)
• Data in two pieces: data & transfer
  description
                       •fewer TCP connections
• Port 80              •compression/decompression
• version 1.1          •multiple languages
                                     •virtual hosting

02/28/11        ΗΥ359 - Διαδικτυοκεντρικός Προγραμματισμός   20
                             Δημήτρης Κοτζίνος
Sockets and Ports (Diagram)

                                      port 13                 Time Service

   Client
                                      port 80                 Web Service

            Socket                Socket


                                                                Server



02/28/11         ΗΥ359 - Διαδικτυοκεντρικός Προγραμματισμός                  21
                              Δημήτρης Κοτζίνος
HTTP
1.     Client opens connection
2.     Client makes the request
3.     Server sends response
4.     Server closes connection

•      HTTP-Keep Alive: server does not close
       connection
•      Restart from (2)
02/28/11        ΗΥ359 - Διαδικτυοκεντρικός Προγραμματισμός   22
                             Δημήτρης Κοτζίνος
HTTP methods
• GET
   retrieves a resource from the server and returns it to the
   client
   GET <URL> HTTP/1.1
• HEAD
   like GET but returns only info about a resource and NOT
   the resource itself
• POST
   sends data from the server to the client

02/28/11          ΗΥ359 - Διαδικτυοκεντρικός Προγραμματισμός   23
                               Δημήτρης Κοτζίνος
The HTTP Connection
• The HTTP protocol is text-based.
• HTTP headers:
     – GET: identifies the request as HTTP version
       1.1.
     – Accept: identifies what image formats are
       accepted.
     – Accept-Language: specifies the language
       used.
     – Accept-Encoding: specifies the data
       compression.
02/28/11        ΗΥ359 - Διαδικτυοκεντρικός Προγραμματισμός   24
                             Δημήτρης Κοτζίνος
The HTTP Connection
• HTTP headers (continued):
     – User-Agent: identifies the user agent.
     – Host: requests the homepage.
     – Connection: specifies to keep the connection
       open.
     – Extension: Something about security.




02/28/11         ΗΥ359 - Διαδικτυοκεντρικός Προγραμματισμός   25
                              Δημήτρης Κοτζίνος
HTTP Request / Response




02/28/11    ΗΥ359 - Διαδικτυοκεντρικός Προγραμματισμός   26
                         Δημήτρης Κοτζίνος
Request headers send from
                    browser
GET /Tests/file.html HTTP/1.0
Referer: http://www.utoronto.ca/webdocs/webinfo.html
Connection: Keep-Alive
Cookie: good=bad; apples=oranges
User-Agent: Mozilla/3.0b5 (Win95; I)
Host: smaug.java.utoronto.ca:2021
Accept:image/gif, image/x-xbitmap, image/jpeg,
  image/pjpeg, */*
Accept-Language: en-US, fr
Accept-Charset: ISO-8859-1, *,UCS-2


02/28/11        ΗΥ359 - Διαδικτυοκεντρικός Προγραμματισμός   27
                             Δημήτρης Κοτζίνος
HTML form that uses GET
<FROM ACTION= “http://smaug.java.utoronto.ca:2021/cgi-bin/form1”
METHOD=GET>
<p> Search string: <INPUT TYPE=”text” NAME=”srch” VALUE=”dogfish”>
<p> Search Type:
   <SELECT NAME=”srch_type”>
      <OPTION> Insensitive Substrinb
      <OPTION SELECTED> Exact Match
      <OPTION> Sensitive Substring
      <OPTION> Regular Expression
     </SELECT>
<p> Search databases in:
  <INPUT TYPE=“checkbox” NAME=“srvr” VALUE=“Canada” CHECKED> Canada
  <INPUT TYPE= “chckbox” NAME=“srvr” VALUE=“Russia” > Russia
   <INPUT TYPE=“checkbox” NAME=“srvr” VALUE=“Sweden” CHECKED> Sweden
   <INPUT TYPE=“checkbox” NAME=“srvr” VALUE=“U.S.A.” > U.S.A
   <em>(multiple items can be selected.)</em>
<P> <INPUT TYPE=“submit”> < <INPUT TYPE=reset>.
</FORM>

02/28/11             ΗΥ359 - Διαδικτυοκεντρικός Προγραμματισμός        28
                                  Δημήτρης Κοτζίνος
Data sent to a HTTP server during
    a form-based GET request
GET /cgi-bin/form1?
  srch=dogfish&srch_type=Exact+Match&srvr=Ca
  nanda&srvr=Sweden HTTP/1.0
Connection:keep-Alive
User-Agent: Mozilla/3.02 (Win95; I)
Host: smaug.java.utoronto.ca:2021
Accept: image/gif, image/x-xbitmap, image/jpeg,
  image/pjpeg, */*
Accept-Language: en-US, fr, fr-CA

02/28/11      ΗΥ359 - Διαδικτυοκεντρικός Προγραμματισμός   29
                           Δημήτρης Κοτζίνος
Form-based POST request
POST /cgi-bin/form1 HTTP/1.0
Connection: Keep-Alive
User-Agent: Mozilla/3.0b5 (Win95; I)
Host: smaug.java.utoronto.ca:2021
Accept:image/gif, image/x-xbitmap, image/jpeg,
   image/pjpeg, */*
Accept-Language: en-US, fr, fr-CA
Content-type: application/x-www-form-urlencoded
Content-length: 58
[a blank line, containing only CRLF ]
srch=dogfish&srch_type=Exact+Match&srvr=Cananda
   &srvr=Sweden

02/28/11      ΗΥ359 - Διαδικτυοκεντρικός Προγραμματισμός   30
                           Δημήτρης Κοτζίνος
HyperText Markup Language (HTML)

• readable by both humans and computers
• based on SGML (Standard Generalized
  Markup Language)
• markup: tags describing the data
• tags: <> </> (tag names case-insensitive)
• Text, images,


02/28/11     ΗΥ359 - Διαδικτυοκεντρικός Προγραμματισμός   31
                          Δημήτρης Κοτζίνος
HTML – Elements and Tags
<h1>This is a level one heading</h1>




02/28/11             ΗΥ359 - Διαδικτυοκεντρικός Προγραμματισμός   32
                                  Δημήτρης Κοτζίνος
HTML files
<html>
<head>
<title>Paragraph Attributes</title>
</head>
<body>
<h1>The Paragraph Attribute Align</h1>
<p align='left'> This is a paragraph with its text pushed against the left-hand
side of the page.
<p align='center'> This is a paragraph with its text placed in the center of the
page.
<p align='right'> This is a paragraph with its text pushed against the righthand
side of the page.
</body>
</html>



02/28/11                ΗΥ359 - Διαδικτυοκεντρικός Προγραμματισμός                 33
                                     Δημήτρης Κοτζίνος
HTML files




02/28/11   ΗΥ359 - Διαδικτυοκεντρικός Προγραμματισμός   34
                        Δημήτρης Κοτζίνος
HTML forms
• <form> …. </form>
• hidden forms: forms not showing on the
  browser but used to preserve state
  information




• Note: HTTP is a stateless protocol

02/28/11            ΗΥ359 - Διαδικτυοκεντρικός Προγραμματισμός   35
                                 Δημήτρης Κοτζίνος
02/28/11   ΗΥ359 - Διαδικτυοκεντρικός Προγραμματισμός   36
                        Δημήτρης Κοτζίνος

Contenu connexe

Tendances

Introduction of Internet Hindi Notes
Introduction of Internet Hindi NotesIntroduction of Internet Hindi Notes
Introduction of Internet Hindi Notes
SirajRock
 
Net To Web 2007 version
Net To Web 2007 versionNet To Web 2007 version
Net To Web 2007 version
Johan Koren
 
The Links that became a Web
The Links that became a WebThe Links that became a Web
The Links that became a Web
Johan Koren
 
Net to web: The Links that became a Web
Net to web:  The Links that became a WebNet to web:  The Links that became a Web
Net to web: The Links that became a Web
Johan Koren
 
History ofwww internetprinciples
History ofwww internetprinciplesHistory ofwww internetprinciples
History ofwww internetprinciples
Akshay Kochhar
 
Hrd 860 Presentation
Hrd 860 PresentationHrd 860 Presentation
Hrd 860 Presentation
mmbrown
 
9781423903055 ppt ch02
9781423903055 ppt ch029781423903055 ppt ch02
9781423903055 ppt ch02
临枫 盖
 

Tendances (20)

Internet History - ICCA Pondicherry 30 jan 2012
Internet History - ICCA Pondicherry 30 jan 2012Internet History - ICCA Pondicherry 30 jan 2012
Internet History - ICCA Pondicherry 30 jan 2012
 
Internet to Web
Internet to WebInternet to Web
Internet to Web
 
FreedomBox & Community Wi-Fi networks
FreedomBox & Community Wi-Fi networksFreedomBox & Community Wi-Fi networks
FreedomBox & Community Wi-Fi networks
 
Introduction of Internet Hindi Notes
Introduction of Internet Hindi NotesIntroduction of Internet Hindi Notes
Introduction of Internet Hindi Notes
 
computer Unit 9
computer Unit 9computer Unit 9
computer Unit 9
 
CS101- Introduction to Computing- Lecture 28
CS101- Introduction to Computing- Lecture 28CS101- Introduction to Computing- Lecture 28
CS101- Introduction to Computing- Lecture 28
 
Net To Web 2007 version
Net To Web 2007 versionNet To Web 2007 version
Net To Web 2007 version
 
The Links that became a Web
The Links that became a WebThe Links that became a Web
The Links that became a Web
 
Assignment 01
Assignment 01Assignment 01
Assignment 01
 
Net to web: The Links that became a Web
Net to web:  The Links that became a WebNet to web:  The Links that became a Web
Net to web: The Links that became a Web
 
History of Internet and advantages of internet
History of Internet and advantages of internetHistory of Internet and advantages of internet
History of Internet and advantages of internet
 
History ofwww internetprinciples
History ofwww internetprinciplesHistory ofwww internetprinciples
History ofwww internetprinciples
 
Hrd 860 Presentation
Hrd 860 PresentationHrd 860 Presentation
Hrd 860 Presentation
 
Networking lesson
Networking lessonNetworking lesson
Networking lesson
 
Assignment 01
Assignment 01Assignment 01
Assignment 01
 
9781423903055 ppt ch02
9781423903055 ppt ch029781423903055 ppt ch02
9781423903055 ppt ch02
 
Internet
InternetInternet
Internet
 
Networks - Lecture C
Networks - Lecture CNetworks - Lecture C
Networks - Lecture C
 
Network and internet fundamental
Network and internet fundamentalNetwork and internet fundamental
Network and internet fundamental
 
Internet and www
Internet and wwwInternet and www
Internet and www
 

En vedette (9)

Chinese luck
Chinese luckChinese luck
Chinese luck
 
Food[1]
Food[1]Food[1]
Food[1]
 
Unconditional love
Unconditional loveUnconditional love
Unconditional love
 
OGDCL
OGDCLOGDCL
OGDCL
 
The bracelet
The braceletThe bracelet
The bracelet
 
Network Security
Network SecurityNetwork Security
Network Security
 
2002 0918 internet_history_and_growth
2002 0918 internet_history_and_growth2002 0918 internet_history_and_growth
2002 0918 internet_history_and_growth
 
Luckier
LuckierLuckier
Luckier
 
History lecture notes s2004
History lecture notes   s2004History lecture notes   s2004
History lecture notes s2004
 

Similaire à Lecture2

Mis jaiswal-chapter-03
Mis jaiswal-chapter-03Mis jaiswal-chapter-03
Mis jaiswal-chapter-03
Amit Fogla
 
Internet and web by Gulshan K Maheshwari(QAU)
Internet and web by Gulshan  K Maheshwari(QAU)Internet and web by Gulshan  K Maheshwari(QAU)
Internet and web by Gulshan K Maheshwari(QAU)
GulshanKumar368
 
ISBB_Chapter5.pptx
ISBB_Chapter5.pptxISBB_Chapter5.pptx
ISBB_Chapter5.pptx
MitKumar2
 

Similaire à Lecture2 (20)

A simple lecture on Computers and Internet Technologies
A simple lecture on Computers and Internet TechnologiesA simple lecture on Computers and Internet Technologies
A simple lecture on Computers and Internet Technologies
 
Mis jaiswal-chapter-03
Mis jaiswal-chapter-03Mis jaiswal-chapter-03
Mis jaiswal-chapter-03
 
intro-to-internet.ppt
intro-to-internet.pptintro-to-internet.ppt
intro-to-internet.ppt
 
intro-to-internet.ppt
intro-to-internet.pptintro-to-internet.ppt
intro-to-internet.ppt
 
Data Communication and Networking
Data Communication and NetworkingData Communication and Networking
Data Communication and Networking
 
Internet Presentation
Internet PresentationInternet Presentation
Internet Presentation
 
lecture1.ppt
lecture1.pptlecture1.ppt
lecture1.ppt
 
lecture1.ppt
lecture1.pptlecture1.ppt
lecture1.ppt
 
Data Communication-1.ppt
Data Communication-1.pptData Communication-1.ppt
Data Communication-1.ppt
 
lecture1 (1).ppt
lecture1 (1).pptlecture1 (1).ppt
lecture1 (1).ppt
 
Web Technologies Introduction to web technologies
Web Technologies Introduction to web technologiesWeb Technologies Introduction to web technologies
Web Technologies Introduction to web technologies
 
e COMMERCE INFRASTRUCTURE.pptx
e COMMERCE INFRASTRUCTURE.pptxe COMMERCE INFRASTRUCTURE.pptx
e COMMERCE INFRASTRUCTURE.pptx
 
Internet and web by Gulshan K Maheshwari(QAU)
Internet and web by Gulshan  K Maheshwari(QAU)Internet and web by Gulshan  K Maheshwari(QAU)
Internet and web by Gulshan K Maheshwari(QAU)
 
HOW DOES THE INTERNET WORK BY BATANGAS EASTERN COLLEGES.pptx
HOW DOES THE INTERNET WORK BY BATANGAS EASTERN COLLEGES.pptxHOW DOES THE INTERNET WORK BY BATANGAS EASTERN COLLEGES.pptx
HOW DOES THE INTERNET WORK BY BATANGAS EASTERN COLLEGES.pptx
 
Telecommunications, the internet, and wireless technology
Telecommunications, the internet, and wireless technologyTelecommunications, the internet, and wireless technology
Telecommunications, the internet, and wireless technology
 
Dc ch01 : data communications, data networks, and the internet
Dc ch01 : data communications, data networks, and the internetDc ch01 : data communications, data networks, and the internet
Dc ch01 : data communications, data networks, and the internet
 
ISBB_Chapter5.pptx
ISBB_Chapter5.pptxISBB_Chapter5.pptx
ISBB_Chapter5.pptx
 
ISBB_Chapter5.pptx
ISBB_Chapter5.pptxISBB_Chapter5.pptx
ISBB_Chapter5.pptx
 
009458666.pdf
009458666.pdf009458666.pdf
009458666.pdf
 
Ecommerce Chap 11
Ecommerce Chap 11Ecommerce Chap 11
Ecommerce Chap 11
 

Plus de MUHAMMAD UMAIR (20)

MPH1.pptx
MPH1.pptxMPH1.pptx
MPH1.pptx
 
My Own Demography 2 Population Composition.pptx
My Own Demography 2 Population Composition.pptxMy Own Demography 2 Population Composition.pptx
My Own Demography 2 Population Composition.pptx
 
My Own Demography 3 Population Pyramid.pptx
My Own Demography 3 Population Pyramid.pptxMy Own Demography 3 Population Pyramid.pptx
My Own Demography 3 Population Pyramid.pptx
 
Demography 1 Introduction.pptx
Demography 1 Introduction.pptxDemography 1 Introduction.pptx
Demography 1 Introduction.pptx
 
My Own Demography 4 Demographic transition.pptx
My Own Demography 4 Demographic transition.pptxMy Own Demography 4 Demographic transition.pptx
My Own Demography 4 Demographic transition.pptx
 
Green marketing
Green marketingGreen marketing
Green marketing
 
Crescent Fibres
Crescent FibresCrescent Fibres
Crescent Fibres
 
Wind energy(Pakistan)
Wind energy(Pakistan)Wind energy(Pakistan)
Wind energy(Pakistan)
 
OIL AND GAS DEVELOPMENT CORPORATION PAKISTAN(OGDCL)
OIL AND GAS DEVELOPMENT CORPORATION PAKISTAN(OGDCL)OIL AND GAS DEVELOPMENT CORPORATION PAKISTAN(OGDCL)
OIL AND GAS DEVELOPMENT CORPORATION PAKISTAN(OGDCL)
 
Site talk world_domination_jan_2011
Site talk world_domination_jan_2011Site talk world_domination_jan_2011
Site talk world_domination_jan_2011
 
Unaico business information_training
Unaico business information_trainingUnaico business information_training
Unaico business information_training
 
Why men die early
Why men die earlyWhy men die early
Why men die early
 
Tomorrow
TomorrowTomorrow
Tomorrow
 
Put mouse on nose
Put mouse on nosePut mouse on nose
Put mouse on nose
 
Photo shoot
Photo shootPhoto shoot
Photo shoot
 
Look into this
Look into thisLook into this
Look into this
 
Kids
KidsKids
Kids
 
Friendship
FriendshipFriendship
Friendship
 
Friends
FriendsFriends
Friends
 
Emails
EmailsEmails
Emails
 

Dernier

Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and Myths
Joaquim Jorge
 
Histor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slideHistor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slide
vu2urc
 

Dernier (20)

How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
Real Time Object Detection Using Open CV
Real Time Object Detection Using Open CVReal Time Object Detection Using Open CV
Real Time Object Detection Using Open CV
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day Presentation
 
Strategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherStrategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a Fresher
 
HTML Injection Attacks: Impact and Mitigation Strategies
HTML Injection Attacks: Impact and Mitigation StrategiesHTML Injection Attacks: Impact and Mitigation Strategies
HTML Injection Attacks: Impact and Mitigation Strategies
 
Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Script
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
 
AWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of TerraformAWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of Terraform
 
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdfUnderstanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
 
Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
 
Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024
 
Advantages of Hiring UIUX Design Service Providers for Your Business
Advantages of Hiring UIUX Design Service Providers for Your BusinessAdvantages of Hiring UIUX Design Service Providers for Your Business
Advantages of Hiring UIUX Design Service Providers for Your Business
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)
 
Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and Myths
 
Handwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsHandwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed texts
 
Exploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone ProcessorsExploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone Processors
 
A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?
 
Histor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slideHistor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slide
 
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
 

Lecture2

  • 1. Lecture 2 • Internet • HTTP • HTML • Cookies • Web servers 02/28/11 ΗΥ359 - Διαδικτυοκεντρικός Προγραμματισμός 1 Δημήτρης Κοτζίνος
  • 2. History of the Internet • ARPAnet – Implemented in late 1960’s by ARPA (Advanced Research Projects Agency of DOD) – Networked computer systems of a dozen universities and institutions with 56KB communications lines – Grandparent of today’s Internet – Intended to allow computers to be shared – Became clear that key benefit was allowing fast communication between researchers – electronic-mail (email) 02/28/11 ΗΥ359 - Διαδικτυοκεντρικός Προγραμματισμός 2 Δημήτρης Κοτζίνος
  • 3. History of the Internet (II) • ARPA’s goals – Allow multiple users to send and receive info at same time – Network operated packet switching technique • Digital data sent in small packages called packets • Packets contained data, address info, error-control info and sequencing info • Greatly reduced transmission costs of dedicated communications lines – Network designed to be operated without centralized control • If portion of network fails, remaining portions still able to route packets 02/28/11 ΗΥ359 - Διαδικτυοκεντρικός Προγραμματισμός 3 Δημήτρης Κοτζίνος
  • 4. History of the Internet (III) • Transmission Control Protocol (TCP) – Name of protocols for communicating over ARPAnet – Ensured that messages were properly routed and that they arrived intact • Organizations implemented own networks – Used both for intra-organization and communication 02/28/11 ΗΥ359 - Διαδικτυοκεντρικός Προγραμματισμός 4 Δημήτρης Κοτζίνος
  • 5. History of the Internet (IV) • Huge variety of networking hardware and software appeared – ARPA achieved inter-communication between all platforms with development of the IP • Internetworking Protocol • Current architecture of Internet – Combined set of protocols called TCP/IP • The Internet – Limited to universities and research institutions – Military became big user – Next, government decided to access Internet for commercial purposes 02/28/11 ΗΥ359 - Διαδικτυοκεντρικός Προγραμματισμός 5 Δημήτρης Κοτζίνος
  • 6. History of the Internet (V) • Internet traffic grew – Businesses spent heavily to improve Internet • Better service their clients – Fierce competition among communications carriers and hardware and software suppliers – Result • Bandwidth (info carrying capacity) of Internet increased tremendously • Costs plummeted 02/28/11 ΗΥ359 - Διαδικτυοκεντρικός Προγραμματισμός 6 Δημήτρης Κοτζίνος
  • 7. Growing of the Internet • In 1988 when the Internet was first plugged into a T1 backbone, there were a total of about 50,000 hosts. • In 1993, when the World Wide Web came online, the number of hosts had just passed 1 million mark. • In 2001, there are more than 100 million hosts on the Internet. The Internet is growing in a fast speed. • The most recent survey can be found at http://www.isc.org/ds/. 02/28/11 ΗΥ359 - Διαδικτυοκεντρικός Προγραμματισμός 7 Δημήτρης Κοτζίνος
  • 8. Major Events in Internet History (I) Year Event 1957 USSR launches Sputnik 1968 First Packet Switching Network 1969 ARPANET Starts 1972 First Public Demo of ARPANET Internet Mail Invented 1979 UseNet Starts 1983 ARPANET Changes Over to TCP/IP ARPANET Splits into ARPANET & MILNET 1984 Internet Exceeds 1.000 Hosts Domain Name Server Introduced 1987 Internet Exceeds 10.000 Hosts 1988 Worm Attacks 6.000 of Internet’s 60.000 Hosts 02/28/11 ΗΥ359 - Διαδικτυοκεντρικός Προγραμματισμός 8 Δημήτρης Κοτζίνος
  • 9. Major Events in Internet History (II) Year Event 1989 Internet Exceeds 100,000 Hosts 1990 ARPANET Dismantled Archie Starts 1986 NSFNET Created 1991 WAIS Started Gopher Started NSF Lifts Commercial Ban 1992 Internet Exceeds 1 million Hosts Web Invented by Tim Berners-Lee 1993 MOSAIC Developed by Marc Andreesen InterNIC Founded by NSF 02/28/11 ΗΥ359 - Διαδικτυοκεντρικός Προγραμματισμός 9 Δημήτρης Κοτζίνος
  • 10. Client/Server • A program running on the end-user workstation is called a client. • A program running on the service part is called a server. • Client/server describes the relationship between two computer programs in which one program, the client, makes a service request from another program, the server, which fulfills the request. 02/28/11 ΗΥ359 - Διαδικτυοκεντρικός Προγραμματισμός 10 Δημήτρης Κοτζίνος
  • 11. History of the World Wide Web • WWW – Allows computer users to locate and view multimedia-based documents – Introduced in 1990 by Tim Berners-Lee – HyperText (Nielsen, 1965) • Internet today – Mixes computing and communications technologies – Makes information constantly and instantly available to anyone with a connection 02/28/11 ΗΥ359 - Διαδικτυοκεντρικός Προγραμματισμός 11 Δημήτρης Κοτζίνος
  • 12. Standard Bodies • Internet Society (www.isoc.org) • Internet Architecture Board (www.isi.edu/iab) • Internet Engineering Task Force (IETF) (www.ietf.org) • Internet Research Task Force (IRTF) (www.irtf.org) • Internet network Information Center (InterNIC): Domain Names (www.internic.net) • Internet Assigned Numbers Authority (IANA): IP addresses (www.iana.org) • World Wide Wed Concortium (W3C) (www.w3c.org) 02/28/11 ΗΥ359 - Διαδικτυοκεντρικός Προγραμματισμός 12 Δημήτρης Κοτζίνος
  • 13. World Wide Web Consortium (W3C) • Founded in 1994 by Tim Berners-Lee – Devoted to developing non-proprietary and interoperable technologies for the World Wide Web and making the Web universally accessible • Standardization – W3C Recommendations: technologies standardized by W3C • include Extensible HyperText Markup Language (XHTML), Cascading Style Sheets (CSS) and the Extensible Markup Language (XML) – Document must pass through Working Draft, Candidate Recommendation and Proposed Recommendation phases before considered for W3C Recommendation 02/28/11 ΗΥ359 - Διαδικτυοκεντρικός Προγραμματισμός 13 Δημήτρης Κοτζίνος
  • 14. World Wide Web Consortium (W3C) (II) • W3C Structure – 3 Hosts • Massachusetts Institute of Technology (MIT) • INRIA (Institut National de Recherche en Informatique et Automatique) • Keio University of Japan – 400 Members (including Deitel & Associates) • W3C homepage at www.w3c.org • W3C Goals – User Interface Domain – Technology and Society Domain – Architecture Domain and Web Accessibility Initiatives 02/28/11 ΗΥ359 - Διαδικτυοκεντρικός Προγραμματισμός 14 Δημήτρης Κοτζίνος
  • 15. TCP/IP: The Internet Protocol Application Layer (HTTP, FTP, SMTP) Transport Layer (TCP, UDP) Internet Layer (IP) Physical Network 02/28/11 ΗΥ359 - Διαδικτυοκεντρικός Προγραμματισμός 15 Δημήτρης Κοτζίνος
  • 16. TCP/IP FPT HTTP TELNET SNMP MBONE TCP UDP Connection- Connectionles oriented s IP (ICMP, IGMP) Internet addressing Physical Layer Physical wiring 02/28/11 ΗΥ359 - Διαδικτυοκεντρικός Προγραμματισμός 16 Δημήτρης Κοτζίνος
  • 17. Uniform Resource Locator - URL • <scheme>:<scheme-specific name> • <protocol>://<user>:<password>@<host>: <port>/<path> • http://<user>:<passowrd>:www.csd.uoc.gr :80/~kotzino 02/28/11 ΗΥ359 - Διαδικτυοκεντρικός Προγραμματισμός 17 Δημήτρης Κοτζίνος
  • 18. IP addresses Octets: network classification 216.27.61.137 11011000.00011011.00111101.10001001 02/28/11 ΗΥ359 - Διαδικτυοκεντρικός Προγραμματισμός 18 Δημήτρης Κοτζίνος
  • 19. Name Servers • DNS (Domain Names System, 1983, University of Wisconsin) • Domain Names – .org, .com, .net, .gov, .edu, .mil – .gr 02/28/11 ΗΥ359 - Διαδικτυοκεντρικός Προγραμματισμός 19 Δημήτρης Κοτζίνος
  • 20. HyperText Transfer Protocol (HTTP) www.w3c.org/protocols/HTTP • Client / Server (browser / web server) • Stateless • MIME (binary data support) • Data in two pieces: data & transfer description •fewer TCP connections • Port 80 •compression/decompression • version 1.1 •multiple languages •virtual hosting 02/28/11 ΗΥ359 - Διαδικτυοκεντρικός Προγραμματισμός 20 Δημήτρης Κοτζίνος
  • 21. Sockets and Ports (Diagram) port 13 Time Service Client port 80 Web Service Socket Socket Server 02/28/11 ΗΥ359 - Διαδικτυοκεντρικός Προγραμματισμός 21 Δημήτρης Κοτζίνος
  • 22. HTTP 1. Client opens connection 2. Client makes the request 3. Server sends response 4. Server closes connection • HTTP-Keep Alive: server does not close connection • Restart from (2) 02/28/11 ΗΥ359 - Διαδικτυοκεντρικός Προγραμματισμός 22 Δημήτρης Κοτζίνος
  • 23. HTTP methods • GET retrieves a resource from the server and returns it to the client GET <URL> HTTP/1.1 • HEAD like GET but returns only info about a resource and NOT the resource itself • POST sends data from the server to the client 02/28/11 ΗΥ359 - Διαδικτυοκεντρικός Προγραμματισμός 23 Δημήτρης Κοτζίνος
  • 24. The HTTP Connection • The HTTP protocol is text-based. • HTTP headers: – GET: identifies the request as HTTP version 1.1. – Accept: identifies what image formats are accepted. – Accept-Language: specifies the language used. – Accept-Encoding: specifies the data compression. 02/28/11 ΗΥ359 - Διαδικτυοκεντρικός Προγραμματισμός 24 Δημήτρης Κοτζίνος
  • 25. The HTTP Connection • HTTP headers (continued): – User-Agent: identifies the user agent. – Host: requests the homepage. – Connection: specifies to keep the connection open. – Extension: Something about security. 02/28/11 ΗΥ359 - Διαδικτυοκεντρικός Προγραμματισμός 25 Δημήτρης Κοτζίνος
  • 26. HTTP Request / Response 02/28/11 ΗΥ359 - Διαδικτυοκεντρικός Προγραμματισμός 26 Δημήτρης Κοτζίνος
  • 27. Request headers send from browser GET /Tests/file.html HTTP/1.0 Referer: http://www.utoronto.ca/webdocs/webinfo.html Connection: Keep-Alive Cookie: good=bad; apples=oranges User-Agent: Mozilla/3.0b5 (Win95; I) Host: smaug.java.utoronto.ca:2021 Accept:image/gif, image/x-xbitmap, image/jpeg, image/pjpeg, */* Accept-Language: en-US, fr Accept-Charset: ISO-8859-1, *,UCS-2 02/28/11 ΗΥ359 - Διαδικτυοκεντρικός Προγραμματισμός 27 Δημήτρης Κοτζίνος
  • 28. HTML form that uses GET <FROM ACTION= “http://smaug.java.utoronto.ca:2021/cgi-bin/form1” METHOD=GET> <p> Search string: <INPUT TYPE=”text” NAME=”srch” VALUE=”dogfish”> <p> Search Type: <SELECT NAME=”srch_type”> <OPTION> Insensitive Substrinb <OPTION SELECTED> Exact Match <OPTION> Sensitive Substring <OPTION> Regular Expression </SELECT> <p> Search databases in: <INPUT TYPE=“checkbox” NAME=“srvr” VALUE=“Canada” CHECKED> Canada <INPUT TYPE= “chckbox” NAME=“srvr” VALUE=“Russia” > Russia <INPUT TYPE=“checkbox” NAME=“srvr” VALUE=“Sweden” CHECKED> Sweden <INPUT TYPE=“checkbox” NAME=“srvr” VALUE=“U.S.A.” > U.S.A <em>(multiple items can be selected.)</em> <P> <INPUT TYPE=“submit”> < <INPUT TYPE=reset>. </FORM> 02/28/11 ΗΥ359 - Διαδικτυοκεντρικός Προγραμματισμός 28 Δημήτρης Κοτζίνος
  • 29. Data sent to a HTTP server during a form-based GET request GET /cgi-bin/form1? srch=dogfish&srch_type=Exact+Match&srvr=Ca nanda&srvr=Sweden HTTP/1.0 Connection:keep-Alive User-Agent: Mozilla/3.02 (Win95; I) Host: smaug.java.utoronto.ca:2021 Accept: image/gif, image/x-xbitmap, image/jpeg, image/pjpeg, */* Accept-Language: en-US, fr, fr-CA 02/28/11 ΗΥ359 - Διαδικτυοκεντρικός Προγραμματισμός 29 Δημήτρης Κοτζίνος
  • 30. Form-based POST request POST /cgi-bin/form1 HTTP/1.0 Connection: Keep-Alive User-Agent: Mozilla/3.0b5 (Win95; I) Host: smaug.java.utoronto.ca:2021 Accept:image/gif, image/x-xbitmap, image/jpeg, image/pjpeg, */* Accept-Language: en-US, fr, fr-CA Content-type: application/x-www-form-urlencoded Content-length: 58 [a blank line, containing only CRLF ] srch=dogfish&srch_type=Exact+Match&srvr=Cananda &srvr=Sweden 02/28/11 ΗΥ359 - Διαδικτυοκεντρικός Προγραμματισμός 30 Δημήτρης Κοτζίνος
  • 31. HyperText Markup Language (HTML) • readable by both humans and computers • based on SGML (Standard Generalized Markup Language) • markup: tags describing the data • tags: <> </> (tag names case-insensitive) • Text, images, 02/28/11 ΗΥ359 - Διαδικτυοκεντρικός Προγραμματισμός 31 Δημήτρης Κοτζίνος
  • 32. HTML – Elements and Tags <h1>This is a level one heading</h1> 02/28/11 ΗΥ359 - Διαδικτυοκεντρικός Προγραμματισμός 32 Δημήτρης Κοτζίνος
  • 33. HTML files <html> <head> <title>Paragraph Attributes</title> </head> <body> <h1>The Paragraph Attribute Align</h1> <p align='left'> This is a paragraph with its text pushed against the left-hand side of the page. <p align='center'> This is a paragraph with its text placed in the center of the page. <p align='right'> This is a paragraph with its text pushed against the righthand side of the page. </body> </html> 02/28/11 ΗΥ359 - Διαδικτυοκεντρικός Προγραμματισμός 33 Δημήτρης Κοτζίνος
  • 34. HTML files 02/28/11 ΗΥ359 - Διαδικτυοκεντρικός Προγραμματισμός 34 Δημήτρης Κοτζίνος
  • 35. HTML forms • <form> …. </form> • hidden forms: forms not showing on the browser but used to preserve state information • Note: HTTP is a stateless protocol 02/28/11 ΗΥ359 - Διαδικτυοκεντρικός Προγραμματισμός 35 Δημήτρης Κοτζίνος
  • 36. 02/28/11 ΗΥ359 - Διαδικτυοκεντρικός Προγραμματισμός 36 Δημήτρης Κοτζίνος