Index Next |
iPlanet Web Server, FastTrack Edition NSAPI Programmer's Guide |
Contents
About This BookiPlanet Web Server, FastTrack Edition Overview
Book Summary
Chapter 1 Basics of Server OperationConfiguration Files
magnus.conf
How the Server Handles Requests from Clients
obj.conf
mime.types
HTTP Basics
Using NSAPI to Write New Server Application Functions
Steps in the Request Handling Process
Directives for Handling Requests
Chapter 2 Syntax and Use of obj.confServer Instructions in obj.conf
Summary of the Directives
Object and Client Tags
The Object Tag
Flow of Control in obj.conf
The Client Tag
Init
Syntax Rules for Editing obj.conf
AuthTrans
NameTrans
PathCheck
ObjectType
Service
AddLog
Error
Order of Directives
Examples of obj.conf Directives
Parameters
Case Sensitivity
Separators
Quotes
Spaces
Line Continuation
Path Names
Comments
Chapter 3 Predefined SAFs and the Request Handling ProcessInit Stage
cache-init
AuthTrans Stage
cindex-init
dns-cache-init
flex-init
flex-rotate-init
init-cgi
init-clf
init-uhome
load-modules
load-types
pool-init
register-http-method
thread-pool-init
basic-auth
NameTrans Stage
basic-ncsa
get-sslid
assign-name
PathCheck Stage
document-root
home-page
pfx2dir
redirect
unix-home
cert2user
ObjectType Stage
check-acl
deny-existence
find-index
find-links
find-pathinfo
get-client-cert
load-config
nt-uri-clean
ntcgicheck
require-auth
set-virtual-index
ssl-check
ssl-logout
unix-uri-clean
force-type
Service Stage
set-default-type
shtml-hacktype
type-by-exp
type-by-extension
add-footer
AddLog Stage
add-header
append-trailer
imagemap
index-common
index-simple
key-toosmall
list-dir
make-dir
parse-html
query-handler
remove-dir
remove-file
rename-file
send-cgi
send-file
send-range
send-shellcgi
send-wincgi
upload-file
common-log
Error Stage
flex-log
record-useragent
send-error
Chapter 4 Creating Custom SAFsThe SAF Interface
SAF Parameters
pb (parameter block)
Result Codes
sn (session)
rq (request)
Creating and Using Custom SAFs
Write the Source Code
Overview of NSAPI C Functions
Compile and Link
Load and Initialize the SAF
Instruct the Server to Call the SAFs
Stop and Start the Server
Test the SAF
Parameter Block Manipulation Routines
Required Behavior of SAFs for Each Directive
Protocol Utilities for Service SAFs
Memory Management
File I/O
Network I/O
Threads
Utilities
Init SAFs
CGI to NSAPI Conversion
AuthTrans SAFs
NameTrans SAFs
PathCheck SAFs
ObjectType SAFs
Service SAFs
Error SAFs
AddLog SAFs
Chapter 5 NSAPI Function ReferenceNSAPI Functions (in Alphabetical Order)
CALLOC
cinfo_find
condvar_init
condvar_notify
condvar_terminate
condvar_wait
crit_enter
crit_exit
crit_init
crit_terminate
daemon_atrestart
filebuf_buf2sd
filebuf_close
filebuf_getc
filebuf_open
filebuf_open_nostat
FREE
func_exec
func_find
log_error
magnus_atrestart
MALLOC
net_ip2host
net_read
net_write
netbuf_buf2sd
netbuf_close
netbuf_getc
netbuf_grab
netbuf_open
param_create
param_free
pblock_copy
pblock_create
pblock_dup
pblock_find
pblock_findval
pblock_free
pblock_nninsert
pblock_nvinsert
pblock_pb2env
pblock_pblock2str
pblock_pinsert
pblock_remove
pblock_str2pblock
PERM_CALLOC
PERM_FREE
PERM_MALLOC
PERM_REALLOC
PERM_STRDUP
protocol_dump822
protocol_set_finfo
protocol_start_response
protocol_status
protocol_uri2url
protocol_uri2url_dynamic
REALLOC
request_header
request_stat_path
request_translate_uri
session_maxdns
shexp_casecmp
shexp_cmp
shexp_match
shexp_valid
STRDUP
system_errmsg
system_fclose
system_flock
system_fopenRO
system_fopenRW
system_fopenWA
system_fread
system_fwrite
system_fwrite_atomic
system_gmtime
system_localtime
system_lseek
system_rename
system_ulock
system_unix2local
systhread_attach
systhread_current
systhread_getdata
systhread_newkey
systhread_setdata
systhread_sleep
systhread_start
systhread_terminate
systhread_timerset
util_can_exec
util_chdir2path
util_chdir2path
util_cookie_find
util_env_find
util_env_free
util_env_replace
util_env_str
util_getline
util_hostname
util_is_mozilla
util_is_url
util_itoa
util_later_than
util_sh_escape
util_snprintf
util_sprintf
util_strcasecmp
util_strftime
util_strncasecmp
util_uri_escape
util_uri_is_evil
util_uri_parse
util_uri_unescape
util_vsnprintf
util_vsprintf
Chapter 6 Examples of Custom SAFsExamples in the Build
AuthTrans Example
Installing the Example
NameTrans Example
Source Code
Installing the Example
PathCheck Example
Source Code
Installing the Example
ObjectType Example
Source Code
Installing the Example
Service Example
Source Code
Installing the Example
AddLog Example
Source Code
More Complex Service Example
Installing the Example
Source Code
Appendix A Data Structure ReferencePrivatization of Some Data Structures
session
pblock
pb_entry
pb_param
Session->client
request
stat
shmem_s
cinfo
Appendix B Variables in magnus.confServer Information
Address
Object Configuration File
Concurrency
MtaHost
Port
ServerID
ServerName
ServerRoot
User
VirtualServerFile
LoadObjects
Language Issues
RootObject
AcceptLanguage
DNS Lookup
AdminLanguage
ClientLanguage
DefaultLanguage
AsyncDNS
Threads, Processes and Connections
DNS
BlockingListenSockets
Native Thread Pools
KeepAliveTimeout
KernelThreads
ListenQ
MaxKeepAliveConnections
MaxProcs
PostThreadsEarly
RcvBufSize
RqThrottle
RqThrottleMinPerSocket
SndBufSize
StackSize
StrictHttpHeaders
TerminateTimeout
NativePoolStackSize
CGI
NativePoolMaxThreads
NativePoolMinThreads
NativePoolQueueSize
CGIExpirationTimeout
Error Logging and Statistic Collection
CGIWaitPid (UNIX Only)
ErrorLog
ACL
LogFlushInterval
LogVerbose
PidLog
ACLFile
Security
Chroot (Unix only)
Chunked Encoding
Ciphers
Security
ServerCert
ServerKey
SSLCacheEntries
SSLClientAuth
SSLSessionTimeout
SSL2
SSL3
SSL3Ciphers
SSL3SessionTimeout
UseOutputStreamSize
Miscellaneous
flushTimer
ChunkedRequestBufferSize
ChunkedRequestTimeout
Umask (UNIX only)
Appendix C MIME TypesIntroduction
Loading the MIME Types File
Determining the MIME Type
How the Type Affects the Response
What Does the Client Do with the MIME Type?
Syntax of the MIME Types File
Sample MIME Types File
Appendix D Wildcard PatternsWildcard Patterns
Wildcard Examples
Appendix E Time Formats
Appendix F Server-Parsed HTML TagsUsing Server-Parsed Commands
config
include
echo
fsize
flastmod
exec
Environment Variables in Commands
Appendix G HyperText Transfer ProtocolCompliance
Requests
Request Method, URI, and Protocol Version
Responses
Request Headers
Request Data
HTTP Protocol Version, Status Code, and Reason Phrase
Buffered Streams
Response Headers
Response Data
Appendix H Alphabetical List of NSAPI Functions and Macros
Appendix I Alphabetical List of Directives in magnus.conf
Appendix J Alphabetical List of Pre-defined SAFs
Index
Index Next
Copyright © 2000 Sun Microsystems, Inc. Some preexisting portions Copyright © 2000 Netscape Communications Corp. All rights reserved.
Last Updated July 20, 2000