Package net.i2p.router.web
Class ConfigUpdateHandler
java.lang.Object
net.i2p.router.web.FormHandler
net.i2p.router.web.ConfigUpdateHandler
public class ConfigUpdateHandler extends FormHandler
-
Field Summary
Fields Modifier and Type Field Description static String
DEFAULT_NEWS_URL
older defaultstatic String
DEFAULT_NEWS_URL_SU3
current default, i2pnews.i2p, run by echelon NOTE: If you change, also change in Android: app/src/main/java/net/i2p/android/apps/NewsFetcher.javastatic String
DEFAULT_PROXY_HOST
static String
DEFAULT_PROXY_PORT
static int
DEFAULT_PROXY_PORT_INT
static long
DEFAULT_REFRESH_FREQ
static String
DEFAULT_REFRESH_FREQUENCY
static boolean
DEFAULT_SHOULD_PROXY
static boolean
DEFAULT_SHOULD_PROXY_NEWS
static String
DEFAULT_UPDATE_POLICY
static String
DEFAULT_UPDATE_URL
These are only for .sud and .su2.static String
OLD_DEFAULT_NEWS_URL
very old defaultstatic String
OLD_DEFAULT_NEWS_URL_SU3
old defaultstatic String
PROP_DEV_SU3_URL
no defaultstatic String
PROP_NEWS_URL
static String
PROP_PROXY_HOST
static String
PROP_PROXY_PORT
static String
PROP_REFRESH_FREQUENCY
static String
PROP_SHOULD_PROXY
static String
PROP_SHOULD_PROXY_NEWS
static String
PROP_TRUSTED_KEYS
static String
PROP_UPDATE_DEV_SU3
default falsestatic String
PROP_UPDATE_DISABLED
default false - use for distrosstatic String
PROP_UPDATE_POLICY
static String
PROP_UPDATE_UNSIGNED
default falsestatic String
PROP_UPDATE_URL
static String
PROP_ZIP_URL
no defaultstatic String
SU3_UPDATE_URLS
Empty string if disabled.static boolean
USE_SU3_UPDATE
Only enabled if we have trusted public key certificates installedFields inherited from class net.i2p.router.web.FormHandler
_action, _context, _log, _method, _out, _requestWrapper, _settings
-
Constructor Summary
Constructors Constructor Description ConfigUpdateHandler()
-
Method Summary
Modifier and Type Method Description protected void
processForm()
Implement this to perform the final processing (in turn, adding formNotice and formError messages, etc) Will only be called if _action is non-null and the nonce is valid.static int
proxyPort(I2PAppContext ctx)
Convenience method for updatersvoid
setDevSU3URL(String url)
void
setNewsThroughProxy(String foo)
void
setNewsURL(String url)
void
setProxyHost(String host)
void
setProxyPort(String port)
void
setRefreshFrequency(String freq)
void
setTrustedKeys(String keys)
void
setUpdateDevSU3(String foo)
void
setUpdatePolicy(String policy)
void
setUpdateThroughProxy(String foo)
void
setUpdateUnsigned(String foo)
void
setUpdateURL(String url)
void
setZipURL(String url)
Methods inherited from class net.i2p.router.web.FormHandler
_t, _t, _t, _x, addFormError, addFormErrorNoEscape, addFormNotice, addFormNoticeNoEscape, getAllMessages, getErrors, getJettyString, getNewNonce, getNotices, isAdvanced, setAction, setContextId, setNonce, setRequestWrapper, setSettings, storeMethod, storeNonces, storeWriter
-
Field Details
-
PROP_NEWS_URL
- See Also:
- Constant Field Values
-
OLD_DEFAULT_NEWS_URL
very old default- See Also:
- Constant Field Values
-
DEFAULT_NEWS_URL
older default- See Also:
- Constant Field Values
-
OLD_DEFAULT_NEWS_URL_SU3
old default- See Also:
- Constant Field Values
-
DEFAULT_NEWS_URL_SU3
current default, i2pnews.i2p, run by echelon NOTE: If you change, also change in Android: app/src/main/java/net/i2p/android/apps/NewsFetcher.java- See Also:
- Constant Field Values
-
PROP_REFRESH_FREQUENCY
- See Also:
- Constant Field Values
-
DEFAULT_REFRESH_FREQ
public static final long DEFAULT_REFRESH_FREQ- See Also:
- Constant Field Values
-
DEFAULT_REFRESH_FREQUENCY
-
PROP_UPDATE_POLICY
- See Also:
- Constant Field Values
-
DEFAULT_UPDATE_POLICY
- See Also:
- Constant Field Values
-
PROP_SHOULD_PROXY
- See Also:
- Constant Field Values
-
DEFAULT_SHOULD_PROXY
public static final boolean DEFAULT_SHOULD_PROXY- See Also:
- Constant Field Values
-
PROP_SHOULD_PROXY_NEWS
- Since:
- 0.9.9
- See Also:
- Constant Field Values
-
DEFAULT_SHOULD_PROXY_NEWS
public static final boolean DEFAULT_SHOULD_PROXY_NEWS- Since:
- 0.9.9
- See Also:
- Constant Field Values
-
PROP_PROXY_HOST
- See Also:
- Constant Field Values
-
DEFAULT_PROXY_HOST
- See Also:
- Constant Field Values
-
PROP_PROXY_PORT
- See Also:
- Constant Field Values
-
DEFAULT_PROXY_PORT_INT
public static final int DEFAULT_PROXY_PORT_INT- See Also:
- Constant Field Values
-
DEFAULT_PROXY_PORT
-
PROP_UPDATE_UNSIGNED
default false- See Also:
- Constant Field Values
-
PROP_UPDATE_DISABLED
default false - use for distros- See Also:
- Constant Field Values
-
PROP_ZIP_URL
no default- See Also:
- Constant Field Values
-
PROP_UPDATE_URL
- See Also:
- Constant Field Values
-
PROP_UPDATE_DEV_SU3
default false- Since:
- 0.9.20
- See Also:
- Constant Field Values
-
PROP_DEV_SU3_URL
no default- Since:
- 0.9.20
- See Also:
- Constant Field Values
-
DEFAULT_UPDATE_URL
These are only for .sud and .su2. Do NOT use this for .su3 -
USE_SU3_UPDATE
public static final boolean USE_SU3_UPDATEOnly enabled if we have trusted public key certificates installed- Since:
- 0.9.9
-
SU3_UPDATE_URLS
Empty string if disabled. Cannot be overridden by config.- Since:
- 0.9.9
-
PROP_TRUSTED_KEYS
- See Also:
- Constant Field Values
-
-
Constructor Details
-
ConfigUpdateHandler
public ConfigUpdateHandler()
-
-
Method Details
-
proxyPort
Convenience method for updaters- Returns:
- the configured value, else the registered HTTP proxy, else the default
- Since:
- 0.8.13
-
processForm
protected void processForm()Description copied from class:FormHandler
Implement this to perform the final processing (in turn, adding formNotice and formError messages, etc) Will only be called if _action is non-null and the nonce is valid.- Specified by:
processForm
in classFormHandler
-
setNewsURL
-
setRefreshFrequency
-
setUpdateURL
-
setUpdatePolicy
-
setTrustedKeys
-
setUpdateThroughProxy
-
setProxyHost
-
setProxyPort
-
setUpdateUnsigned
-
setZipURL
-
setNewsThroughProxy
- Since:
- 0.9.9
-
setUpdateDevSU3
- Since:
- 0.9.20
-
setDevSU3URL
- Since:
- 0.9.20
-