RMI Proxy 1.2

com.rmiproxy
Class Configuration

java.lang.Object
  |
  +--com.rmiproxy.Configuration

public abstract class Configuration
extends java.lang.Object

Holds configuration details for the RMI application firewall.

Configuration details are read from a configuration file, which is a standard Java properties file named rmiproxy.cfg. All hosts involved in the RMI Proxy setup (client, server and all intervening proxies) may have a such a file. It is assumed to exist in the current directory (TODO Fix this?), along with any rmiproxy.policy file (required by proxy hosts only).

Currently two values are configurable:

These values may also be specified via system properties, in which case the system properties over-ride any specifications in rmiproxy.cfg.


Field Summary
static java.lang.String ConfigFile
          Name of the configuration file.
 
Method Summary
static Configuration current()
           
abstract  java.util.Collection getNonProxyHosts()
           
abstract  java.lang.String getProxyHost()
           
abstract  boolean isNonProxyHost(java.lang.String host)
           
static void refresh()
          Refresh the configuration.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

ConfigFile

public static final java.lang.String ConfigFile
Name of the configuration file.
Method Detail

current

public static Configuration current()
Returns:
The singleton Configuration instance

refresh

public static void refresh()
Refresh the configuration.

getProxyHost

public abstract java.lang.String getProxyHost()
Returns:
The RMI URL (e.g. 'rmi://10.0.1.6') of the proxy host, or null if there is no proxy.

When present, it is always the URL of the RMI Proxy which is closer to the Internet than this host.


getNonProxyHosts

public abstract java.util.Collection getNonProxyHosts()
Returns:
The non-RMI-proxy hosts as a Collection of RMI URL-formatted names, or null if there are none.

RMI requests for these hosts will be forwarded directly and not via the RMI proxy.


isNonProxyHost

public abstract boolean isNonProxyHost(java.lang.String host)
Returns:
False iff the specified host is reached via the RMI proxy

www.rmiproxy.com

Copyright © 2000, 2003 Telekinesis Pty Ltd, Box 82/85 Grattan St, Carlton 3053, Victoria, Australia. All rights reserved.