Bump version for next release
Merge branch 'release-1.4' into develop
Add DAEMON_OPTS variable in vncauthproxy.default
Make control connection handling async

For every incoming control connection, accept() inside the main loop and
dispatch the connection handling/establishment to a new greenlet.

The async handling of the control connections ensures that vncauhtproxy won't
hang again if the VNC server or client fail during the connection establishment
(handshake).

This commit also adds a larger (and configurable) backlog for the control
socket and a (configurable) timeout to the server socket, while doing the
handhsake.
Use TCP instead of UNIX sockets (first try)

Initial 'implementation' of vncauthproxy using TCP sockets instead of
UNIX domain sockets for control connections.

By default, it will bind to 127.0.0.1:24999 (forwarding ports start at
TCP 25000). The client was changed accordingly.

The new version needs 'lexical' fixes (cli options
etc) and *a lot* of testing.
Minor lexical fixes
Code refactoring

* Move the connection establishment inside the VncAuthProxy greenlet /
  class.
* Use a shared get_listening_sockets() method for both client proxy /
  forward sockets and the control socket.
* Reorganize / comment / rephrase the default values and the cli
  options. Also make sure to disallow any positional arguments, when parsing
  the cli input.
Fix typos/mistakes introduced by the refactoring
Set SO_REUSEADDR for the control socket
Use SSL/TLS for control connections

Control connections now use SSL/TLS by default. Since, vncauthproxy control
connections now use TCP/IP instead of Unix domain sockets, sensitive
information could be sent over possibly untrusted / insecure channels.
Add support for control connection authentication

Since vncauthproxy no longer uses Unix domain sockets for the control
connection handling, authentication handling, which was done with POSIX
file permissions, must be implemented in vncauthproxy.

The /var/lib/vncauthproxy/users file (configurable) acts as an
'auth_db'.  Its entries are in the form of 'username password'. Lines
starting with '#' are treated as comments. Passwords can be stored in
cleartext format, or they can be prefixed with a {cipher} tag. At the
moment, vncauthproxy only supports the {cleartext} tag (same as no tag)
and the {HA1} tag, which stores the MD5 digest of the string
'username:vncauthproxy:password'.

The json format for the requests has changed accordingly, with two new
elements added (auth_user and auth_password). Failed requests will now
also get a slightly modified response, including the reason for the
failure (eg 'Authentication Failure').

Currently, vncauthproxy doesn't (need to) support separate read and
write permissions.

Note that since vncauthproxy now needs exclusive read access on the
'auth_db' file (and the SSL key file, introduced in a previous commit),
the vncauthproxy daemon must not run as nobody / nogroup. The relevant
debian files in the debian branch must change accordingly.

This commit also includes various fixes / improvements regarding the
SSL/TLS support for control connections (introduced in a previous
commit).
Add example users file and users file checks

Add an example users file and fail if there are no users defined in the
file.
Initial Debian packaging
Drop daemon's privileges

Since there is no support for this in the daemon itself nor a proper
configuration file, do that in the (Debian) init script by using a
/etc/default/vncauthproxy file plus start-stop-daemon.
Minor fixes to the Debian packaging
Update debian packaging after script name change

Update debian packaging to reflect console script name change
vncauthproxy.py -> vncauthproxy in setup.py.
Update maintainer field in Synnefo branch
Add the `snf-' prefix to the package name
Install default and init.d file as `vncauthproxy'

This is done to ensure there is an upgrade path, if package
`vncauthproxy' is already installed
Update debian/changelog before release