[[ucc_options]]
Common options to UCC
---------------------

The following table lists the options understood by most UCC commands. Most 
commands have additional options. You can always get a summary of all available
options for a command by calling UCC with the "-h" or "--help" option, for example

-----------
ucc batch --help
-----------

You do not need to give all the options on the commandline, it is advisable to create a preferences
file containing your usual settings for keystore, registry etc. 

.Common options for the UCC
[options="header"]
|==============================
|option (short and long form)| description
| -c,--configuration <Properties_file>  | Properties file containing your preferences. By default, a file 'userhome/.ucc/preferences' is checked.
| -k,--keystore <Keystore_file>   |      Keystore containing your user credential and trusted certificates
| -n,--alias <Alias>   |      Key entry alias (by default, the first key entry is used)
| -p,--password <Password>   |      Keystore password
| -x,--storetype <Keystore_type>    |   Keystore type (default is "jks") 
| -T,--truststore <Truststore_file>   |   Truststore in JKS format containing your trusted certificates
| -Y,--truststorePassword <Password>   |      Truststore password
| -o,--output <Output_dir>    |          Directory for any output produced (default is the current directory)
| -r,--registry <List_of_Registry_URLs>  |        The comma-separated list of URLs of UNICORE registries
| -v,--verbose | Verbose mode 
| -h,--help | Print help message
| -y,--with-timing            |      Timing mode
| -J, --VO                    |      VO server URL
|================================


Security and VO related options
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

In general you need a keystore containing your end-user certificate in order 
to use UNICORE.

To use UCC with infrastructures that run a SAML-enabled VO server such as UVOS, there are 
additional options for specifying the VO server, your VO etc. 
Please see the xref:ucc_saml[SAML Push] section for details about the VO support.

Here is a list of security related options.

.Security and VO options for the UCC
[options="header"]
|==============================
|option (short and long form)     |  description
| -k,--keystore <Keystore_file>   |  Keystore containing your user credential and trusted certificates
| -n,--alias <Alias>              |  Key entry alias (by default, the first key entry is used)
| -p,--password <Password>        |  Keystore password
| -x,--storetype <Keystore_type>     |  Keystore type (default is "jks") 
| -T,--truststore <Truststore_file>    |   Truststore in JKS format containing your trusted certificates
| -Y,--truststorePassword <Password>   |   Truststore password
| -J, --VO                    |      VO server URL
| -G, --voGroup               |      VO group
| -A, --attributeAssertion    |      File containing a VO attribute assertion
| -I, --includeAttributes     |      Filter VO attributes
| -Q, --excludeAttributes     |      Filter VO attributes
|================================


Configuration file
~~~~~~~~~~~~~~~~~~

By default, UCC checks for the existence of a file <userhome/.ucc/preferences> and reads
default settings from there. As shown above, you can use a different file by specifiying
it on the commandline using the "-c" option.

The configuration file can contain default settings for many commandline options,
which are given in the form <option name>=<value>  where <option name> is the long
form of the option.

For example, to set your keystore and registry, the file can contain the following settings
  
----------------------------
keystore=user-keystore.p12
storetype=pkcs12
password=XXXXXXX
registry=https://localhost:8080/XNJS/services/Registry?res=default_registry
----------------------------

[NOTE]
==================
To protect your passwords, you should make the file non-readable by others,
for example on Unix using a command such as 'chmod 600 preferences'
==================

Communications options
~~~~~~~~~~~~~~~~~~~~~~

The configuration file may also contain low-level options, for example if you need to 
specify connection timeouts, http proxies etc. 


.HTTP options for the UCC
[options="header"]
|==============================
|option | description
|http.proxyHost  | HTTP(s) proxy to use
|http.proxyPort  | Port of the HTTP(s) proxy to use
|http.nonProxyHosts  | Space separated list of host name fragments for which NOT to go via the proxy. If the target URL contains such a fragment, it is accessed directly
|http.connection.timeout  | Timeout to use when establishing a HTTP connection
|http.sockettimeout  | Timeout to use when reading/writing from/to HTTP connection
|==============================

For example, to set the timeout when establishing a connection to 5 seconds, you would use

------------
http.connection.timeout=5000
------------

Other options
~~~~~~~~~~~~~

The following table lists other options, that are more rarely used.

.Other options for the UCC
[options="header"]
|==============================
|option | description
|contact-registry  | Do not attempt to contact the registry, even if one is configured
|==============================
