![Netscape ENTERPRISE SERVER 6.1 Manual Download Page 116](http://html1.mh-extra.com/html/netscape/enterprise-server-6-1/enterprise-server-6-1_manual_1674653116.webp)
The SAF Interface
116
Netscape Enterprise Server NSAPI Programmer’s Guide • April 2002 (Draft)
The SAF Interface
All SAFs (custom and built-in) have the same C interface regardless of the
request-handling step for which they are written. They are small functions
designed for a specific purpose within a specific request-response step. They
receive parameters from the directive that invokes them in the
obj.conf
file, from
the server, and from previous SAFs.
Here is the C interface for a SAF:
int function(pblock *pb, Session *sn, Request *rq);
The next section discusses the parameters in detail.
The SAF returns a result code which indicates whether and how it succeeded. The
server uses the result code from each function to determine how to proceed with
processing the request. See the section “Result Codes,” on page 119 for details of
the result codes.
SAF Parameters
This section discusses the SAF parameters in detail. The parameters are:
•
pb (parameter block)
-- contains the parameters from the directive that
invokes the SAF in the
obj.conf
file.
•
sn (session)
-- contains information relating to a single TCP/IP session.
•
rq (request)
-- contains information relating to the current request.
pb (parameter block)
The
pb
parameter is a pointer to a
pblock
data structure that contains values
specified by the directive that invokes the SAF. A
pblock
data structure contains a
series of name/value pairs.
For example, a directive that invokes the
basic-nsca
function might look like:
AuthTrans fn=basic-ncsa auth-type=basic
dbm=/netscape/servers/userdb/rs
Summary of Contents for ENTERPRISE SERVER 6.1
Page 1: ...NSAPI Programmer s Guide Netscape Enterprise Server Version6 1 April 2002 Draft...
Page 290: ...Miscellaneous 290 Netscape Enterprise Server NSAPI Programmer s Guide April 2002 Draft...
Page 318: ...cinfo 318 Netscape Enterprise Server NSAPI Programmer s Guide April 2002 Draft...
Page 336: ...Buffered Streams 336 Netscape Enterprise Server NSAPI Programmer s Guide April 2002 Draft...
Page 344: ...344 Netscape Enterprise Server NSAPI Programmer s Guide April 2002 Draft...
Page 350: ...350 Netscape Enterprise Server NSAPI Programmer s Guide April 2002 Draft...
Page 356: ...356 Netscape Enterprise Server NSAPI Programmer s Guide April 2002 Draft...