Server Fault is a question and answer site for system and network administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

gvfs (gnome virtual file system) felt the need to reimplement some of the common filesystems. I'm trying to get people onto our WebDAV shares, but I'm getting pretty cryptic errors.

What I'd like to do is setup gvfs to use a proxy, so I can use Charles to see what's going on.

How can I easily do this?


share|improve this question
Can you please add 'webdav' tag? – Peter Štibraný May 13 '09 at 18:02
up vote 1 down vote accepted

I don't know gvfs, or whether it supports proxy or not. But simple way to "force" proxy is to setup Charles as reverse proxy, and let your webdav client connect to proxy instead.

For example, suppose that Charles runs on "proxy" host and webdav is at "webdav" host. Setup Charles to do reverse-proxy on port 80 and to forward traffic to webdav:80 ("reverse proxy" is available in menus). Then instead of connecting your clients to "webdav", let them connect to http://proxy/ instead.

There are few caveats when doing reverse-proxy with WebDAV. You need to rewrite not only Host: header (which Charles do for you), but also Destination: and If: headers. Destination: is used when copying or moving files, while If: is used to verify that file is still locked. Fortunately, Charles supports rewriting any header ... look for Tools > Rewrite, you can put there quite general rules for rewriting. What you need to do is rewrite host part of absolute URLs in those headers from "proxy" to "webdav". (Simple s/proxy/webdav/ will work for testing) There is great summary by Julian Reschke about the webdav and reverse proxy issues if you're interested ;-)

(If you can make gvfs use proxy by itself, then you can avoid troubles with header-rewriting ... but I was not able to make WebdavFS on Mac to use proxy, so this was useful for me).

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.