/* ** (c) COPYRIGHT MIT 1995. ** Please first read the full copyright statement in the file COPYRIGH. */This module keeps a list of proxies and gateways to be contacted on a request in stead of requesting it directly from the origin server. The module replaces the old system of environment variables for gateways and proxies. However for backward compatibility there is a function that reads the environment variables at start up. Note that there is a difference between a proxy and a gateway - the difference is the way the URL is set up in the RequestLine of the HTTP request. If the original, full URL looks like
"http://www.w3.org/test.html"
then the result will for a
proxy is "http://www.w3.org/test.html"
and a gateway
"/www.w3.org/test.html"
The module is implemented by HTProxy.c, and it is a part of the W3C Reference Library.
#ifndef HTPROXY_H #define HTPROXY_H #include "HTList.h"
http://proxy.w3.org:8001
but
domain name is not required. If an entry exists for this access then
delete it and use the new one.
extern BOOL HTProxy_add (const char * access, const char * proxy); extern BOOL HTProxy_deleteAll (void);The remove function removes all registered proxies. This is automatically done in HTLibTerminate()
w3.org
and www.close.com
extern BOOL HTNoProxy_add (const char * host, const char * access, unsigned port); extern BOOL HTNoProxy_deleteAll (void);The remove function removes all entries in the list. This is automatically done in HTLibTerminate()
extern char * HTProxy_find (const char * url);
http://gateway.w3.org:8001
but domain name is not required. If an entry exists for this access
then delete it and use the new one.
extern BOOL HTGateway_add (const char * access, const char * gate); extern BOOL HTGateway_deleteAll (void);The remove function removes all registered proxies. This is automatically done in HTLibTerminate()
extern char * HTGateway_find (const char * url);
extern void HTProxy_getEnvVar (void);
#endif /* HTPROXY_H */