Requests and Server Response Codes

Slides:



Advertisements
Similar presentations
Hypertext Transfer PROTOCOL ----HTTP Sen Wang CSE5232 Network Programming.
Advertisements

Modern Web Application Frameworks CSE 591 – Security and Vulnerability Analysis Spring 2015 Adam Doupé Arizona State University
Servlets and a little bit of Web Services Russell Beale.
CS320 Web and Internet Programming Generating HTTP Responses
HTTP Hypertext Transfer Protocol. HTTP messages HTTP is the language that web clients and web servers use to talk to each other –HTTP is largely “under.
How the web works: HTTP and CGI explained
Hypertext Transfer Protocol Information Systems 337 Prof. Harry Plantinga.
HTTP Overview Vijayan Sugumaran School of Business Administration Oakland University.
2/9/2004 Web and HTTP February 9, /9/2004 Assignments Due – Reading and Warmup Work on Message of the Day.
Hypertext Transport Protocol CS Dick Steflik.
 What is it ? What is it ?  URI,URN,URL URI,URN,URL  HTTP – methods HTTP – methods  HTTP Request Packets HTTP Request Packets  HTTP Request Headers.
Rensselaer Polytechnic Institute CSC-432 – Operating Systems David Goldschmidt, Ph.D.
Meta Tags What are Meta Tags And How Are They Best Used?
Form Handling, Validation and Functions. Form Handling Forms are a graphical user interfaces (GUIs) that enables the interaction between users and servers.
Sys Prog & Scripting - HW Univ1 Systems Programming & Scripting Lecture 15: PHP Introduction.
HTTP; The World Wide Web Protocol
Chapter 1: Introduction to Web
Server tools. Site server tools can be utilised to build, host, track and monitor transactions on a business site. There are a wide range of possibilities.
FTP (File Transfer Protocol) & Telnet
HyperText Transfer Protocol (HTTP).  HTTP is the protocol that supports communication between web browsers and web servers.  A “Web Server” is a HTTP.
CP476 Internet Computing Lecture 5 : HTTP, WWW and URL 1 Lecture 5. WWW, HTTP and URL Objective: to review the concepts of WWW to understand how HTTP works.
Copyright (c) 2010, Dr. Kuanchin Chen1 The Client-Server Architecture of the WWW Dr. Kuanchin Chen.
CSE 190: Internet E-Commerce Lecture 5. Exam Material Lectures 1-4 (Presentation Tier) –3-tier architecture –HTML –Style sheets –Javascript –DOM –HTTP.
Introduction to HTML. What is a HTML File?  HTML stands for Hyper Text Markup Language  An HTML file is a text file containing small markup tags  The.
Kingdom of Saudi Arabia Ministry of Higher Education Al-Imam Muhammad Ibn Saud Islamic University College of Computer and Information Sciences Chapter.
CIS679: Lecture 13 r Review of Last Lecture r More on HTTP.
1-1 HTTP request message GET /somedir/page.html HTTP/1.1 Host: User-agent: Mozilla/4.0 Connection: close Accept-language:fr request.
Appendix E: Overview of HTTP ©SoftMoore ConsultingSlide 1.
1 WWW. 2 World Wide Web Major application protocol used on the Internet Simple interface Two concepts –Point –Click.
IS-907 Java EE World Wide Web - Overview. World Wide Web - History Tim Berners-Lee, CERN, 1990 Enable researchers to share information: Remote Access.
2: Application Layer 1 Chapter 2: Application layer r 2.1 Principles of network applications  app architectures  app requirements r 2.2 Web and HTTP.
CITA 310 Section 2 HTTP (Selected Topics from Textbook Chapter 6)
The Basics of HTTP Jason Dean
Web Server Design Week 13 Old Dominion University Department of Computer Science CS 495/595 Spring 2010 Martin Klein 4/7/10.
HTTP Here, we examine the hypertext transfer protocol (http) – originally introduced around 1990 but not standardized until 1997 (version 1.0) – protocol.
8 Chapter Eight Server-side Scripts. 8 Chapter Objectives Create dynamic Web pages that retrieve and display database data using Active Server Pages Process.
CS 6401 The World Wide Web Outline Background Structure Protocols.
242/102/49 0/51/59 181/172/166 Primary colors 248/152/29 PMS 172 PMS 137 PMS 546 PMS /206/ /227/ /129/123 Secondary colors 114/181/204.
More than one site? Use multiple configuration files Use multiple configuration files  httpd –d {path}  Assumes “conf/httpd.conf” Logging transactions.
Overview of Servlets and JSP
Session 11: Cookies, Sessions ans Security iNET Academy Open Source Web Development.
Simple Web Services. Internet Basics The Internet is based on a communication protocol named TCP (Transmission Control Protocol) TCP allows programs running.
Web Programming Week 1 Old Dominion University Department of Computer Science CS 418/518 Fall 2007 Michael L. Nelson 8/27/07.
What’s Really Happening
National College of Science & Information Technology.
* Web Servers/Clients * The HTTP Protocol
Hypertext Transfer Protocol
Web Basics: HTML and HTTP
CS320 Web and Internet Programming Generating HTTP Responses
Hypertext Transfer Protocol
Content from Python Docs.
HTTP – An overview.
Hypertext Transfer Protocol
Web Development Web Servers.
Authentication & .htaccess
Data Virtualization Tutorial… CORS and CIS
Hypertext Transport Protocol
Next Generation SSIS Tasks and data Connection Series
HTTP Protocol.
Tutorial (4): HTTP Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display.
IS333D: MULTI-TIER APPLICATION DEVELOPMENT
WEB API.
Client side & Server side scripting
Web Server Design Week 15 Old Dominion University
While the audience is gathering. During breaks etc
Kevin Harville Source: Webmaster in a Nutshell, O'Rielly Books
The HTTP Protocol COSC 2206 Internet Tools The HTTP Protocol

Web Server Design Week 14 Old Dominion University
* Web Servers/Clients * The HTTP Protocol
Presentation transcript:

Requests and Server Response Codes

Part I - Requests

Two Main Request Types GET POST Every file is requested by the client using one of these methods.

Less Common Request Methods HEAD Like GET, but only returns the header portion. Useful to verify the document exists. PUT Used to publish documents to the Web. DELETE Deletes the document

Comparing GET and POST GET appears in the URL (URI). GET is limited in size. Don’t go over 1000 characters in your URI. GET can refresh the same page, because the request includes the name value pairs GET shows passwords in plain sight in the request.

Comparing GET and POST POST sends form information separately, so refreshing the page may be unsuccessful if the info was not cached. POST can send more form information

URL Encoding Sometimes you will see strange symbols up in your URL. Those are URL Encoded symbols matching common characters such as a space or ampersand. That way the request won’t end up confusing the server or client. My.cgi?example=Kevin%20Harville For instance, your form input may include an ampersand, equals, or slash. These things have meanings that may cause errors unless interpreted correctly.

Part II - Responses

Overview We are used to seeing 403 and 404 errors, indicating “forbidden” and “not found” respectively. EVERY time the server is requested to serve a file it gives a response code. The code is given in the response header.

The Most Common Response The most common response code is 200, meaning the client’s request was successful. Your header may begin as follows: HTTP/1.1 200 OK Date: Monday, 12-March-01 17:45:91 GMT …..

Response Code Summary 100-199 Informational 200-299 Request Successful 300-399 Redirected. Further Action Necessary. 400-499 Client Error 500-599 Server Error

Common 400 Errors 400 Bad Request 401 Unauthorized 403 Forbidden 404 Not Found 405 Method Not Allowed 408 Request Time-out

400 There was a syntax error in the request

401 The request lacked proper authorization.

403 Forbidden We commonly get this on Gaia when we forget to set our permissions.

404 The infamous “Not Found” Error. The file does not exist.

408 The request timed-out due to client side error.

500 Errors 500 Internal Server Error This indicates that a part of the server (for example, a CGI or ASP program) has crashed or encountered a configuration error.

Custom Error Pages Perhaps you have seen custom error pages. To see one you may wish to type in a URL for a document that does not exist. A major site will respond with a custom error page for 404 errors. This page can be just like any other page. You can configure Apache, IIS, or most other servers to serve custom error pages in response to specific errors.