
Configuring Avira Updater
------------------------

With Avira Updater you can update Avira software on your computers, 
using Avira update servers. The program can be configured either by 
editing the configuration file, or by using command line options.

Before downloading and updating product files, the Updater reads the
configuration from avupdate.conf. 
All parameters from avupdate.conf can be passed to the Updater via
command line. For example:
-parameter in avupdate.conf: 
	temp-dir=/tmp 
-command line: 
	avupdate.bin --temp-dir=/tmp 
The configuration parameters for the Updater are listed below.

* General:

--help 
Display help about the Updater options.
Note:
This option is available only for unix versions of avupdater.

--version 
Display Updater version.
Note:
This option is available only for unix versions of avupdater.

--config 
Contains the path to the configuration file.
avupdate.bin --config=avupdate.conf
The default value: avupdate.conf

--quiet
If is present, the updater will not log messages on screen.
Note:
This option is available only for unix versions of avupdater.
The default value: false

--show-progress
Show download progress.
Note:
This option is available only for unix versions of avupdater.
The default value: false

* Directories and files:

--temp-dir 
Temporary directory for downloading update files.
avupdate.bin --temp-dir=/tmp
The default value: avupdate

--backup-dir 
Backup directory for the existing files, before updating.
The default value: <install directory>\avupdate_backup

--install-dir 
Specifies the installation directory for updated product files. 
avupdate.bin --install-dir=/usr/lib/AntiVir

--update-dir
Specifies the location of engine, vdf and build.dat in order to get the needed informations
for the user-agent string. If this parameter is not given, avupdater will use the path from
"--install-dir" option.

--key-dir
Specifies the directory in which the updater should search for a valid key.

--product-root 
The directory on the update server where the files for a product are to 
be found.

--master-file 
Specifies the master.idx file.
avupdate.bin --master-file=/idx/master.idx

--local-master-file
Specifies the full path to a local master file to be used instead the
one from the install directory.

--product-file 
To specify the idx product file. Example:
avupdate.bin --product-file=/idx/mailgatebin.idx 

--add-var-pair 
Used to define variable and value pairs in the INFO file. Example: 
DESTINATION=%MY_INSTALL_DIR% 
In command line: 
avupdate.bin --add-var-pair=MY_INSTALL_DIR=/usr/lib/<yourproduct>

--internet-srvs 
The list of Internet update servers. 
avupdate.bin --internet-srvs= http://dl1.pro.antivir.de,
http://dl2.pro.antivir.de, http://dl3.pro.antivir.de 

--peak-handling-srvs
Contains the servers used in case no internet server is available or if both 
'--ipv4-peak-server-limit' and '--ipv6-peak-server-limit' are reached.

--ipv4-peak-server-limit
If both '--ipv4-peak-server-limit' and '--ipv6-peak-server-limit' are reached 
the list of servers from '--peak-handling-srvs' will be used for update. If this
limit is set 0 updater will try to update from all ipv4 servers ('--internet-srvs')
before trying to update from '--peak-handling-srvs' list.
The default value: 0

--ipv6-peak-server-limit
If both '--ipv4-peak-server-limit' and '--ipv6-peak-server-limit' are reached 
the list of servers from '--peak-handling-srvs' will be used for update. If this
limit is set 0 updater will try to update from all ipv6 servers ('--internet-srvs')
before trying to update from '--peak-handling-srvs' list.
The default value: 0

--product-info-file
To specify the product info file.

--local-product-info-file
Used to specify a local product info file to be used instead the one 
from the server.

* Update mode:

--mirror
Performs a mirror update(meaning no pre / post / unpost applications are executed)
The default value: false

--check-if-update-available 
When this option is set updater will not install any files. It will only check if an
update is available.
There are two situations:
1) When --skip-master-file is set, updater will download product.info files and it will
check all local files against the online ones. It will also log the files that are dirty
and must be updated.
2) When --skip-master-file is not set, updater will download only master.idx. It will
check only local master.idx against the online one. 
If identical will return "Nothing to update". If not identical will return "Update is available"
The default value: false

--update-modules-list 
Specifies the modules that must be updated (comma-separated list). 

--no-check-md5 
Don't check md5 of local files. 
The default value: false

--skip-master-file 
Skip master file (if you want to mirror the entire structure, not only the 
changed files). 
The default value: false

--skip-selfupdate 
Skip installing updater files. 
The default value: false

--no-deltaupdate
Specifies that the updater will not use the delta update feature.
The default value: false

--no-signature-check
Specifies that the updater will not check if the files are signed.
Note:
Only uncompressed binary files are checked. 
The default value: true

--check-product
If this option is present, the updater will check the license.
The default value: false

--ext-program-timeout
Timeout for waiting an executed pre / post / unpost application (in seconds).
The default value: 1800 s

--depend
If this option is present, the updater will use the old depend functionality.
Description:
When in the product info file, module 1 depends on module 2, module 1 
must get dirty when module 2 is dirty, meaning that pre / post applications
of module 1 gets executed.
The default value: false

--ignore-srvs-list
For updates from a share or internal http server the Updater must
ignore the servers list present in the IDX file and download everything from
inside the network and not from the Internet.
The default value: false

* Connection settings:

--user-agent
Specifies the user agent string which is reported to the http server.
The default value: AntiVir-UpdateCP/<updater version> (<target>;<product>; 
AVE <engine version>; VDF <version>; <language>; <operating system>)
Example:
AntiVir-UpdateCP/0.0.21 (SELFUPDATE, VDF, AVE2, SAVAPI3;
SAVAPI3-LINUX_GLIBC22-EN; AVE 8.1.1.23; VDF 7.0.6.157; EN; LINUX_GLIBC22_I386)

--system-proxy
Tells the updater to use system proxy settings.
The default value: false

--proxy-username 
Username for proxy authentication. 

--proxy-password 
Password for proxy authentication. 

--proxy-host 
The name of the proxy server. 

--proxy-port 
Proxy port. 

--username 
Username for accessing a shared folder. 

--password 
The password for accessing a shared folder. 

--connect-timeout 
Timeout for Internet connection (in seconds).
The default value: 30 seconds

--receive-timeout 
Timeout for receiving data (in seconds). 
The default value: 30 seconds

--retries 
Number of retries.
The default value: 1

--retry-timeout 
Timeout between retries (in seconds). 

* Notification emails:

--mailer
Specify the method for sending mails. Can have one of the following values:
  smtp      -  for using own smtp engine
  sendmail  -  for using sendmail binary
The default value: smtp

--sendmail-path
When --mailer is set sendmail, this parameter specifies the local path of
sendmail binary.
On unix the default value is: /usr/sbin/sendmail. It also searches in /usr/lib/sendmail

--sendmail-arguments
If --mailer is set sendmail, this parameter specifies the arguments for running
sendmail binary.
On unix the default value is: -oem -oi

--email-to 
Receiver of the notification emails, if --notify-when is not 0 (see below). 
The default value: root@localhost

--email-from
Sender of the notification emails, if --notify-when is not 0 (see below). 
The default value: root@localhost

--notify-when 
To send email notifications to the address set with --email-to. This 
option can have one of four values: 
	0 - no email notifications are sent (default value), 
	1 - email notifications are sent in case of "successful update",
	"unsuccessful update", or "up to date". 
	2 - email notification only in case of "unsuccessful update". 
	3 - email notification only in case of "successful update".
The default value: 0

--email-footer 
The default footer of the notification emails is: 
-- Avira AntiVir Copyright (c) 2010 by Avira GmbH. All rights reserved. 
It can be changed using --email-footer: 
avupdate.bin --email-to=<yourmail@domain.com> --email-footer=
<custom footer> 

--auth-method 
When set in avupdate.conf, the Updater requires the smtp login data: 
smtp-user and smtp-password (see bellow), in order to send email
notifications to the address set with --email-to. 
The default value: false

--smtp-user 
If notify-when is not 0 and auth-method is set in avupdate.conf, the
Updater requires the smtp login data: smtp-user and smtp-password. 

--smtp-password 
If notify-when is not 0 and auth-method is set in avupdate.conf, the
Updater requires the smtp login data: smtp-user and smtp-password. 

--smtp-server 
The smtp server for sending email notifications, if --notify-when is not 0. 

--smtp-port 
The smtp port for sending email notifications, if --notify-when is not 0. 
The default value: 25

--smtp-timeout
Timeout for receiving data when connecting to a smtp server (in seconds). 
The default value: 30 seconds

* Logfile:

--log 
Specifies a different name of the logfile. The default name: avupdate.log 
Note:
If this option is not present, a default logfile with the name 'avupdate.log'
will be created in the same directory as the updater binary.

--log-rotate 
Overwrite logfiles by rotation. For maintaining a log history, up to 10 
recent logfiles will be kept. For example: 
avupdate.log.001, avupdate.log.002, avupdate.log.003, ...,
avupdate.log.010, avupdate.log.001... 
The default value: false
Note:
This parameter is mutual exclusive with --log-append.
If both parameters are present the --log-append behaviour will be ignored.

--log-append 
Append to log file (By default, the log is overwritten).
Note:
This parameter is mutual exclusive with --log-rotate.

--log-template 
Option to specify the format of the logfile. 
The default template used for logging is: 
${DAY}/${MONTH}/${YEAR} ${HOUR}:${MINUTE}:${SECOND}
${FULLHOST}[${PID}]: ${SOURCE}: ${LEVEL}: ${MSG} 
where: 
	${DAY}/${MONTH}/${YEAR}- date format 
	${HOUR}, ${MINUTE}, ${SECOND}- time format 
	${FULLHOST}- hostname 
	${PID}- pid of the program generating the log 
	${LEVEL}- the message level, as set by the program ("DEBUG", 
	"INFO", "MESSAGE", "WARNING", "ERROR", "FATAL", "MAX_LEVEL", 
	"UNDEFINED") 
	${MSG}- the message sent to the log 
Example of log entry: 
	16/07/2008 12:34:04 abc-desktop [18428]: UPD: ERROR: Smtp 
	engine returned error: Connection refused 
The user can specify only the desired information to be logged. 
For example:
-in avupdate.conf: 
	log-template=${MSG} 
-in the command line:
	avupdate.bin --log-template=${MSG} 


Avira Updater can return one of the following codes:
  0  -  successful update
  1  -  nothing to update
 -1  -  unsuccessful update


Example of a configuration file:

		internet-srvs=http://dl.antivir.de/update
		master-file=/idx/master.idx
		product-file=/idx/savapi3-linux_glibc22-en.idx
		install-dir=install
		temp-dir=/tmp/avira


* Updating from IUM

		# Should replace here IUM_SERVER and IUM_PORT with the correct name and port of IUM server
		internet-srvs=http://IUM_SERVER:IUM_PORT/update
		master-file=/idx/master.idx
		product-file=/idx/savapi3-linux_glibc22-en.idx
		install-dir=install
		temp-dir=/tmp/avira
		ignore-srvs-list
