Required Behavior of SAFs for Each Directive
NameTrans SAFs
•
Purpose: Convert logical URI to physical path
•
Perform operations on logical path (
local file system path.
•
Return
path, or
•
To redirect the client to another site, change
url
Return
PathCheck SAFs
•
Purpose: Check path validity and user's access rights.
•
Check
•
Return
rq->vars
•
If not authorized, insert
as:
HTTP response status to
ObjectType SAFs
•
Purpose: Determine content-type of data.
•
If
•
Determine the MIME type and create
•
Return
Service SAFs
•
Purpose: Generate and send the response to the client.
•
A Service SAF is only called if each of the optional parameters
and
130
Netscape Enterprise Server NSAPI Programmer's Guide • November 2001
if
REQ_PROCEED
REQ_NOACTION
to
with full URL (for example.,
rq->vars
.
REQ_PROCEED
,
auth-type
auth-user
if user (and group) is authorized for this area (
REQ_PROCEED
).
Basic; Realm=\"Our private area\"
in
content-type
rq->srvhdrs
if
REQ_PROCEED
specified in the directive in
query
in
ppath
in
contains the full local file system
ppath
rq->vars
if not.
and/or
auth-group
WWW-Authenticate
. Call
PROTOCOL_UNAUTHORIZED
already exists, return
content-type
is created,
content-type
obj.conf
) to convert it into a full
rq->vars
in
to
ppath
rq->vars
http://home.example.com/
in
rq->vars.
to
with a value such
rq->srvhdrs
protocol_status()
. Return
REQ_ABORTED
REQ_NOACTION
in
rq->srvhdrs
otherwise
REQ_NOACTION
type
match the request.
. Add
/URL
).
in
ppath
to set
.
.
,
,
method