Client connection | Client connects by issuing a request to the port that SRE2003 is listening to | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Check limits and bad IP addresses | SRE2003 makes sure that the server is not too busy, and that the client is not explicitily UNALLOWED | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
SRE2003 "pre-transaction" procedure
Optional procedures | executed by SRE2003 before reading request information (but after the client has established a connection).
SRE2003 | "pre-request" procedure
Optional procedures | executed by SRE2003 after reading request information.
Check request cache
|
Check the SRE2003 request cache for
a useable cached version of this request. If one is found (and returned
to the client), the filter
may be called anyways.
|
The fast-filter
|
Optional small and fast filter
called before SREhttp/2 is invoked.
|
The filter
|
| SREhttp/2 is called.
|
Access control | and selector specific attributes
Selector-specific attributes are
looked up.
| If necessary, client privileges may be compared against required privileges. This can involve sending an authorization response, followed by username lookup.
|
Client-specific attributes
| If a
client advanced-option
has been specified -- then
client privilege information can be used
to modify the failure, redirect, permissions, and the
advanced options
selector-specific attributes.
|
|
Redirection | and other selector attributes
One of the following may be done:
|
The end result is either a modified-selector for internal use, a modified selector to redirect to, or the name of a file to send to the client. However, no actual redirection occurs at this step.
|
SREhttp/2 EXEC | selector- specific procedures
Optional selector-specific procedures
can be called. These may (though they usually do not)
send a response to the client.
| [in which case, skip to SRE2003 "IM" procedures]
|
!Special commands
|
If a !Special command was requested,
process it and return the results.
[in which case, skip to SREhttp/2 post-response procedure]
|
|
Redirection responses
|
If a redirection
(TEMP, MOVE, or NOTIFY)
has been specified,
or appending a trailing /
occured, then redirection occurs now
(before the pre-response procedure).
| [in which case, skip to SREhttp/2 post-response procedure]
|
Literal assignment
|
If literal assignments
was specified, the specified file is sent to the client.
| [in which case, skip to SRE2003 "IM" procedures]. Note: if HTACCESS controls are enabled, check the appropriate HTACCESS file before granting access to this resource.
|
Non-standard methods
|
| Process PUT, DELETE, and other non-standard http requests. If this happens, skip to SREhttp/2 post-response procedure.
|
Create a response | to send to client
|
|
SREhttp/2 | "pre-response" procedure
Given the output from the prior step (and given that a 404 response was
not sent), SREhttp/2 can than apply an
optional pre-response procedure to the contents of
the response.
For example, adding a date
stamp to html documents; or performing on-the-fly content-encoding;
or applying encryption.
| Note that output from !SPECIAL commands, from CGI-BIN scripts, and from many SREhttp/2 addons, will not be modified by pre-response procedures.
|
Send the response | to the client
The output, perhaps as modified by a pre-response procedure, is then
sent to the client. If needed, a
MD5 hash is generated (using this output).
| In technical terms, this is the instance, and will be identified by a unique to this URI etag. Thus, although the contents of the instance may not change, what is actually sent to the client may be the result of further processing, including Instance Manipulation, Range Extraction, and Transfer Encoding.
SRE2003 "IM" procedures | and range responses
Possibly do a range extraction. Also, possibly execute
Instance Manipulation procedures
Instance
manipulation includes sophisticated range extraction, and delta encoding. | Basically, instance manipulation does not change the underlying content of a response (the instance), though it may change the bytes used to represent this content.
On the fly GZIP encoding | as a transfer encoding
If the client (or, a proxy between you and the client) understands
GZIP as transfer encoding, then SRE2003 can
GZIP on-the-fly.
|
Transmit the response
|
The actual bytes of the response, including response header
and response body, are sent by SRE2003. SREhttp/2 can wait for conclusion
of this transmission, or it
can assume that SRE2003 will succeed and
immediately proceed to the next step.
|
|
Auditing and SREhttp/2 "post-response" | procedure
Log information can be written to several common log files.
| A running count of the number of requests, by URI, can also be augmented.
Optional procedure called after a response has
been sent to the client. For example, you can use post-response procedures for
advanced auditing, or send event specific email alerts.
|
Sending a file to a client |
When SREhttp/2 sends a file to a client, several general and selector-specific
parameters are checked. These include:
|
||||||||
Determinine the content-type |
When sending a static file to a client, SREhttp/2 determines the mimetype (which is
then used in a Content-Type response header) in several
steps...
|