Ubuntu One Proxy Support



This workaround makes it possible for syncdaemon to connect to the proxy server. It involves configuration changes and software installation.

First of all syncdaemon needs to be tweaked so that it is connecting to the localhost instead of the real ubuntu one server. Choose the port according to your own taste - you will control the port number in this case.


log_level = TRACE
host =
port = 1986
dns_srv = None

We need to disable DNS SRV lookup, so that syncdaemon will not query DNS. Unfortunately the only way to do that is to supply it with an invalid SRV lookup string. "None" works.

Now we need to set up a proxy for the service.


ProxyTunnel can use environment variable HTTP_PROXY which is set within GNOME session in case Proxy settings are used.

The argument to -a is the port number, -d is the destination for this proxy connection.

$ proxytunnel -a 1986 -d

proxytunnel will maintain the connection even after the syncdaemon client exit.


You can use connect-proxy which is available in Ubuntu repository. The argument to -H is the host:port of the proxy. In your case that might be the IP address of the proxy server. The argument to -p command is the port number you picked earlier. The remaining arguments are the host and port number which will be contacted through the proxy. is the Ubuntu One server for syncdaemon and 443 is the port it is listening to.

$ connect-proxy -H localhost:3128 -p 1986 443

Now start syncdaemon. You will find the following in the logs:


2010-01-26 10:47:41,101 - ubuntuone.SyncDaemon.ActionQueue - INFO - SRV lookup error, fallback to '':1986 
Traceback (most recent call last):
Failure: twisted.names.error.DNSNameError: <twisted.names.dns.Message instance at 0xa4966ac>

2010-01-26 10:47:41,104 - ubuntuone.SyncDaemon.ActionQueue - DEBUG - connection made
2010-01-26 10:47:41,105 - ubuntuone.SyncDaemon.EQ - DEBUG - push_event: SYS_CONNECTION_MADE, args:(), kw:{}

The disadvantage is that connect-proxy and proxytunnel is binding to all interfaces -

tcp        0      0  *               LISTEN     

aka it is listening on all IPs, this cannot be configured and this is bad for hostile network setups. In the worst case, people might use your host to connect to ubuntuone file sync service.

Another issue is that REST API calls from syncdaemon are not passing through the proxy-aware code so that publishing/unpublishing the files will not work properly.


No solution found so far

See also

RomanYepishev/UbuntuOne/ProxySupport (last edited 2010-11-10 10:27:15 by host-60-59-151-193)