Configuring a WebDAV share on https://webdav.csail.mit.edu

Limitations

WebDAV, for Distributed Authoring and Versioning, is a protocol for performing arbitrary edits/modifications to files located on a web server. TIG provides the webdav facility with the expectation that it will be used only by account owners and close collaborators to transfer/synchronize data. Specifically, take care to ensure that your share on webdav.csail.mit.edu does not allow anonymous access, and that usernames and passwords used to access it are not disclosed publicly.

Please do not use webdav.csail.mit.edu for iCal or Subversion repositories. Use ical.csail.mit.edu for iCal access and svn.csail.mit.edu for SVN access instead.

NOTICE: webdav.csail currently does not support .htdigest format passwords, only .htpasswd. Changing this will require everyone to re-enter users passwords into .htdigest format. If .htdigest support is important to you, please email help@csail and we will consider (re)scheduling a transition.

Directories

You can set up WebDAV within space belonging to yourself (/afs/csail/u/y/you), a group (/afs/csail/group/yourgroup), or a project (/afs/csail/proj/someproject). The appropriate directory is referred to as $DIR below.

Setup

From a unix prompt with AFS access (CSAIL Debian, Ubuntu, Mac OS...):
  1. change to the top level of the user, group, or project directory: cd $DIR
  2. mkdir -p webdav
  3. fs sa webdav webdav write
  4. make sure $DIR allows webdav to list its subdirectories:
    • If the output of fs la $DIR includes the line system:anyuser l or system:authuser l, you're already OK
    • If not, run fs sa $DIR webdav l

Finally, specify the usernames and passwords that will be able to access the share.
  • create the file webdav/.htaccess with the single line AuthUserFile /afs/csail.mit.edu/PATH/TO/webdav/.htpasswd
  • create the file webdav/.htpasswd to restrict access to username & password pairs. That is, run
$ htpasswd -c .htpasswd username1
New password:
Re-type new password:
Adding password for user username1
for more detail on .htaccess and .htpasswd in general, see: Htaccess Hints#Restricting_access_using_basic_a.

Point your WebDAV client at the appropriate user, group, or project URL:
  • https://webdav.csail.mit.edu/~$USERNAME/
  • https://webdav.csail.mit.edu/groups/$GROUPNAME/
  • https://webdav.csail.mit.edu/projects/$PROJECTNAME/
Note that only https:// is available (not http://), and that the tilde (~) is required for user WebDAV stores.

Troubleshooting

  • No username or password is accepted
    • Make sure your .htaccess file properly specifies an AuthUserFile -- if it does not, all logins will be rejected
  • Other problems (including 500 Internal Server Error)
    • Check the error log for clues: ssh webdav.csail.mit.edu tail /var/log/apache2/error.log

Clients

  • git
  • FoxMarks/XMarks
    • try appending /bookmarks.json to the path in Advanced -> Server
  • Zotero
    • Tools -> Add-Ons -> Zotero -> Preferences -> Sync -> Settings -> File Syncing -> Sync attachment files using: WebDAV
    • No known way to save the reference database itself to WebDAV
  • Transmit (MacOS, commercial)
    • Server: webdav.csail.mit.edu
    • Protocol: WebDAV HTTPS
    • Remote Path: /~$USERNAME/ or /projects/$PROJECTNAME/ or /groups/$GROUPNAME/

  • Mac OS (for file transfer)
    • Install the CSAIL Master CA in Safari (stop after the first section of instructions)
    • Click the desktop, then click Go -> Connect to Server, and enter the WebDAV URL from above. A new window should appear with your files.
    • Slow performance? Try a dedicated file transfer client like CyberDuck or Transmit 3, and choose server type: WebDAV.
  • Linux (as filesystem)
    • look to install and use the davfs package.
  • Windows (as filesystem)
    • Install the CSAIL Master CA? in Internet Explorer (Steps 1-3)
    • Find "My Computer" aka "Computer" in the Start Menu or on the desktop. Right-click it, choose "Add Network Location" (or "Map Network Drive" -> "Connect to a Web site ... to store ...")
    • Enter the WebDAV URL from above. A new window should appear with your files.
    • Slow performance? Within Internet Explorer, click Tools -> Options -> Connections -> LAN Settings, and set "Automatically detect settings" to NO. Or try installing MS hotfix KB945435 for Vista.
    • "The folder...does not appear to be valid": try installing MS hotfix KB907306 for XP or Vista (and Windows 7)
Topic revision: 05 Aug 2016, JasonDorfman
 

MIT Computer Science and Artificial Intelligence Laboratory

 

  • About CSAIL
  • Research
  • News + Events
  • Resources
  • People

This site is powered by Foswiki MIT: Massachusetts Institute of Technology