Manual Reference Pages - WSO_LOGOUT (3)
wso_login, wso_logout, wso_query, wso_version - API functions to access whoson database
int wso_login(char *addr, char *name, char *retbuf, int buflen)
int wso_logout(char *addr, char *retbuf, int buflen)
int wso_query(char *addr, char *retbuf, int buflen)
wso_login() adds an entry to the whoson database (or replaces existing entry with
the same key)
wso_logout() deletes entry from the database
wso_query() requests the database entry
wso_version() returns the character string with the version number of the API and
addr parameter is the IP address of the remote system specified as a character
string, usually in dotted quad notation (e.g. "220.127.116.11").
This is the key identifying unique entries in the WHOSON database.
name parameter is the user accounting information (e.g. userid).
defines how the API functions should contact the
wso_query() return an integer return code, and the buffer
retbuf is filled with relevant information if appropriate. Return code
-1 means that the request could not be completed, return code
+1 mean that the request was successfully completed. For
wso_query() function, return code 0 means that the
requested address is present in the database. In this case,
retbuf may contain the data that was previously passed to a
wso_login() call for the same
addr as the value of the
In other cases, retbuf may or may not contain description of
the situation, e.g. the text "Access denied" or "Not found" or something
retbuf parameter is NULL or the
buflen parameter is zero, no attempt is made to fill the buffer.
Normally, when filling the database, you can blindly call
wso_logout() if appropriate) and ignore the return code. When querying the
database, return code
0 means that the address is in the database, return code
+1 means that the address is not in the database, and return code
-1 means that the information is unavailable or inaccessable.
WHOSON_VERBOSE Verbose debug messages are enabled if this variable is present in the
environment (its value is ignored).
WHOSON_CONFIG May be set to the pathname of an alternative configuration file.
|WHOSON ||WHOSON (3) ||26 Nov 2006 |
Visit the GSP FreeBSD Man Page Interface.
Output converted with manServer 1.07.