CA-105004: Enable SO_KEEPALIVE for stunnel client

We should also consider fine tweaking KEEPALIVE parameters when we upgrade to the new version of stunnel.

Signed-off-by: Zheng Li <zheng.li@eu.citrix.com>
Merge pull request #144 from zli/xenserver/CA-105004

CA-105004: Enable SO_KEEPALIVE for stunnel client
CA-89974: Live migrate fails on IPv6-preferring hosts

Make HTTP server understand URLs containing literal IPv6 addresses.
A related commit to xen-api makes the client embed literal IPv6 addresses
in URLs correctly.

 * Parse IPv6 literals wrapped in square brackets in URLs
 * Wrap IPv6 literals in square brackets when creating URLs
 * Copy 'Helpers.validate_ip_address' from xapi/helpers.ml in xen-api
   to stdext/unixext.ml and rename it to 'domain_of_addr';  a separate
   commit to xen-api will remove the original 'validate_ip_address'

Signed-off-by: Euan Harris <euan.harris@citrix.com>
Merge pull request #147 from euanh/CA-89974

CA-89974: Live migrate fails on IPv6-preferring hosts