Server-Side Web Programming: Python (Part 1) Copyright 2017 by Robert M. Dondero, Ph.D. Princeton University
|
|
- Peregrine Gilbert
- 5 years ago
- Views:
Transcription
1 Server-Side Web Programming: Python (Part 1) Copyright 2017 by Robert M. Dondero, Ph.D. Princeton University 1
2 Objectives You will learn about Server-side web programming in Python Common Gateway Interface (CGI) programming Fundamentals Stateful programming HTTP redirection 2
3 Agenda 1. CGI Programming Fundamentals 2. Stateful CGI Programming 3. HTTP Redirection in CGI Programming
4 Motivating Example Demo of PennyPython1Fund app HTML server does more than deliver static HTML pages HTML server generates HTML pages dynamically, and then delivers them Based upon argument supplied by browser Using data retrieved from a database 4
5 Problem Generalizing Problem: Often static HTML pages are insufficient Often HTTP server must generate HTML pages dynamically Based upon arguments supplied by browser Using data retrieved from a database 5
6 Solution One solution: Common Gateway Interface (CGI) protocol 6
7 URLs (Revisited) URL format: protocol://host:port/file.py? name1=value1&name2=value2&... Same as previously described, except... Browser passes program name file.py and name/value pair(s) to HTTP server HTTP server forks/execs process running file.py and passes name/value pair(s) to process 7
8 HTML Links (Revisited) <a href=" Same as previously described, except... Browser passes program name file.py and name/value pair(s) to HTTP server HTTP server forks/execs process running file.py and passes name/value pair(s) to process 8
9 HTML Forms (Revisited) Or could be "post"; see upcoming slides <form action=" method="get"> <input type="text" name="name1" value="value1"><br> <input type="text" name="name2" value="value2"><br> <input type="submit"> </form> Same as previously described, except... Browser passes program name file.py and name/ value pair(s) to HTTP server HTTP server forks/execs process running file.py and passes name/value pair(s) to process 9
10 Aside: URL Encoding Names and values are URL encoded Each special character (", ', =, &, etc.) is encoded as %nn (hex) Each space is encoded as + Many standard libraries provide functions/ methods to encode and decode... 10
11 Aside: URL Encoding in Python See urlencode.py Try command line arguments: one 't wo' 'th" ree' 11
12 Aside: URL Encoding in Java See UrlEncode.java Try command line arguments: one 't wo' 'th" ree' 12
13 CGI Details: GET Method Browser Or could be POST; see upcoming slides Socket GET file.py?name1=value1&name2=value2 HTTP/1.1 Host: host <Blank line> HTTP Server Environment variable fork/exec Pipe (usually) QUERY_STRING: name1=value1&name2=value2 13
14 CGI Details: GET Method file.py Uses QUERY_STRING Writes to stdout database wait Pipe (usually) Content-Type: text/html <Blank line> <HTML page> somefile HTTP Server Socket Browser HTTP/ OK Date: date Server: server Content-Type: text/html <Blank line> <HTML page> There are some additional headers 14
15 Hello Get in Python See HelloPythonGet app runserver runserver.bat index.html hello.py 15
16 CGI Example: GET Method Browser User types Bob Dondero and clicks form submit button Socket GET hello.py?person=bob+dondero HTTP/1.1 Host: localhost <Blank line> HTTP Server Environment variable fork/exec Pipe (usually) QUERY_STRING: person=bob+dondero 16
17 CGI Example: GET Method hello.py Content-Type: text/html wait Pipe (usually) HTTP Server Socket Browser <!DOCTYPE html> <html> <body> <p>hello, Bob Dondero</p> </body> </html> HTTP/ OK Content-Type: text/html <!DOCTYPE html> <html> <body> <p>hello, Bob Dondero</p> </body> </html> Uses QUERY_STRING Writes to stdout There are some additional headers 17
18 Review: How to GET Question: How can user command browser to generate a GET request? Answer: 3 ways 18
19 Review: How to GET Answer 1: Enter a URL at top of browser The default protocol is http There is no default host The default port is 80 The default file name is index.html or index.php, depending upon HTTP server configuration 19
20 Review: How to GET Answer 2: Click on a page link <a href=" </a> The default protocol is http The default host is the host that delivered this page The default port is the port from which this page was delivered 20
21 Review: How to GET Answer 3: Submit a form User enters Bob Dondero <form action=" method="get" <input type="text" name="person" value="somedefault"> <input type="submit"> </form> The default protocol is http The default host is the host that delivered this page The default port is the port from which this page was delivered 21
22 CGI Details: POST Method Browser Socket POST file.py HTTP/1.1 Host: host Content-type: application/x-www-form-urlencoded Content-length: length <Blank line> name1=value1&name2=value2 HTTP Server fork/exec Pipe (usually) stdin: name1=value1&name2=value2 22
23 CGI Details: POST Method file.py Reads from stdin Writes to stdout database wait Pipe (usually) Content-Type: text/html <Blank line> <HTML page> somefile HTTP Server Socket Browser HTTP/ OK Date: date Server: server Content-Type: text/html <Blank line> <HTML page> There are some additional headers 23
24 Hello Post in Python See HelloPythonPost app runserver, runserver.bat index.html hello.py 24
25 CGI Example: POST Method Browser Socket User types Bob Dondero and clicks form submit button POST hello.py HTTP/1.1 Host: localhost Content-type: application/x-www-form-urlencoded Content-length: 18 person=bob+dondero HTTP Server fork/exec Pipe (usually) stdin: person=bob+dondero 25
26 CGI Example: POST Method wait file.py Pipe (usually) HTTP Server Socket Browser Content-Type: text/html <!DOCTYPE html> <html> <body> <p>hello, Bob Dondero</p> </body> </html> HTTP/ OK Content-Type: text/html <!DOCTYPE html> <html> <body> <p>hello, Bob Dondero</p> </body> </html> Reads from stdin Writes to stdout There are some additional headers 26
27 Review: How to POST Question: How can user command browser to generate a POST request? Answer: Submit a form User enters Bob Dondero <form action=" method="post" <input type="text" name="person" value="somedefault"> <input type="submit"> </form> The default protocol is http The default host is the host that delivered this page The default port is the port from which this page was delivered 27
28 FancyForm in Python See FancyForm app runserver, runserver.bat index.html fancyform.py input tag Type text, password, radio, checkbox, hidden, reset, submit textarea tag select and option tags 28
29 GET vs. POST GET method name=value pairs passed in request header POST method name=value pairs passed in request body Same power When to use which? 29
30 GET vs. POST Technical Criteria Use POST when: There are very many name=value pairs, and/or... Some name=value pairs are very long Keep HTTP request headers under 2000 chars name=value pairs contain non-ascii chars 30
31 GET vs. POST Convention Use GET iff request is idempotent The request does not change server-side state Processing the same name=value pairs twice has same effect as processing them once Use POST iff request is not idempotent The request does change server-side state Processing the same name=value pairs twice had different effect from processing them once 31
32 GET vs. POST Convention With that convention... Browser sees POST request => Browser assumes request is not idempotent Browser warns about page refresh Browser sees GET request => Browser assume request is idempotent Browser does not warn about page refresh 32
33 GET vs. POST Example Example: Web page asks for the price of a car Form should use GET Browser: GET => idempotent Refresh page => no problem Example: Web page purchases a car Form should use POST Browser: POST => not idempotent Refresh page => generate warning Illustrated by FancyForm app 33
34 GET vs. POST Recommendation Generally: Use GET to query server-side data And maybe for learning Use POST to change server-side data 34
35 PennyPython1Fund App Browser Author name prefix HTTP Server Author name prefix CGI Program database Author names, book titles, book prices HTTP Server Author names, book titles, book prices Browser 35
36 PennyPython1Fund App See PennyPython1Fund app runserver, runserver.bat penny.sql penny.sqlite (not shown in hard copy) book.py database.py common.py index.html searchform.py searchresults.py 36
37 Agenda 1. CGI Programming Fundamentals 2. Stateful CGI Programming 3. HTTP Redirection in CGI Programming 37
38 Motivating Example Demo of PennyPython2State application Displays name of previous searched-for author in searchform page But how??? Application must remember previous author name when generating searchform page 38
39 Motivating Example Browser <form action= "searchresults.py" method="get"> Prev search: (None) Browser Click here to do another author search <a href="searchform.py"> Browser <form action= "searchresults.py" method="get"> Prev search:??? User enters "Ker" HTTP Server HTTP Server HTTP Server HTTP Server searchresults.py searchform.py Doesn't know previous author 39
40 Problem Generalizing Problem: HTTP is a stateless protocol Neither browser nor HTTP server remembers previous interactions CGI program exits; so it can t remember either! 40
41 Examples Penny app Want to remember previous search Search engine Want to remember previous searches Commercial app Want to remember shopping cart Secure app Want to remember that user logged in 41
42 State via URL Rewriting Solution 1: URL rewriting Append state data to end of URL 42
43 State via URL Rewriting Example Browser <form action= "searchresults.py" method="get"> Prev search: (None) Browser Click here to do another author search <a href="searchform.py? prevauthor=ker"> Browser <form action= "searchresults.py" method="get"> Prev search: Ker User enters "Ker" HTTP Server HTTP Server HTTP Server HTTP Server searchresults.py Performs URL rewriting searchform.py Does know previous author 43
44 State via Hidden Form Fields Solution 2: Hidden form fields Place state data into form input tag of type hidden Browser does not display 44
45 Browser State via Form Fields Example <form action="searchresults.py" method="get">... Prev search: (None) Browser User enters "Ker" HTTP Server searchresults.py Click here to do another author search <form action="searchform.py" method="get"> <input type="hidden" name="prevauthor" value="ker"> <input type="submit">... HTTP Server HTTP Server Generates hidden form field Browser <form action="searchresults.py" method="get">... Prev search: Ker HTTP Server searchform.py Does know previous author 45
46 State via Cookies Solution 3: Cookies HTTP server: Places state in a cookie Passes cookie to browser as header And then... 46
47 State via Cookies Browser: Retains cookie in memory or client file system Until specified cookie expiration date Until human user explicitly deletes it Passes cookie to HTTP server as header But only to same web app that sent it originally 47
48 Cookie Attributes Cookie attributes: Name Content Host & path The host to which the browser should send the cookie The directory where the cookie is active Default is the directory of page that created cookie Host & path define the web app that sent & should receive the cookie Expiration date Default is this browser session Etc. 48
49 State via Cookies Example Browser <form action="searchresults.py" method="get">... Prev search: (None) User enters "Ker" HTTP Server GET searchresults.py?author=ker HTTP/1.1 Host: localhost <blank line> searchresults.py QUERY_STRING: author=ker Set-Cookie: prevauthor=ker Content-type: Text/html <blank line> <HTML page> 49
50 State via Cookies Example HTTP Server Browser Click here to do another author search <a href="searchform.py"> HTTP/ OK Date: date Server: localhost Set-Cookie: prevauthor=ker Content-Type: Text/html <Blank line> <HTML page> Browser retains cookie HTTP Server GET searchform.py HTTP/1.1 Host: localhost Cookie: prevauthor=ker <blank line> HTTP_COOKIE: prevauthor=ker 50
51 State via Cookies Example searchform.py Knows previous author via HTTP_COOKIE env var Content-type: Text/html <blank line> <HTML page containing Ker> HTTP Server HTTP/ OK Date: date Server: localhost Content-Type: Text/html <Blank line> <HTML page containing Ker> Browser <form action="searchresults.py" method="get">... Prev search: Ker 51
52 PennyPython2State App See PennyPython2State app penny.sql, penny.sqlite, runserver, runserver.bat, book.py, database.py, common.py, index.html searchresults.py Asks browser to store prevauthor cookie searchform.py Uses prevauthor cookie stored by browser 52
53 PennyPython2State App Try viewing cookies in Firefox: Tools Page Info Security View Cookies Try viewing cookies in Chrome: Settings Advanced Privacy & security Content settings Cookies 53
54 Cookie Issue: Size Problem: Cookie size is limited to 4K Solution: Cookie content stored on server-side (in database), indexed by a unique key Cookie contains key only See sessions as implemented in frameworks and PHP 54
55 Cookie Issue: Disabled Cookies Problem: User may disable browser cookies Solution: Ask the user to enable them! Or... Add more logic Fall back to URL rewriting or hidden form fields if necessary 55
56 Cookie Issue: 3rd Party Cookies Problem: Third-party cookies can invade privacy (See Cookie_stuffing) 56
57 Cookie Issue: 3rd Party Cookies Browser AdConsultant contracts with Company1 & Company2 Company1.com Page which includes (hidden) request to fetch blank image from AdConsultant.com User visited Company1 Browser AdConsultant.com Image Set AdConsultant cookie: User visited Company1 AdConsultant knows that user visited Company1 57
58 Cookie Issue: 3rd Party Cookies Company2.com Page which includes (hidden) request to fetch blank image from AdConsultant.com User visited Company2 AdConsultant cookie: User visited Company1 Browser AdConsultant.com Image Set AdConsultant cookie: User visited Company2 AdConsultant knows that user visited Company1 and Company2 AdConsultant provides user profile to Company1 & Company2 58
59 Cookie Issue: 3rd Party Cookies Solution: Tell browser to refuse third-party cookies In Firefox: Edit Preferences Privacy Firefox will Use custom settings for history Accept thirdparty cookies Never But then can t use CAS authentication! Edit Preferences Privacy Firefox will Use custom settings for history Accept thirdparty cookies From visited 59
60 Cookie Issue: 3rd Party Cookies In Chrome: Settings Advanced Privacy & security Content settings Cookies Block third-party cookies 60
61 Agenda 1. CGI Programming Fundamentals 2. Stateful CGI Programming 3. HTTP Redirection in CGI Programming 61
62 Motivating Example Demo of PennyPython3Red app Distinguishes between: Name of author who has no books in database Displays (none) Missing author name Causes redirection back to searchform page Displays error message, prompting user to enter a name 62
63 Problem Generalizing Problem: Often web app must redirect to a page other than requested one Original page Login page Error page 63
64 Solution Solution: HTTP redirection CGI program writes headers to stdout: Status: 307 Temporary Redirect Location: newurl <blank line> HTTP server forwards headers to browser Browser accepts headers, requests newurl 64
65 PennyPython3Red App See PennyPython3Red app penny.sql, penny.sqlite, runserver, runserver.bat, book.py, database.py, common.py, index.html searchform.py searchresults.py 65
66 HTTP Status Codes HTTP Status Code Description 200 OK Standard response for successful HTTP requests. 307 Temporary Redirect The request should be repeated with another URI; however, future requests should still use the original URI. 404 Not Found The requested resource could not be found but may be available in the future. Subsequent requests by the client are permissible. Descriptions from: 66
67 Summary We have covered: Server-side web programming in Python Common Gateway Interface (CGI) programming Fundamentals Stateful programming HTTP redirection 67
CS105 Perl: Perl CGI. Nathan Clement 24 Feb 2014
CS105 Perl: Perl CGI Nathan Clement 24 Feb 2014 Agenda We will cover some CGI basics, including Perl-specific CGI What is CGI? Server Architecture GET vs POST Preserving State in CGI URL Rewriting, Hidden
More informationCOSC 2206 Internet Tools. The HTTP Protocol
COSC 2206 Internet Tools The HTTP Protocol http://www.w3.org/protocols/ What is TCP/IP? TCP: Transmission Control Protocol IP: Internet Protocol These network protocols provide a standard method for sending
More informationNETB 329 Lecture 13 Python CGI Programming
NETB 329 Lecture 13 Python CGI Programming 1 of 83 What is CGI? The Common Gateway Interface, or CGI, is a set of standards that define how information is exchanged between the web server and a custom
More informationForms, CGI. Objectives
Forms, CGI Objectives The basics of HTML forms How form content is submitted GET, POST Elements that you can have in forms Responding to forms Common Gateway Interface (CGI) Later: Servlets Generation
More informationServer-Side Web Programming: Python (Part 2) Copyright 2017 by Robert M. Dondero, Ph.D Princeton University
Server-Side Web Programming: Python (Part 2) Copyright 2017 by Robert M. Dondero, Ph.D Princeton University 1 Objectives You will learn about: Python WSGI programming Web app frameworks in general (briefly)
More informationUSQ/CSC2406 Web Publishing
USQ/CSC2406 Web Publishing Lecture 4: HTML Forms, Server & CGI Scripts Tralvex (Rex) Yeap 19 December 2002 Outline Quick Review on Lecture 3 Topic 7: HTML Forms Topic 8: Server & CGI Scripts Class Activity
More informationThe HTTP Protocol HTTP
The HTTP Protocol HTTP Copyright (c) 2013 Young W. Lim. Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License, Version 1.2 or any later
More informationOutline of Lecture 5. Course Content. Objectives of Lecture 6 CGI and HTML Forms
Web-Based Information Systems Fall 2004 CMPUT 410: CGI and HTML Forms Dr. Osmar R. Zaïane University of Alberta Outline of Lecture 5 Introduction Poor Man s Animation Animation with Java Animation with
More informationDynamic Documents. Kent State University Dept. of Math & Computer Science. CS 4/55231 Internet Engineering. What is a Script?
CS 4/55231 Internet Engineering Kent State University Dept. of Math & Computer Science LECT-12 Dynamic Documents 1 2 Why Dynamic Documents are needed? There are many situations when customization of the
More informationCGI Architecture Diagram. Web browser takes response from web server and displays either the received file or error message.
What is CGI? The Common Gateway Interface (CGI) is a set of standards that define how information is exchanged between the web server and a custom script. is a standard for external gateway programs to
More informationHTTP Protocol and Server-Side Basics
HTTP Protocol and Server-Side Basics Web Programming Uta Priss ZELL, Ostfalia University 2013 Web Programming HTTP Protocol and Server-Side Basics Slide 1/26 Outline The HTTP protocol Environment Variables
More informationWeb Programming. Based on Notes by D. Hollinger Also Java Network Programming and Distributed Computing, Chs.. 9,10 Also Online Java Tutorial, Sun.
Web Programming Based on Notes by D. Hollinger Also Java Network Programming and Distributed Computing, Chs.. 9,10 Also Online Java Tutorial, Sun. 1 World-Wide Wide Web (Tim Berners-Lee & Cailliau 92)
More informationCSC309: Introduction to Web Programming. Lecture 8
CSC309: Introduction to Web Programming Lecture 8 Wael Aboulsaadat Front Layer Web Browser HTTP Request Get http://abc.ca/index.html Web (HTTP) Server HTTP Response .. How
More informationForms, CGI. HTML forms. Form example. Form example...
Objectives HTML forms The basics of HTML forms How form content is submitted GET, POST Elements that you can have in forms Responding to forms CGI the Common Gateway Interface Later: Servlets Generation
More informationINTERNET ENGINEERING. HTTP Protocol. Sadegh Aliakbary
INTERNET ENGINEERING HTTP Protocol Sadegh Aliakbary Agenda HTTP Protocol HTTP Methods HTTP Request and Response State in HTTP Internet Engineering 2 HTTP HTTP Hyper-Text Transfer Protocol (HTTP) The fundamental
More informationLecture 9a: Sessions and Cookies
CS 655 / 441 Fall 2007 Lecture 9a: Sessions and Cookies 1 Review: Structure of a Web Application On every interchange between client and server, server must: Parse request. Look up session state and global
More informationWeb technologies. Web. basic components. embellishments in browser. DOM (document object model)
Web technologies DOM (document object model) what's on the page and how it can be manipulated forms / CGI (common gateway interface) extract info from a form, create a page, send it back server side code
More informationPYTHON CGI PROGRAMMING
PYTHON CGI PROGRAMMING http://www.tutorialspoint.com/python/python_cgi_programming.htm Copyright tutorialspoint.com The Common Gateway Interface, or CGI, is a set of standards that define how information
More informationForms, CGI. Cristian Bogdan 2D2052 / 2D1335 F5 1
Forms, CGI Cristian Bogdan 2D2052 / 2D1335 F5 1 Objectives The basics of HTML forms How form content is submitted GET, POST Elements that you can have in forms Responding to forms Common Gateway Interface
More informationChapter 1 FORMS. SYS-ED/ Computer Education Techniques, Inc.
Chapter 1 FORMS SYS-ED/ Computer Education Techniques, Inc. Objectives You will learn: How to use forms and the related form types. Controls for interacting with forms. Menus and presenting users with
More informationSaving State on the WWW
Saving State on the WWW The Issue Connections on the WWW are stateless Every time a link is followed is like the first time to the server it has no memory for connections Why Bother To Fix This? By saving
More informationWorld Wide Web, etc.
World Wide Web, etc. Alex S. Raw data-packets wouldn t be much use to humans if there weren t many application level protocols, such as SMTP (for e-mail), HTTP & HTML (for www), etc. 1 The Web The following
More informationCommon Gateway Interface CGI
Common Gateway Interface CGI Copyright (c) 2013-2015 Young W. Lim. Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License, Version 1.2
More informationJavascript, Java, Flash, Silverlight, HTML5 (animation, audio/video, ) Ajax (asynchronous Javascript and XML)
Web technologies browser sends requests to server, displays results DOM (document object model): structure of page contents forms / CGI (common gateway interface) client side uses HTML/CSS, Javascript,
More informationComputer Networks. Wenzhong Li. Nanjing University
Computer Networks Wenzhong Li Nanjing University 1 Chapter 8. Internet Applications Internet Applications Overview Domain Name Service (DNS) Electronic Mail File Transfer Protocol (FTP) WWW and HTTP Content
More informationIntroduction to HTTP. Jonathan Sillito
Introduction to HTTP Jonathan Sillito If you interested in working with a professor next Summer 2011 apply for an NSERC Undergraduate Student Award. Students must have a GPA of 3.0 or higher to be eligible.
More informationlast time: command injection
Web Security 1 last time: command injection 2 placing user input in more complicated language SQL shell commands input accidentally treated as commands in language instead of single value (e.g. argument/string
More informationWEB TECHNOLOGIES CHAPTER 1
WEB TECHNOLOGIES CHAPTER 1 WEB ESSENTIALS: CLIENTS, SERVERS, AND COMMUNICATION Modified by Ahmed Sallam Based on original slides by Jeffrey C. Jackson THE INTERNET Technical origin: ARPANET (late 1960
More informationServer-Side Web Programming: Java. Copyright 2017 by Robert M. Dondero, Ph.D Princeton University
Server-Side Web Programming: Java Copyright 2017 by Robert M. Dondero, Ph.D Princeton University 1 Objectives You will learn about: Server-side web programming in Java, via Servlets The Spark web app framework
More informationGET /index.php HTTP/1.1 Host: User- agent: Mozilla/4.0
State management GET /index.php HTTP/1.1 Host: www.mtech.edu User- agent: Mozilla/4.0 HTTP/1.1 200 OK Date: Thu, 17 Nov 2011 15:54:10 GMT Server: Apache/2.2.16 (Debian) Content- Length: 285 Set- Cookie:
More informationServer-side computing
Server-side computing Why server-side? Approaches 1 Why server-side? Markup languages cannot Specify Computations Interactions with users Provide access to Server-side resources Databases Programs Services
More informationSession 8. Reading and Reference. en.wikipedia.org/wiki/list_of_http_headers. en.wikipedia.org/wiki/http_status_codes
Session 8 Deployment Descriptor 1 Reading Reading and Reference en.wikipedia.org/wiki/http Reference http headers en.wikipedia.org/wiki/list_of_http_headers http status codes en.wikipedia.org/wiki/_status_codes
More informationHypertext Transport Protocol
Hypertext Transport Protocol HTTP Hypertext Transport Protocol Language of the Web protocol used for communication between web browsers and web servers TCP port 80 HTTP - URLs URL Uniform Resource Locator
More informationWeb, HTTP and Web Caching
Web, HTTP and Web Caching 1 HTTP overview HTTP: hypertext transfer protocol Web s application layer protocol client/ model client: browser that requests, receives, displays Web objects : Web sends objects
More informationBackend Development. SWE 432, Fall 2017 Design and Implementation of Software for the Web
Backend Development SWE 432, Fall 2017 Design and Implementation of Software for the Web Real World Example https://qz.com/1073221/the-hackers-who-broke-into-equifax-exploited-a-nine-year-old-security-flaw/
More informationCMSC 332 Computer Networking Web and FTP
CMSC 332 Computer Networking Web and FTP Professor Szajda CMSC 332: Computer Networks Project The first project has been posted on the website. Check the web page for the link! Due 2/2! Enter strings into
More informationCS637 Midterm Review
CS637 Midterm Review Coverage: Duckett Chapter 1-2: Basics: Can skip pp. 53-56 Chapter 3: Lists: all important Chapter 4:Links: all important Chapter 5:Images: can skip old code Chapter 6: Tables: all
More informationChapter 4 Sending Data to Your Application
Chapter 4 Sending Data to Your Application Charles Severance and Jim Eng csev@umich.edu jimeng@umich.edu Textbook: Using Google App Engine, Charles Severance Unless otherwise noted, the content of this
More informationEarly Data Analyzer Web User Guide
Early Data Analyzer Web User Guide Early Data Analyzer, Version 1.4 About Early Data Analyzer Web Getting Started Installing Early Data Analyzer Web Opening a Case About the Case Dashboard Filtering Tagging
More informationEDA095 HTTP. Pierre Nugues. March 30, Lund University
EDA095 HTTP Pierre Nugues Lund University http://cs.lth.se/pierre_nugues/ March 30, 2017 Covers: Chapter 6, Java Network Programming, 4 rd ed., Elliotte Rusty Harold Pierre Nugues EDA095 HTTP March 30,
More informationForm Processing in PHP
Form Processing in PHP Forms Forms are special components which allow your site visitors to supply various information on the HTML page. We have previously talked about creating HTML forms. Forms typically
More informationCS 43: Computer Networks. HTTP September 10, 2018
CS 43: Computer Networks HTTP September 10, 2018 Reading Quiz Lecture 4 - Slide 2 Five-layer protocol stack HTTP Request message Headers protocol delineators Last class Lecture 4 - Slide 3 HTTP GET vs.
More informationUsing OAuth 2.0 to Access ionbiz APIs
Using OAuth 2.0 to Access ionbiz APIs ionbiz APIs use the OAuth 2.0 protocol for authentication and authorization. ionbiz supports common OAuth 2.0 scenarios such as those for web server, installed, and
More informationHTTP Reading: Section and COS 461: Computer Networks Spring 2013
HTTP Reading: Section 9.1.2 and 9.4.3 COS 461: Computer Networks Spring 2013 1 Recap: Client-Server Communication Client sometimes on Initiates a request to the server when interested E.g., Web browser
More informationCOS 333: Advanced Programming Techniques. Copyright 2017 by Robert M. Dondero, Ph.D. Princeton University
COS 333: Advanced Programming Techniques Copyright 2017 by Robert M. Dondero, Ph.D. Princeton University 1 Agenda Introductions Course Overview Resources Topics Assignments Project (briefly) Schedule (briefly)
More informationWeb Security. Jace Baker, Nick Ramos, Hugo Espiritu, Andrew Le
Web Security Jace Baker, Nick Ramos, Hugo Espiritu, Andrew Le Topics Web Architecture Parameter Tampering Local File Inclusion SQL Injection XSS Web Architecture Web Request Structure Web Request Structure
More information3. WWW and HTTP. Fig.3.1 Architecture of WWW
3. WWW and HTTP The World Wide Web (WWW) is a repository of information linked together from points all over the world. The WWW has a unique combination of flexibility, portability, and user-friendly features
More informationNIELSEN API PORTAL USER REGISTRATION GUIDE
NIELSEN API PORTAL USER REGISTRATION GUIDE 1 INTRODUCTION In order to access the Nielsen API Portal services, there are three steps that need to be followed sequentially by the user: 1. User Registration
More informationHow to clear a web browsers cache, cookies and history last updated on 8/28/2013
How to clear a web browsers cache, cookies and history last updated on 8/28/2013 About cache, cookies, and history Each time you access a file through your web browser, the browser caches (i.e., stores)
More informationLecture 7b: HTTP. Feb. 24, Internet and Intranet Protocols and Applications
Internet and Intranet Protocols and Applications Lecture 7b: HTTP Feb. 24, 2004 Arthur Goldberg Computer Science Department New York University artg@cs.nyu.edu WWW - HTTP/1.1 Web s application layer protocol
More informationCOS 333: Advanced Programming Techniques. Robert M. Dondero, Ph.D. Princeton University
COS 333: Advanced Programming Techniques Robert M. Dondero, Ph.D. Princeton University 1 Agenda Introductions General Information Topics Assignments Project (briefly) Schedule Policies The Programming
More informationChapter 9. Managing State Information. Understanding State Information (continued) Understanding State Information 10/29/2011.
Chapter 9 Managing State Information PHP Programming with MySQL 2 nd Edition Objectives In this chapter, you will: Learn about state information Use hidden form fields to save state information Use query
More informationNetworking and Internet
Today s Topic Lecture 13 Web Fundamentals Networking and Internet LAN Web pages Web resources Web client Web Server HTTP Protocol HTML & HTML Forms 1 2 LAN (Local Area Network) Networking and Internet
More informationClickToCall SkypeTest Documentation
ClickToCall SkypeTest Documentation Release 0.0.1 Andrea Mucci August 04, 2015 Contents 1 Requirements 3 2 Installation 5 3 Database Installation 7 4 Usage 9 5 Contents 11 5.1 REST API................................................
More informationJava4570: Session Tracking using Cookies *
OpenStax-CNX module: m48571 1 Java4570: Session Tracking using Cookies * R.G. (Dick) Baldwin This work is produced by OpenStax-CNX and licensed under the Creative Commons Attribution License 4.0 Abstract
More informationCOMP519 Web Programming Lecture 28: PHP (Part 4) Handouts
COMP519 Web Programming Lecture 28: PHP (Part 4) Handouts Ullrich Hustadt Department of Computer Science School of Electrical Engineering, Electronics, and Computer Science University of Liverpool Contents
More informationCGI Programming. What is "CGI"?
CGI Programming What is "CGI"? Common Gateway Interface A means of running an executable program via the Web. CGI is not a Perl-specific concept. Almost any language can produce CGI programs even C++ (gasp!!)
More information5/19/2015. Objectives. JavaScript, Sixth Edition. Saving State Information with Query Strings. Understanding State Information
Objectives JavaScript, Sixth Edition When you complete this chapter, you will be able to: Save state information with query strings, hidden form fields, and cookies Describe JavaScript security issues
More informationHow browsers talk to servers. What does this do?
HTTP HEADERS How browsers talk to servers This is more of an outline than a tutorial. I wanted to give our web team a quick overview of what headers are and what they mean for client-server communication.
More informationCMPT 165 INTRODUCTION TO THE INTERNET AND THE WORLD WIDE WEB
CMPT 165 INTRODUCTION TO THE INTERNET AND THE WORLD WIDE WEB Unit 8 HTML Forms and Basic CGI Slides based on course material SFU Icons their respective owners 1 Learning Objectives In this unit you will
More informationHTML forms and the dynamic web
HTML forms and the dynamic web Antonio Lioy < lioy@polito.it > english version created by Marco D. Aime < m.aime@polito.it > Politecnico di Torino Dip. Automatica e Informatica timetable.html departure
More informationUnraveling the Mysteries of J2EE Web Application Communications
Unraveling the Mysteries of J2EE Web Application Communications An HTTP Primer Peter Koletzke Technical Director & Principal Instructor Common Problem What we ve got here is failure to commun cate. Captain,
More informationWeb Engineering. Basic Technologies: Protocols and Web Servers. Husni
Web Engineering Basic Technologies: Protocols and Web Servers Husni Husni@trunojoyo.ac.id Basic Web Technologies HTTP and HTML Web Servers Proxy Servers Content Delivery Networks Where we will be later
More informationCS 5450 HTTP. Vitaly Shmatikov
CS 5450 HTTP Vitaly Shmatikov Browser and Network Browser OS Hardware request reply website Network slide 2 HTML A web page includes Base HTML file Referenced objects (e.g., images) HTML: Hypertext Markup
More informationWeb forms and CGI scripts
Web forms and CGI scripts Dr. Andrew C.R. Martin andrew.martin@ucl.ac.uk http://www.bioinf.org.uk/ Aims and objectives Understand how the web works Be able to create forms on HTML pages Understand how
More informationOutline. Lecture 8: CGI (Common Gateway Interface ) Common Gateway Interface (CGI) CGI Overview
Outline Lecture 8: CGI (Common Gateway Interface ) CGI Overview Between Client and Handler Between Web Server and Handler Wendy Liu CSC309F Fall 2007 1 2 Common Gateway Interface (CGI) CGI Overview http://www.oreilly.com/openbook/cgi/
More informationCMPE 151: Network Administration. Servers
CMPE 151: Network Administration Servers Announcements Unix shell+emacs tutorial. Basic Servers Telnet/Finger FTP Web SSH NNTP Let s look at the underlying protocols. Client-Server Model Request Response
More informationExcerpts of Web Application Security focusing on Data Validation. adapted for F.I.S.T. 2004, Frankfurt
Excerpts of Web Application Security focusing on Data Validation adapted for F.I.S.T. 2004, Frankfurt by fs Purpose of this course: 1. Relate to WA s and get a basic understanding of them 2. Understand
More informationYou can also set the expiration time of the cookie in another way. It may be easier than using seconds.
What is a Cookie? A cookie is often used to identify a user. A cookie is a small file that the server embeds on the user's computer. Each time the same computer requests a page with a browser, it will
More informationWeb Focused Programming With PHP
Web Focused Programming With PHP May 20 2014 Thomas Beebe Advanced DataTools Corp (tom@advancedatatools.com) Tom Beebe Tom is a Senior Database Consultant and has been with Advanced DataTools for over
More informationMaster Calendar Integrated Authentication Configuration Instructions. Dean Evans & Associates, Inc.
Master Calendar Integrated Authentication Configuration Instructions Dean Evans & Associates, Inc. Copyright Copyright 2013 Dean Evans & Associates, Inc. All rights reserved. No part of this document may
More informationHow to Create a NetBeans PHP Project
How to Create a NetBeans PHP Project 1. SET UP PERMISSIONS FOR YOUR PHP WEB SITE... 2 2. CREATE NEW PROJECT ("PHP APPLICATION FROM REMOTE SERVER")... 2 3. SPECIFY PROJECT NAME AND LOCATION... 2 4. SPECIFY
More informationInformation Retrieval CS Lecture 13. Razvan C. Bunescu School of Electrical Engineering and Computer Science
Information Retrieval CS 6900 Razvan C. Bunescu School of Electrical Engineering and Computer Science bunescu@ohio.edu Web Search Interfaces Web search engines need a web-based interface. Search page accepts
More informationC24: Web API: Passing Arguments and Parsing Returns
CISC 3120 C24: Web API: Passing Arguments and Parsing Returns Hui Chen Department of Computer & Information Science CUNY Brooklyn College 5/7/2018 CUNY Brooklyn College 1 Outline Parsing arguments/data
More informationLecture 3. HTTP v1.0 application layer protocol. into details. HTTP 1.0: RFC 1945, T. Berners-Lee HTTP 1.1: RFC 2068, 2616
Lecture 3. HTTP v1.0 application layer protocol into details HTTP 1.0: RFC 1945, T. Berners-Lee Lee,, R. Fielding, H. Frystyk, may 1996 HTTP 1.1: RFC 2068, 2616 Ascii protocol uses plain text case sensitive
More informationSpring 2014 Interim. HTML forms
HTML forms Forms are used very often when the user needs to provide information to the web server: Entering keywords in a search box Placing an order Subscribing to a mailing list Posting a comment Filling
More informationOutline of Lecture 3 Protocols
Web-Based Information Systems Fall 2007 CMPUT 410: Protocols Dr. Osmar R. Zaïane University of Alberta Course Content Introduction Internet and WWW TML and beyond Animation & WWW CGI & TML Forms Javascript
More informationFirst Simple Interactive JSP example
Let s look at our first simple interactive JSP example named hellojsp.jsp. In his Hello User example, the HTML page takes a user name from a HTML form and sends a request to a JSP page, and JSP page generates
More informationWeb Development and HTML. Shan-Hung Wu CS, NTHU
Web Development and HTML Shan-Hung Wu CS, NTHU Outline How does Internet Work? Web Development HTML Block vs. Inline elements Lists Links and Attributes Tables Forms 2 Outline How does Internet Work? Web
More informationCreating Forms in SOCS
Training Creating Forms in SOCS Use the Form option on the Advanced Tool Bar to create a form to post to your SOCS site. The form allows visitors to complete the information online. The information gathered
More informationMaster Syndication Gateway V2. User's Manual. Copyright Bontrager Connection LLC
Master Syndication Gateway V2 User's Manual Copyright 2005-2006 Bontrager Connection LLC 1 Introduction This document is formatted for A4 printer paper. A version formatted for letter size printer paper
More informationThe HTTP protocol. Fulvio Corno, Dario Bonino. 08/10/09 http 1
The HTTP protocol Fulvio Corno, Dario Bonino 08/10/09 http 1 What is HTTP? HTTP stands for Hypertext Transfer Protocol It is the network protocol used to delivery virtually all data over the WWW: Images
More information1 Form Basics CSC309
1 Form Basics Web Data 2! Most interesting web pages revolve around data! examples: Google, IMDB, Digg, Facebook, YouTube! can take many formats: text, HTML, XML, multimedia! Many of them allow us to access
More informationPemrograman Jaringan Web Client Access PTIIK
Pemrograman Jaringan Web Client Access PTIIK - 2012 In This Chapter You'll learn how to : Download web pages Authenticate to a remote HTTP server Submit form data Handle errors Communicate with protocols
More informationAdvanced API Security
Advanced API Security ITANA Group Nuwan Dias Architect 22/06/2017 Agenda 2 HTTP Basic Authentication Authorization: Basic QWxhZGRpbjpPcGVuU2VzYW1l 3 API Security is about controlling Access Delegation
More informationDeveloper Resources: PIN2
Administrative Technology Services Technology and Data Services Developer Resources: PIN2 Contents Introduction... 2 Registering an Application... 2 Information Required for Registration... 3 Information
More informationpinremote Manual Version 4.0
pinremote Manual Version 4.0 Page 1 Table of content 1 Introduction... 4 2 Setup... 5 2.1 Requirements server... 5 2.2 Requirements client... 5 2.3 Setup process... 6 2.3.1 Single Server... 8 2.3.2 Cluster...
More informationRESTful Services. Distributed Enabling Platform
RESTful Services 1 https://dev.twitter.com/docs/api 2 http://developer.linkedin.com/apis 3 http://docs.aws.amazon.com/amazons3/latest/api/apirest.html 4 Web Architectural Components 1. Identification:
More informationInstructions For Configuring Your Browser Settings and Online Banking FAQ's
Instructions For Configuring Your Browser Settings and Online Banking FAQ's Instructions By Browser Type Google Chrome Firefox Internet Explorer 8 Internet Explorer 9 Safari Online Banking FAQ's Google
More informationHow to work with HTTP requests and responses
How a web server processes static web pages Chapter 18 How to work with HTTP requests and responses How a web server processes dynamic web pages Slide 1 Slide 2 The components of a servlet/jsp application
More informationICOM 5016 Database Systems. Database Users. User Interfaces and Tools. Chapter 8: Application Design and Development.
Chapter 8: Application Design and Development ICOM 5016 Database Systems Web Application Amir H. Chinaei Department of Electrical and Computer Engineering University of Puerto Rico, Mayagüez User Interfaces
More informationRemote Desktop Services
Remote Desktop Services AMERICAN INSTITUTES FOR RESEARCH AIR REMOTE DESKTOP SERVICES (RDS) GUIDE Overview Welcome to! can be accessed from a Windows computer, a Mac, and even a mobile device; such as an
More informationLAMP, WEB ARCHITECTURE, AND HTTP
CS 418 Web Programming Spring 2013 LAMP, WEB ARCHITECTURE, AND HTTP SCOTT G. AINSWORTH http://www.cs.odu.edu/~sainswor/cs418-s13/ 2 OUTLINE Assigned Reading Chapter 1 Configuring Your Installation pgs.
More informationCNIT 129S: Securing Web Applications. Ch 3: Web Application Technologies
CNIT 129S: Securing Web Applications Ch 3: Web Application Technologies HTTP Hypertext Transfer Protocol (HTTP) Connectionless protocol Client sends an HTTP request to a Web server Gets an HTTP response
More informationShankersinh Vaghela Bapu Institue of Technology
Branch: - 6th Sem IT Year/Sem : - 3rd /2014 Subject & Subject Code : Faculty Name : - Nitin Padariya Pre Upload Date: 31/12/2013 Submission Date: 9/1/2014 [1] Explain the need of web server and web browser
More informationInstallation & Configuration Guide Enterprise/Unlimited Edition
Installation & Configuration Guide Enterprise/Unlimited Edition Version 2.3 Updated January 2014 Table of Contents Getting Started... 3 Introduction... 3 Requirements... 3 Support... 4 Recommended Browsers...
More informationComposer Help. Web Request Common Block
Composer Help Web Request Common Block 7/4/2018 Web Request Common Block Contents 1 Web Request Common Block 1.1 Name Property 1.2 Block Notes Property 1.3 Exceptions Property 1.4 Request Method Property
More informationProtocols. Networking CS 3470, Section 1 Sarah Diesburg
Protocols Networking CS 3470, Section 1 Sarah Diesburg Applications Applications need their own protocols Just like we are writing our network programs with a certain specification so that any two randomly-chosen
More informationChapter 27 WWW and HTTP Copyright The McGraw-Hill Companies, Inc. Permission required for reproduction or display.
Chapter 27 WWW and HTTP 27.1 Copyright The McGraw-Hill Companies, Inc. Permission required for reproduction or display. 27-1 ARCHITECTURE The WWW today is a distributed client/server service, in which
More informationRicoh Managed File Transfer (MFT) User Guide
Ricoh Managed File Transfer (MFT) User Guide -- TABLE OF CONTENTS 1 ACCESSING THE SITE... 3 1.1. WHAT IS RICOH MFT... 3 1.2. SUPPORTED BROWSERS... 3 1.3. LOG IN... 3 1.4. NAVIGATION... 4 1.5. FORGOTTEN
More information