Writing Web Applications With WAI: Netscape Enterprise Server/FastTrack Server, Version 3.0/3.01

[Previous] [Contents]

Index

Numerics

301 status code 91
302 status code 91
404 status code 89

A

ActivateWAS method of WAIWebApplicationService 158
Add method of FormHandler class 165
addResponseHeader 91
addResponseHeader method of ServerRequest 116
AIX, C++ libraries 41
applications
compiling 39
running 42
AUTH_TYPE
getting value of 128

B

base classes
WAIWebApplicationService 114
before you begin 29
bold fonts
used in this book iii
BuildURL method of ServerRequest 118

C

C
initialization 98
WAI interface 8
C applications
defining functions to process requests 48
getting and setting cookies 51
getting data 48
getting headers 49
getting server information 50
redirecting users to another page 53
registering with a web server 55
registering with an SSL-enabled web service 57
running your web service 58
sending response 52
sending responses back to client 51
setting headers in a response 52
setting status of the response 52
C functions in WAI 110
summary of 58
WAIaddResponseHeader 110
WAIBuildURL 110
WAIcreateWebAppService 110
WAIdeleteService 110
WAIdelResponseHeader 110
WAIgetConfigParameter 110
WAIgetCookie 110
WAIgetHost 110
WAIgetInfo 111
WAIgetPort 111
WAIgetRequestHeader 111
WAIgetRequestInfo 111
WAIgetResponseContentLength 111
WAIgetResponseHeader 111
WAIgetServerSoftware 111
WAIimplIsReady 111
WAIisSecure 111
WAILogError 111
WAIReadClient 111
WAIregisterService 111
WAIRespondRedirect 112
WAIsetCookie 112
WAIsetRequestInfo 112
WAIsetResponseContentLength 112
WAIsetResponseContentType 112
WAIsetResponseStatus 112
WAIStartResponse 112
WAIstringFree 112
WAIWriteClient 112
C++
classes for naming services 169
compile flags 41
compiling applications 39
examples
FormHandler 23
WASP 15
include directories 39
libraries 40
AIX 41
Digital UNIX 41
HP-UX 41
IRIX 40
Solaris 40
Windows NT 40
requirements 27
IRIX 28
Solaris 28
Windows NT 28
running web service 80
WAI interface 8
C_r 41
CGI
converting to WAI 30
changes
to obj.conf file 35
changing
ORB configuration 36
CIIOP application 12
classes
FormHandler example 23
CLASSPATH
Java 42, 82
client
reading data from 136
writing data to 149
CLIENT_CERT
getting value of 128
Common Object Request Broker Architecture (see CORBA) 6
compile flags
C++ 41
compiling 39
applications
C++ 39
C++
compile flags 41
C/C++ server plug-ins 42
include directories
C++ 39
Java applications 42
libraries
C++ 40
configuring
IIOPinit parameters 36
ORB
example 38
WAI server 34
web server 100
web server for IIOP 105
web server's ORB 36
constructors
FormHandler 162
content type
setting 144, 146
CONTENT_LENGTH
getting value of 128
CONTENT_TYPE
getting value of 128
Content-length 89
converting CGI to WAI 30
cookie
constructing and sending to client 141
cookies
getting
C applications 51
C++ 72
Java 88
setting
C applications 51
C++ 72
Java 88
CORBA
understanding 6

D

data
from a request 48
getting reqest 69
getting requst 84
headers 49
server information 50
dce.sl 41
dcepthreads 41
declaring
a web service class 67
defining
method to process requests 68, 84
defining functions
C applications 48
Delete method of FormHandler class 165
delResponseHeader method of ServerRequest 119
Digital UNIX
C++ libraries 41
DISABLE_ORB_LOCATOR 45

E

editing
obj.conf 45
enabling
IIOP connections 105
WAI 34
enabling WAI
changes to obj.conf 35
environment variables
Java
CLASSPATH 42, 82
errors
Invalid Stringified Object Reference 186
logging 133
Server Error 185
WAI Application Not Found 183
example applications
running the Java sample 19
Examples 11
examples
C++
WASP 15
configuring the ORB 38
FormHandler
C++ 23
Java 25
FormHandler class 23
running a C application 12
running sample applications 11
running the sample C++ application 15
running the sample Java application 19

F

finding
application 101
IOR file 57, 79
flags
UNIX
-R on Solaris 42
-rpath on IRIX 42
fonts
bold, used in this book iii
italics, used in this book iii
monospaced, used in this book ii
FormHandler 161
examples
C++ 23
compiling C++ 24
Java 25
FormHandler base class methods 109
FormHandler constructor 162
FormHandler example 23
FormHandler member summary 162
FormHandler methods
Add 165
Delete 165
Get 164
GetHashTable 167
GetQueryString 163
InitIterator 166
IsValid 163
ParseQueryString 164
forms
handling data 22
function
writing an initialization 98

G

GATEWAY_INTERFACE
getting value of 153
Get method of FormHandler 164
getConfigParameter method of ServerRequest 121
getContext method of ServerRequest 123
getCookie method of ServerRequest 124
GetHashTable method of FormHandler class 167
getHost method of ServerContext 151
getInfo 86
getInfo method of ServerContext 152
getInfo variables
GATEWAY_INTERFACE 153
HTTPS 153
SERVER_ID 153
SERVER_NAME 153
SERVER_PORT 153
SERVER_SOFTWARE 153
getName method of ServerContext 153
getPort 87
getPort method of ServerContext 154
GetQueryString method of FormHandler 163
getRequestHeader 84
getRequestHeader method of ServerRequest 125
getRequestInfo 85
getRequestInfo method of ServerRequest 127
getRequestInfo variables
AUTH_TYPE 128
CLIENT_CERT 128
CONTENT_LENGTH 128
CONTENT_TYPE 128
HOST 128
HTTP_* header 128
HTTPS 128
HTTPS_KEYSIZE 128
HTTPS_SECRETKEYSIZE 128
PATH_INFO 128
PATH_TRANSLATED 128
QUERY 129
QUERY_STRING 129
REMOTE_ADDR 129
REMOTE_HOST 129
REMOTE_USER 129
REQUEST_METHOD 129
SCRIPT_NAME 129
SERVER_PROTOCOL 129
URI 129
getResponseContentLength method of ServerRequest 130
getResponseHeader method of ServerRequest 132
getRootNaming 176
getRootNaming, method of NameUtil 176, 177
getServerSoftware method of ServerContext 154
getServiceInfo 77, 83, 92
getServiceInfo method in WAIWebApplicationService base class 68
getServiceInfo method of WAIWebApplicationService 158
getting
cookies
C++ 72
Java 88
request data 69, 84
request headers 69, 84
server information 70, 86
getting data
C applications 48
getting headers
C applications 49
getting server information
C applications 50
guidelines
security 101, 103

H

header
adding to a response 116
deleting from a response 119
getting from request 125
obtaining from response 132
headers
getting request 69, 84
setting 73
setting in a response 52
Hello World 90
HOST
getting value of 128
hostname
getting 151
HP-UX
C++
libraries 41
HTTP_* header
getting value of 128
HTTPS
getting value of 128, 153
HTTPS_KEYSIZE
getting value of 128
HTTPS_SECRETKEYSIZE
getting value of 128
HttpServerContext 113
HttpServerContext interface 150
HTTPServerContext interface methods 108
HttpServerRequest 113, 114
HttpServerRequest interface member summary 115
HTTPServerRequest interface methods 107

I

IDL 6
understanding 7
WAI interface 8
IIOP, enabling 105
IIOPinit
parameters 37
IIOPsec 41
IIOPsec.sl 41
IIOPsec.so 41
include files
Java 42
information
providing service 77, 92
initialization
C 98
InitIterator 24
InitIterator method of FormHandler class 166
Interface Definition Language (see IDL) 6, 7
interfaces
HttpServerContext 113
HttpServerRequest 113
WAIWebApplicationService base class 114
WebApplicationBasicService 113
WebApplicationService 113
intialization function, writing 98
IOR file
finding 57, 79
IRIX
C++
libraries 40
-rpath flag 42
isSecure method of ServerContext 155
IsValid method of FormHandler 163
italics font
used in this book iii

J

Java
classes for naming services 174
examples
FormHandler 25
obj.conf 45
registering with a web server 94
requirements 28
JDK 28
Visual Café 28
using osagent 45
WAI interface 8
JavaWASP application 19

L

lcache10.so 41
ldap10.so 41
libIIOPsec.a 40
liblcache10.so 40
libldap10.so 40
libnsl.so 40
libnspr.so 40
libONEiiop.so 40
liborb_r.so 40
libposix4.so 40
libraries
C++
Digital UNIX 41
HP-UX 41
IRIX 40
Solaris 40
Windows NT 40
C++ AIX 41
libresolv.so 40
libthread.so 40
listimpl 187
listing
configurable IIOPinit parameters 36
LogError method of ServerRequest 133
logging
status messages 39
logging errors 133

M

method
defining 68
definint 84
methods
FormHandler base class 109
HTTPServerContext interface 108
HttpServerRequest 115
HTTPServerRequest interface 107
WAIWebApplicationService base class 109
monospaced fonts
used in this book ii

N

NameFromString, method of NameUtil 176, 177
NameUtil 176
NameUtil.hpp 169
Naming 174
naming services 169
C++ classes 169
java classes 174
netscape.WAI.HttpServerRequest 84, 85
netscape.WAI.NameUtil 176
netscape.WAI.Naming 174
Next 24
Next method of FormHandler class
FormHandler methods
Next 166
nisb.zip 82
NS_SERVER_ROOT 57, 79
nshttpd.sl 41
ns-httpd.so 40, 41
nshttpd_shr 41
nspr_shr 41
NVPair 23

O

OAD 42
LD_LIBRARY_PATH 44
NS_SERVER_ID 43
NS_SERVER_ROOT 43
ORBELINE_IMPL_NAME 43
ORBELINE_IMPL_PATH 44
setting up your application 42
OAport 45
obj.conf
changes 35
editing 45
object activation daemon (see OAD) 42
Object Management Group (see OMG) 7
Object Request Broker (see ORB) 6
OMG 7
ONEiiop.sl 41
ONEiiop.so 41
ONEiiop_shr 41
ONEiiop10.lib 40
options
enabling WAI 34
ORB 6
changing configuration 36
configuring 36
example 38
orb_r 41
orb_r.sl 41
orb_r.so 41
osagent
running 106
starting 34
troubleshooting 186
listimpl 187
unregobj 188
with Java 45
overview
of WAI 28
overview of this manual i

P

parameters
configurable IIOPinit 36
IIOPinit 37
ParseQueryString method of FormHandler 164
PATH_INFO
getting value of 128
PATH_TRANSLATED
getting value of 128
permissions
write 104
plug-in
writing WAI server 97
plug-ins
compiling 39
port number
getting 154
preprocessor definitions 66
processing requests 68, 84
C applications 48
project settings 66
prototype
C 113
C++ 113
Java 113
providing
service information 77, 92
putContext 173
putObject 173

Q

QUERY
getting value of 129
QUERY_STRING
getting value of 129

R

ReadClient method of ServerRequest 136
reading data from client 136
redirecting
users to another page 75
redirecting users to another page 91
C applications 53
reference, how to use 112
register, method of Naming 175
registering
web application service
C applications 55
with a web server
C applications web server

registering with 55

web server registering with 94

with an SSL-enabled web service
C applications 57
registering with a web server
Java 94
registerObject 172
registerObject, method of NameUtil 176, 177
RegisterService 79
RegisterService method of WAIWebApplicationService 159
registerWAS 170
registerWAS, method of NameUtil 176, 179
remote machines
running on 46
REMOTE_ADDR
getting value of 129
REMOTE_HOST
getting value of 129
REMOTE_USER
getting value of 129
request
getting information about 127
getting length of response content 130
request data
getting 84
REQUEST_METHOD
getting value of 129
requirements
C++ 27
IRIX 28
Solaris 28
Windows NT 28
Java 28
JDK 28
Visual Café 28
system 27
resolve, method of Naming 175
resolveURI 170, 171
resolveURI, method of NameUtil 176, 180
resolveWAS 170, 171
RespondRedirect method of ServerRequest 140
response
sending 52, 148
sending back 88
sending one back to the client 51
sending to client 73
setting content length 144
setting content type 146
setting headers 52
setting status 52, 74
setting status code 146
restricting login access 103
Run 83
Run method in WAIWebApplicationService base class 68
Run method of WebApplicationBasicService 159
running
applications 42
C++ web service 80
on remote machines 46
web service
C applications 58
java 96

S

sample applications
C++ 15
running 11
running the C sample 12
samples
running the Java application 19
SCRIPT_NAME
getting value of 129
security
osagent 104
potential concerns 102
recommended guidelines 103
replace web service 102
security guidelines 101
security issue
understanding 29
sending
a response 73
response 88
Java response

sending

Java 90

sending response
C applications 52
to client 51
server
finding application 101
getting information 70
getting name and version of software 154
getting value associated with name in 152
server id
retrieving 153
server information
getting 86
server plug-in
writing 97
server plug-ins
compiling
C/C++ 42
server software
getting name and version of 154
SERVER_ID
getting value of 153
SERVER_NAME
getting value of 153
SERVER_PORT 86
getting value of 153
SERVER_PROTOCOL
getting value of 129
SERVER_SOFTWARE
getting value of 153
ServerContext methods
getHost 151
getInfo 152
getName 153
getPort 154
getServerSoftware 154
isSecure 155
ServerRequest methods
addResponseHeader 116
BuildURL 118
delResponseHeader 119
getConfigParameter 121
getContext 123
getCookie 124
getRequestHeader 125
getRequestInfo 127
getResponseContentLength 130
getResponseHeader 132
LogError 133
ReadClient 136
RespondRedirect 140
setCookie 141
setRequestInfo 144
setResponseContentLength 144
setResponseContentType 146
SetResponseStatus 146
StartResponse 148
WriteClient 149
services
naming 169
setCookie method of ServerRequest 141
setRequestInfo method of ServerRequest 144
setResponseContentLength 74, 89
setResponseContentLength method of ServerRequest 144
setResponseContentType 74, 89
setResponseContentType method of ServerRequest 146
setResponseStatus 91
setResponseStatus method of ServerRequest 146
setting
cookies 72
Java 88
headers 73
headers in a response 52
option to enable WAI 34
response status 74
up the web server 33
setting status of response 52
setting up
Visual C++ 64
signatures, of WAI methods 107
Solaris
C++
libraries 40
-R flag 42
SSL
determining if enabled 155
starting
osagent 34
StartResponse 91
StartResponse method of ServerRequest 148
status
setting response 74
status codes
301 91
302 91
404 89
status messages
logging 39
StringAlloc method of WAIWebApplicationService 160
StringDelete method of WAIWebApplicationService 160
StringDup 77
StringDup method of WAIWebApplicationService 161
syntax
WAI methods 113
system requirements 27

T

troubleshootin 183
troubleshooting
osagent
listimpl 187
unregobj 188

U

understanding
security issues 29
version differences 5, 30
unregobj 188
URI
getting value of 129
URL
creating from prefix and suffix 118
using
osagent
with Java 45
the reference section 112
WAI 27

V

version differences
understanding 5, 30
vertical bar
used in this book iii
Visual C++
preprocessor definitions 66
setting up 64

W

WAI 5
C functions 110
configuring the server 34
converting CGI 30
enabling 34
methods
syntax 113
overview 28
security guidelines 101
using 27
wrapper classes 7
writing C++ application 63
WAI interface
C 8
C++ 8
IDL 8
Java 8
WAI.zip 82
WAIaddResponseHeader 110
WAIBuildURL 110
WAIcreateWebAppService 110
WAIdeleteService 110
WAIdelResponseHeader 110
WAIgetConfigParameter 110
WAIgetCookie 110
WAIgetHost 110
WAIgetInfo 111
WAIgetName
C functions in WAI
WAIgetName 111
WAIgetPort 111
WAIgetRequestHeader 111
WAIgetRequestInfo 111
WAIgetResponseContentLength 111
WAIgetResponseHeader 111
WAIgetServerSoftware 111
WAIimplIsReady 111
WAIisSecure 111
WAILogError 111
WAIReadClient 111
WAIregisterService 111
registering with an SSL-enabled server 57
WAIRespondRedirect 112
WAIRunFunction
C functions in WAI
*WAIRunFunction 112
WAIsetCookie 112
WAIsetRequestInfo 112
WAIsetResponseContentLength 112
WAIsetResponseContentType 112
WAIsetResponseStatus 112
WAIStartResponse 112
WAIstringFree 112
WAIWebApplication methods
getServiceInfo 68
WAIWebApplicationService 77, 82, 92, 114
declaring a class 82
virtual methods 68
WAIWebApplicationService base class 156
WAIWebApplicationService base class methods 109
WAIWebApplicationService methods
ActivateWAS 158
getServiceInfo 158
RegisterService 159
Run 68, 159
StringAlloc 160
StringDelete 160
StringDup 161
WAIWriteClient 112
WASP sample application 15
Web Application Interface (see WAI) 5
web application services 8
web applicaton service
registering
C applications 55
web server
configuring 100
configuring ORB 36
setting it up 33
web service
declaring a class 67
running
java 96
WebApplicationBasicService 113
WebApplicationService 113
WebApplicationServicePrototype 77, 78, 92
Windows NT
C++
libraries 40
wrapper classes 7
write permissions 104
WriteClient 90
WriteClient method of ServerRequest 149
writing
in C++ 63
initialization function 98
WAI server plug-in 97
WSOCK32.lib 40

X

XP_WIN32 66


[Previous] [Contents]

Last Updated: 12/04/97 16:13:20


Copyright © 1997 Netscape Communications Corporation

Any sample code included above is provided for your use on an "AS IS" basis, under the Netscape License Agreement - Terms of Use