|
- <!--
- Licensed to the Apache Software Foundation (ASF) under one or more
- contributor license agreements. See the NOTICE file distributed with
- this work for additional information regarding copyright ownership.
- The ASF licenses this file to You under the Apache License, Version 2.0
- (the "License"); you may not use this file except in compliance with
- the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
- Unless required by applicable law or agreed to in writing, software
- distributed under the License is distributed on an "AS IS" BASIS,
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- See the License for the specific language governing permissions and
- limitations under the License.
- -->
-
- <html>
- <head>
- <meta http-equiv="Content-Language" content="en-us">
- <link rel="stylesheet" type="text/css" href="../stylesheets/style.css">
- <title>Setproxy Task</title>
- </head>
-
- <body>
- <h2>Setproxy Task</h2>
-
- <h3 id="description">Description</h3>
- Sets Java's web proxy properties, so that tasks and code run in the same JVM can have through-the-firewall access to remote web sites, and remote ftp sites. You can nominate an http and ftp proxy, or a socks server, reset the server settings, or do nothing at all.
-
- <h3>Examples</h3>
- <pre><setproxy/></pre> do nothing
- <pre><setproxy proxyhost="firewall"/></pre> set the proxy to firewall:80
- <pre><setproxy proxyhost="firewall" proxyport="81"/></pre> set the proxy to firewall:81
- <pre><setproxy proxyhost=""/></pre> stop using the http proxy; don't change the socks settings
- <pre><setproxy socksproxyhost="socksy"/></pre> use socks via socksy:1080
- <pre><setproxy socksproxyhost=""/></pre> stop using the socks server.
- <p>
- You can set a username and password for http with the <tt>proxyHost</tt> and <tt>proxyPassword</tt> attributes. On Java 1.4 and above these can also be used against SOCKS5 servers.
- </p>
-
- <h3 id="attributes">Parameters</h3>
- <table>
- <tr>
- <td valign="top" align="left">
- <b>Attribute</b>
- </td>
- <td valign="top" align="left">
- <b>Description</b>
- </td>
- <td valign="top" align="left">
- <b>Type</b>
- </td>
- <td valign="top" align="left">
- <b>Requirement</b>
- </td>
- </tr>
- <tr>
- <td valign="top" align="left">
- nonproxyhosts
- </td>
- <td valign="top" align="left">
- A list of hosts to bypass the proxy on. These should be separated with the vertical bar character '|'. Only in Java 1.4 does ftp use this list. e.g. fozbot.corp.sun.com|*.eng.sun.com
- </td>
- <td valign="top" align="left">
- String
- </td>
- <td valign="top" align="left" rowspan="7">
- Optional
- </td>
- </tr>
- <tr>
- <td valign="top" align="left">
- proxyhost
- </td>
- <td valign="top" align="left">
- the HTTP/ftp proxy host. Set this to "" for the http proxy option to be disabled
- </td>
- <td valign="top" align="left">
- String
- </td>
- </tr>
- <tr>
- <td valign="top" align="left">
- proxypassword
- </td>
- <td valign="top" align="left">
- Set the password for the proxy. Used only if the proxyUser is set.
- </td>
- <td valign="top" align="left">
- String
- </td>
- </tr>
- <tr>
- <td valign="top" align="left">
- proxyport
- </td>
- <td valign="top" align="left">
- the HTTP/ftp proxy port number; default is 80
- </td>
- <td valign="top" align="left">
- int
- </td>
- </tr>
- <tr>
- <td valign="top" align="left">
- proxyuser
- </td>
- <td valign="top" align="left">
- set the proxy user. Probably requires a password to accompany this setting. Default=""
- </td>
- <td valign="top" align="left">
- String
- </td>
- </tr>
- <tr>
- <td valign="top" align="left">
- socksproxyhost
- </td>
- <td valign="top" align="left">
- The name of a Socks server. Set to "" to turn socks proxying off.
- </td>
- <td valign="top" align="left">
- String
- </td>
- </tr>
- <tr>
- <td valign="top" align="left">
- socksproxyport
- </td>
- <td valign="top" align="left">
- Set the ProxyPort for socks connections. The default value is 1080
- </td>
- <td valign="top" align="left">
- int
- </td>
- </tr>
- </table>
- </body>
- </html>
|