Examples of HTTP 1.0 Requests and Responses

This section provides some tutorial examples of HTTP 1.0 requests and responses. Google and Wikipedia are still supporting HTTP 1.0 protocols.

Let's continue to try my Perl socket test program to send a simple HTTP 1.0 request to some other Web servers.

www.wikipedia.org likes my HTTP 1.0 request and I received a good HTTP 1.0 response:

\herong>SocketRequestResponse.pl www.wikipedia.org 80 http_get.req

\herong>type http_get.res
HTTP/1.0 200 OK
Date: ... 2009
Server: Apache
Cache-Control: s-maxage=3600, must-revalidate, max-age=0
Last-Modified: Tue, 21 Jul 2009 23:54:41 GMT
Vary: Accept-Encoding
Content-Length: 6091
Content-Type: text/html; charset=utf-8
X-Cache: HIT from sq39.wikimedia.org
X-Cache-Lookup: HIT from sq39.wikimedia.org:3128
Age: 195
X-Cache: HIT from eiximenis.wikimedia.org
X-Cache-Lookup: HIT from eiximenis.wikimedia.org:80
Connection: close

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://w...
<!-- Sysops: Please do not edit the main template directly; update...
<html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en"
  <meta http-equiv="Content-Type" content="text/html; charset=utf-...
  <meta http-equiv="Content-Language" content="en" />
  <meta http-equiv="Content-Style-Type" content="text/css" />

www.apache.org accepted my HTTP 1.0 request. But it delivered a good HTTP 1.1 response back to me:

\herong>SocketRequestResponse.pl www.apache.org 80 http_get.req

\herong>type http_get.res
HTTP/1.1 200 OK
Date: ... 2009
Server: Apache/2.3.4 (Unix) mod_ssl/2.3.4 OpenSSL/0.9.7d mod_fcgid...
Last-Modified: Wed, 23 Dec 2009 14:11:41 GMT
ETag: "cb717d-6bcc-47b65e6cdc140"
Accept-Ranges: bytes
Content-Length: 27596
Cache-Control: max-age=86400
Expires: ... 2009
Vary: Accept-Encoding
Connection: close
Content-Type: text/html

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" ...
  Licensed to the Apache Software Foundation (ASF) under one
  or more contributor license agreements.  See the NOTICE file
<html xmlns="http://www.w3.org/1999/xhtml">

My HTTP 1.0 worked nicely on www.google.com:

\herong>SocketRequestResponse.pl www.google.com 80 http_get.req

\herong>type http_get.res
HTTP/1.0 200 OK
Date: ... 2009
Expires: -1
Cache-Control: private, max-age=0
Content-Type: text/html; charset=ISO-8859-1
Set-Cookie: PREF=ID=36f1760e936ac4ea:TM=1262399916:LM=1262399916:S...
Set-Cookie: NID=30=s9IcPpepJ8gkHjNmrV2IpOLgLfkus6sGG6F8TYxx7sNx5tX...
Server: gws
X-XSS-Protection: 0

<!doctype html><html><head><meta http-equiv="content-type" content...
var _gjwl=location;function _gjuc(){var e=_gjwl.href.indexOf("#");...
window._gjp && _gjp()</script><style>td{line-height:.8em;}.gac_m t...
function a(){google.timers.load.t.ol=(new Date).getTime();google.r...

Last update: 2009.

Table of Contents

 About This Book

 Introduction to Web Service

 Introduction to SOAP (Simple Object Access Protocol)

 SOAP Message Structure

 SOAP Message Transmission and Processing

 SOAP Data Model

 SOAP Encoding

 SOAP RPC Presentation

 SOAP Properties Model

 SOAP Message Exchange Patterns

 SOAP HTTP Binding

 SOAP Perl Implementations

 SOAP PHP Implementations

 SOAP Java Implementations

 Perl SOAP::Lite - SOAP Server-Client Communication Module

Perl Socket Test Program for HTTP and SOAP

 SocketRequestResponse.pl - Socket Level Testing Program

Examples of HTTP 1.0 Requests and Responses

 Examples of HTTP 1.1 Requests and Responses

 SOAP 1.1 Request - Content-Length Too Small

 SOAP 1.1 Request - Content-Length Too Large

 SOAP 1.1 Request and Response of GetSpeech

 SOAP 1.2 Request and Response of GetSpeech

 Perl SOAP::Lite for GetSpeech SOAP 1.1 Web Service

 Perl SOAP::Lite 0.710 for SOAP 1.2 Web Services

 Perl SOAP::Lite 0.710 for WSDL

 PHP SOAP Extension Client Programs

 PHP SOAP Extension Server Programs

 Java Socket and HttpURLConnection for SOAP

 SAAJ - SOAP with Attachments API for Java

 SoapUI - SOAP Web Service Testing Tool

 WS-Security - SOAP Message Security Extension

 WS-Security X.509 Certificate Token

 Web Services and SOAP Terminology


 PDF Printing Version