Webdav and url-encoding



Greetings,

I am trying to get gnome-vfs to list a directory on a
webdav-enabled server.  The url is 

  http://superbeast.ucsd.edu/~landry/ArX/{archive}

If I just use that as the url, it fails, giving me errors like

  PROPFIND:2: parser warning : xmlns:D: 'DAV:' is not a valid URI
  <D:multistatus xmlns:D="DAV:">
                               ^
  PROPFIND:3: parser warning : xmlns:lp0: 'DAV:' is not a valid URI
  <D:response xmlns:lp0="DAV:" xmlns:lp1="http://apache.org/dav/props/"; xmlns:i0="
  ...

That is odd, but if I url-encode the brackets "{" and "}" by looking at

  http://superbeast.ucsd.edu/~landry/ArX/%7barchive%7d

It gives me the warnings, but at the end it does give me the directory
listing.  So now if let gnomevfs do the encoding by calling the
gnome_vfs_escape_host_and_path_string function, it converts the
original url into

  http://superbeast.ucsd.edu/~landry/ArX/%7Barchive%7D

(note the capital letters) and that fails (after giving me the
warnings).

But then it gets more interesting.  If I try to list

  http://regexps.srparish.net/{archives}/lord emf net--2003/

then it works if I encode the brackets "{" and "}", but not if I
encode "@".

So in the end, I guess my question is, what is the proper way to take
a raw string and list the contents of a webdav directory?

This is using gnome-vfs-2.5.0.  I get similar results 2.4.1 on debian
testing (2.4.1).  The version on redhat 9 (2.2.2) doesn't give me the
warnings, but it does give me the url-encoding problems.

Thanks,
Walter Landry
wlandry ucsd edu




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]