跳至主要內容
OCLC Support

Proxy & ProxySSL

Learn how to use Proxy and ProxySSL config.txt directives to specify a proxy server for EZproxy.

Proxy and ProxySSL are position-dependent config.txt directives that interact with database definitions.

Proxy directs EZproxy to use the specified proxy server when making http requests for remote web pages. ProxySSL directs EZproxy to use the specified proxy server when making https requests for remote web pages. You may use only Proxy to proxy only outgoing http requests, only ProxySSL to proxy only outgoing https requests, or both.

Syntax

Proxy host: port username: password
ProxySSL host: port username: password

You may omit username: password if your proxy server does not require a username or password. Specifying Proxy or ProxySSL alone directs EZproxy not to proxy outgoing requests.

Examples

The most typical usage and placement of Proxy is right before your first Title statement, such as:

Proxy squid.yourlib.org:3128
ProxySSL squid.yourlib.org:3128
Title Some Database
    URL http://www.somedb.com/
    D somedb.com
Title Other Database
    URL http://www.otherdb.com/
    D otherdb.com

If needed, you can direct EZproxy to use different proxy servers when accessing different databases. The most common application for this functionality occurs when using EZproxy with LOCKSS. A sample configuration might look like this:

# Direct requests for Some Database through LOCKSS server
Proxy lockss.yourlib.org:3128
Title Some Database
URL http://www.somedb.com/
D somedb.com
# Requests for Other Database go direct, bypassing any proxy
Proxy
Title Other Database
URL http://www.otherdb.com/
D otherdb.com