Version 5.6 Build 450.9

SPECIAL NOTES ABOUT THIS UPDATE:

Changes, Fixes, New Features and Enhancements by Wildcat! Component

WCSERVER (Wildcat! Server)

- new server SDK functions.

- Now flushes files (filemaps) to disk when they are updated. This
should help reduce any lost of data for unexpected reboots or
machine power outtages.

- Added new function WildcatServerConnectLocal() to force local connections
situations. The same can be accomplished by using the specific function
passing the local computer name. But this makes it easier for developers
writing code what wish to force local mode operations only.

- Added local so that no broadcasting is performed for local computer
operations.

- Also corrected some logic for non-static IP internet connections where
if the connection was lost/disconnected while the server was up, future
attempts forced the broadcasting (addin a small 2 second delay). It
also send a false "Client IP advertisement Error" to server. This
small issue is now fixed.

WCCONFIG (Wildcat! Configuration)

- New bandwidth/throttling setup features for WEB, FTP, NNTP, TELNET and Security profiles.

- Fixed the order of the Auto Answer modes in Modem profiles. It should be:

    Ring Detect
    Ring Result

    The first two were reversed.

    Ring Result
    Ring Detect
    Auto Answer

- Added System Security option so that no RPC TCP/IP is used.

WCSSLCONFIG (Wildcat! SSL Configuration)

- n/a

WCONLINE (Wildcat! Online Controller)

- n/a

WCWEB (Wildcat! WEB Server)

The following enhancements and new features were done for the Wildcat!
Web Server:

- Added support for simple YesNo questionnaire option.

- Support for HTTP chunking/flushing offers a tremendous speed
improvement in WEB server-side scripting operations, including
WCX (wcBASIC) and script-mapping.

The web server will automatically flush the output buffer that has
rearch 80% of the internal buffer (32K) size. Hence the feature
benefits all server-side scripting systems.

wcBASIC developers can use the HttpFlush() command to flush
the current output buffer to the browser.

Tip:

wcBASIC developers who are creating larges amount of data should print
the output as oppose to creating a large string buffer and then
printing the final string buffer.

Example:

// method 1: slower browser response

dim buffer as string = ""
for i = 1 to 1000
dim line as string
input #file, line
buffer = buffer + line
next
print buffer

// method 2: faster browser response

for i = 1 to 1000
dim line as string
input #file, line
print line;
next

In method 1, we are concatenating a large string buffer and printing
it when the loop is complete. This has a high overhigh due to
string resizing/reallocation. The browser has to wait until the
data is complete.

In method 2, we are printing as soon as we can. No string resizing
overhead and the web browser will flush the data when it reaches
80% of its internal cache.

- URL redirection or URL Aliases.

A new http alias/redirect configuration file is now available which
allows for creating a simple "alias" name for long URLs.

For example, \wc5\config\http_alias.cfg:

alias redirected url
------------ --------------------------------

subscribe styles/code/html-subscribe
newsletter styles/code/html-newsletter?date=today


The goal with the URL alias is to provide you with short and sweet
URLs to present to users rather than the long urls.

For example, if you have a public url such as:

http://www.domain.comstyles/code/html-newsletter?date=today

you can now make it:

http://www.domain.com/newsletter

by declaring an alias in http_alias.cfg.

This also provides a way to change the redirect url while keeping a
constant, consistent alias.

notes:

1) The alias will override any existing folder path. For example,
using the newsletter alias. If you have a http\newsletter folder,
the alias will override this folder.

With no alias defined for newsletter, the following url:

http://www.domain.com/newsletter

will open up the newsletter folder if a index file is found
in this founder.

With the alias, the redirection to the defined url will take
place.

- New Web server wcBASIC hooks:

html-logon.wcc

If html-logon.wcx is found, it will be executed when the
user is first logs on the web server.

html-logoff.wcc

If html-logoff.wcx is found, it will be executed when the
user is logged off the web server.

html-idletimeout.wcc

If html-idletimeout.wcx is found, it will be executed when the
user is timed out.

- Dynamic Reloading

The web server no longers needs to be restarted when changes are make
to web server configuration items/files. The web server will detect
the changes and re-read the information when it is idle (no one
is connected).

WCFTP (Wildcat! FTP Server)

- Added a new tab to the FTP server setup to edit the messages.

WCSMTP (Wildcat! SMTP Server)

- Added logic to check for HELO/EHLO IP Spoofing

    example:

    client ip is 211.158.5.4, issues

    HELO 208.247.131.9

    a ip check to see if its a valid dot address and compare it with the
    client ip.


WCPOP3 (Wildcat! POP3 Server)


- n/a

WCMAIL (Wildcat! Mail Gateway)

- n/a

WCLISTSERVER (Wildcat! List Server)

- n/a

WCNNTPSERVER (Wildcat! NNTP News Server)

- n/a

WCREPORT (Wildcat! Reports)

- Fixed the automated script command line mode where an extra
  "Cancel Update?" window prompt was displayed.

- Moved the wcREPORT Setup options from the registy to a server side
configuration file (config\wcreport.ini).

Why?

- Now wcReports can be run from multiple machines and read the
common server configuration file. Before, the setup options
were stored on the local machine which were lost if wcReport
was run on another machine.

- Wildcat! will provide this configuration file for all based
installations, regardless if you have wcREPORT or not.

This allows for new applications to use the wcReport defined options
using a traditional Wildcat! client/server methodology.

For example, the Sysop Editor can now read this file to provide the
sysop a way to define user defined profile fields, only possible
before with wcReports.

- Allows for Santronics to easily provide new options for wcREPORT.

WCMENU (Wildcat! Menu Editor)

- n/a

WCQUES (Wildcat! Questionnaire Editor)

Fixed/Cleaned/Added many items

- Added support for config\extendeduserfields.ini

- Fixed up YESNO Question Action type.

- Enhanced the file open/save dialog.

- Added delete questionnaire from the file open dialog.

WCDRAW (Wildcat! Ansi Display Editor)

- Added support for config\extendeduserfields.ini

- Fixed the display of extended user defined fields

- Fixed the handling of %b boolean type extended fields

- file tree items are now sorted

- Display macro fields are now grouped in orderly fashion; MISC, SUB
followed by the rest of the macros.

- You can now delete files using the Right Click menu.

WCSDK

- Three (3) new server SDK API functions were added:

BOOL APIENTRY WcGetPrivateProfileString
(const char *sect,
const char *key,
const char *defvalue,
char *dest,
DWORD *destsize,
const char *inifile);

BOOL APIENTRY WcWritePrivateProfileString
(const char *sect,
const char *key,
const char *value,
const char *inifile);

BOOL APIENTRY WcGetPrivateProfileSection
(const char *sect,
char *dest,
DWORD *destsize,
const char *inifile);

These functions will allow for server-side INI file operations. The inifile name
is is relative to the server, not the client.

The functions follow the same MSDN documented functionality for the
equivalent Win32 functions with the following exception or extensions:

- the inifile name may also be an Wildcat! UNC
- the functions return TRUE/FALSE.


example:

// write to ini file setup.ini in the server data directory
// [section1]
// key1=value1

WcWritePrivateProfileString("section1",
"key1",
"value1",
"wc:\\data\\setup.ini");

//
// read it back. You need to make sure enough space is
// available for the output string value and that the
// buffer size is passed as well. if the space
// is too small, the size is change to requested size
// minus one. See the MSDN documentation for detail
// usage.
//

char value[255];
DWORD size = sizeof(value);

WcGetPrivateProfileString("section1",
"key1",
"default value",
value,
&size,
"wc:\\data\\setup.ini");


//
// Read all sections. Again, following the MSDN
// documentation, this is done by passing NULL
// to the section parameter. The output buffer
// is an array of asciiz strings, ending with
// with a double NULL.
//

char sections[4096];
DWORD size = sizeof(value);

WcGetPrivateProfileString(NULL,
"",
"",
sections,
&size,
"wc:\\data\\setup.ini");

// display the sections:

int nulls = 0;
for (DWORD i = 0;i < size; i++) {
if (dest[i] == 0) {
nulls++;
printf("\n");
if (nulls == 2) break;
continue;
} else {
nulls = 0;
}
printf("%c",dest[i]);
}

//
// Read all the keys=values for a given section.
//

char buffer[1024*20]; // 20K buffer
DWORD size = sizeof(dest);

WcGetPrivateProfileSection("section1",buffer,&size,"wc:\\data\\test.ini");

printf("---- key/value ----\n");
int nulls = 0;
for (DWORD i = 0;i < size; i++) {
if (dest[i] == 0) {
nulls++;
printf("\n");
if (nulls == 2) break;
continue;
} else {
nulls = 0;
}
printf("%c",dest[i]);
}

WCBASIC

- Added for new CATCH exceptions

    ERR_PATH           for mkdir/rmdir errors.
    ERR_RUN             for Run() errors

- Opening files for Append mode (OPEN command) was done in READ ONLY share mode only.

    This is incorrect. It should allow for both READ/WRITE sharing. Apparently, the original design was
    concern with any sharing conflicts between wcBASIC applets. However, thats a programmers issue
    like in all language.  It should not be a BASIC language limitation.


- A new library Win32Ini provides INI functionality.  See win32ini.wch header file.

For server-side INI operations, use the following:

//---------------------------------------------
// WcGetPrivateProfileSection()
//
// return the key value as a string from section
//

function WcGetPrivateProfileString
(byval sect as string,
byval key as string,
byval defvalue as string
byval inifile as string) as string

//---------------------------------------------
// WcWritePrivateProfileSection()
//
// write key=value in section, return size of
// value written.

function WcWritePrivateProfileString
(byval sect as string,
byval key as string,
byval value as string
byval inifile as string) as integer

//---------------------------------------------
// WcGetPrivateProfileSection()
//
// return a string in NV pair format:
//
// &key1=value1&key2=value2....
//

function WcGetPrivateProfileSection
(byval sect as string,
byval inifile as string) as string


For client-side INI operations, use the standard WIN32
functions imported in win32ini.wch:

function WritePrivateProfileString
(byval Sect as string,
byval Key as string,
byval Value as pointer,
byval IniFile as string) as integer

function GetPrivateProfileString
(byval Sect as string,
byval Key as string,
byval DefValue as string,
value as pointer,
byval size as integer,
byval IniFile as string) as integer

function GetPrivateProfileSection
(byval Sect as string,
value as pointer,
byval size as integer,
byval IniFile as string) as integer

Both can be used together with the following functions:

Note: If the ini is a Wildcat! UNC, it will refer to
to the server-side. If the ini is not an WUNC,
it will refer to the client side:

Function iniGetString
(sect as string,
key as string,
defvalue as string,
ini as string) as String

Function iniGetInteger
(sect as string,
key as string,
defvalue as Integer,
ini as string) as Integer

Function iniGetBoolean
(sect as string,
key as string,
defvalue as boolean,
ini as string) as Boolean

Function iniWriteString
(sect as string,
key as string,
value as string,
ini as string) as boolean

Function iniWriteInteger
(sect as string,
key as string,
value as integer,
ini as string) as boolean


- New MakeDirectory() function:

    Function MakeDirectory(path as string) as Boolean

    Create the full path. Return FALSE if failed. Otherwise TRUE

- The SDK function GetUserVariable() now allows the passing of a
blank or null parameters to get entire sections.

Via wcBASIC, the GetUserVartiable is equivalent to the commands:

string = User.Variable(section,key,defaultstring)
integer = User.Variable(section,key,defaultinteger)

So if you wanted to see all the keys in the section "profile", you
simple pass a blank key. All the keys in the section will be
returned as string each key terminated with chr(13) character;

key1 <13>
key2 <13>
key3 <13>
..
keyN <13>

- WCVB.DLL enhancements

(Note: the last WCVB.DLL was 450.4 10/26/2002)

- Wildcat SDK functions returning BOOL will now return a VB style
boolean TRUE or FALSE value, which corresponds to -1 and 0.

Why?

In C/C++, BOOL is 1. In VB, a BOOLEAN is -1.

By conforming to the VB syntax, it allows your VB syntax to be easier:

Before, you have to compare it to FALSE to be correct with boolean
comparisons in Visual Basic (or basic in general):

if WildcatServerConnect(0) <> FALSE then
' success!
end if

Now, the same will work, however, you don't need to compare it to
FALSE. Simple use it as a true Visual Basic BOOLEAN type:

if WildcatServerConnect(0) then
' success!
end if

- New Exception trapping for wcBASIC applications imported DLL functions.

New logic was added to the run time engine (RTE) to trap DLL imported
function call exceptions.

If a DLL imported function failed, untrapped errors could caused a
memory leak. Although wcOnline would continue running, a continued
failure would inevitably caused WCONLINE to run out of resources and
fault, even possibly "disappear" without trace.

A new wcBASIC catch was added, ERR_DLLEXCEPTION, which can used to
catch a DLL function call exception error.

If no catch is added to the WCX program, wcOnline will record the
error in wcHostFault.log and abort the wcx application.

With a catch, wcOnline will record the error and continue at the
catch statement.

It is highly recommmended that if a DLL function call fails, the
wcBASIC application should gracefully shutdown the session until the
DLL function call is finally fixed.

Example:

declare function FuncXYZ dll "TestDLL.dll" as integer

....

FuncXYZ() // calling dll function

...

catch err_dllexception
print "error with DLL function: FuncXYZ"
end

- wcBASIC Library fixes:

cmdline.wcc

InputString() function was making excessive calls to GetObjectFlags()
during input.

WCC
---

- Added hex number address support for the /F option in wcc.exe