naficgi: HTTP Server Example Application

The files in this directory make up an example HTTP Server
application using the File System and External CGI features in the
Advanced Web Server Library.

The application consists of a single task ('ROOT') which starts the
Advanced Web Server and then suspends itself.  This application
demonstrates the External CGI and File System Stub features of the
Advanced Web Server.  The HTML files in this directory contain the
source for a set of web pages.  The PBUILDER Utility was used to
convert these web pages into C files.  These C files are built into
the application to create a web server.

The web server demonstrates how to upload data from an HTML form (RFC
1867) to the web server, and how to read data from the server using
ExternalCGI and by means of a file system.


Note: Only files with the following extensions are accepted by the
External CGI: *.txt, *.jpg, *.html and *.gif.


All application results are observed using a web browser (e.g.,
Netscape, Internet Explorer).

One GNU make file is provided.  Build the target 'image' to
generate an image that can be debugged with gdb, and the file 
image.bin which can be written to flash if the bootloader is used.
Build the target 'rom.bin' to create the file rom.bin which 
can be written to ROM if the bootloader is not used.

The following files are provided with this application:

appconf.h         sets application configuration settings
makefile          Make file for the GNU toolset.
readme            this file
root.c            contains applicationStart() function, that creates an
                  application thread
cgi.c             contains application specific CGI stub functions
file.c            contains application specific file stub functions

The following files are generic stubs required by all applications that
use and include the AWS (librphttpd.a) library.  These files are located
in directory .\..\..\..\src\rphttpd\:

security.c      contains the generic stubs used for no security
                requirements

The following files are input/outputs to/from the pbuilder tool,
and are contained in the pbuilder directory:

list.bat        file listing as parameter to pbuilder tool
fileandcgi_v.c  stub file with fleshed out bodies (initially generated
                by the PBUILDER Utility, naked stub originally located
                in the pbuilder\html directory)
pbsetup.txt     PBUILDER Utility options file (do not alter)
rppages.c       PBUILDER Utility output file containing all the
                application Web pages defined in List.bat
rpusrdct.h      PBUILDER Utility output file containing phrase
                dictionary prototypes
rpusrdct.c      PBUILDER Utility output file containing phrase
                dictionary data structures
rpusrdct.txt    PBUILDER Utility input file containing phrase
                dictionary definitions

The following Web content files are contained in the pbuilder\html
directory:

fileandcgi.c    source file generated by PBUILDER Utility
fileandcgi.htm  opening Web Page
formreply.htm   reply page from Form page

In addition, the following files in the BSP directory are built
as part of this application:

reset.s         contains the reset code
appconf_api.c   contains run time access to the application configuration

The application build file links in the following libraries:

libbsp.a           		contains the BSP code
libtcpip.a         		contains the Net+Works TCP/IP stack
libtx.a            		contains the ThreadX kernel
libfilesys.a       		contains the file system libraries
libposix.a         		contains the POSIX layer libraries
libflash.a         		contains the Flash driver API library
libtelnsvr.a       		contains the Telnet server library
libaddp.a		   		contains the ADDP Library
libssh.a		   		contains the SSH Library
librphttpd.a       		contains the NET+Works AWS API library.
libmanapi.a        		contains the NET+Works Management API library.
libdnsclnt.a            contains the DNS Client library
libpppintf.a		    contains the PPP Interface Library

The application uses the following files located in the
netos\src\linkerScripts directory.  These files are generated
when the BSP is built.

bootldr.dat     bootloader configuration file used to generate the
                file image.bin.  It controls the information placed
                in the bootloader header of the image.

image.ldr       GNU linker script used to build an image that can
                be debugged and used with the bootloader.
                
customize.ldr   Customizable GNU linker script
