>>> Andy Mayer <[EMAIL PROTECTED]> 20-Jul-00 9:28:03 AM >>>

>I guess the HTTP headers will be encoded somehow in the
>CGI header that is passed to the Servlet, and it is this raw
>data I want to see.

1. it's called the HTTP header - not the CGI header
CGI is an application startup protocol, not a transmission protocol.


>As for the format of the raw, I don't know. Maybe somebody
>could give us some pointers to help learn the basics of
>CGI/HTTP  etc etc...??

See many previous posts of mine (and others). HTTP is a very simple
protocol - it's just ascii character data, eg: here is a request:

  GET /somedirectory/somefile.html HTTP/1.1
  Host: someserver:8000
  Accept: image/jpeg image/gif text/html *
  CRLF

where CRLF is a carriage-return followed by a line-feed (ascii 10-13
I think, perhaps the other way round I can never remember).


>Apologies for this basic question, but it seems crucial to
>understanding the Servlet Technology.

A servlet cannot examine the HTTP headers that are transmitted - the
servlet container (or servlet engine) has already read them and put
them in the Enumeration.

Since doing what you want to do is rare it's better that the
container read the header (otherwise all servlets would have to read
the header all the time whoch would be silly).

There is also stuff in the header which is relevant to the container
only, for example: persistent connection notification stuff. If the
container didn't read the header it wouldn't be able to act on this.


The solution to your problem is to get a packet sniffer and place it
between your client and your server. You will be able to see the
request being made in clear ascii.


Nic Ferrier

___________________________________________________________________________
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff SERVLET-INTEREST".

Archives: http://archives.java.sun.com/archives/servlet-interest.html
Resources: http://java.sun.com/products/servlet/external-resources.html
LISTSERV Help: http://www.lsoft.com/manuals/user/user.html

Reply via email to