Accessing Northwestern Box on Linux
Box Sync for Linux is unavailable with Northwestern Box. However, this document offers steps in accessing files and folders via HTTPS and WebDAV/DAVFS. Credit to Indiana University" for assistance with this article.
Note: Before you can use WebDAV or DAVFS with your Northwestern Box account, you must first create an external password.
- Log into your Northwestern Box account with your NetID and password.
- This link provides the convenience and security of Single Sign-On (SSO) with your Northwestern NetID.
- While the web interface may not be ideal for all applications, it gives you basic access to configure your account, as well as the ability to upload and download files.
WebDAV access (cadaver)
- You can use cadaver, a command-line WebDAV client, to access Northwestern Box:
- cadaver https://dav.box.com/dav
- When prompted for a username, enter your full email address (e.g. firstname.lastname@example.org) and then provide your external password.
- Once logged in, you can use a number of cadaver commands, such as ls, get, and put.
- Type help for a list of commands
- Type help [command] for help with an individual command.
- While cleartext passwords should never be placed in files, you can set usernames and passwords for cadaver via the ~/.netrc configuration file login and password tokens.
- This allows unattended upload and download of files, and could be used for things such as scripting and cron jobs.
- For details, see .netrc in the cadaver main page.
WebDAV access (nautilus)
- You can use the nautilus file manager in Gnome to access Northwestern Box.
- Options depend on local system configuration; contact your local IT support for assistance.
- Note: Using WebDAV with nautilus on Red Hat Enterprise Linux 6 is currently not recommended. However, nautilus appears to be fine on other Linux platforms, including Ubuntu and Red Hat Enterprise Linux 5.
- You can use davfs2 to mount your Northwestern Box content onto a directory, giving you transparent filesystem access.
- Note: Using davfs2 with Box on Red Hat Enterprise Linux 6 is currently not recommended.
- Note: The administrator setup steps require root/sudo privileges; contact your local IT support for assistance.
- Install the davfs2 package. These instructions require version 1.4.7 or later.
- Note: The version available for Red Hat Enterprise Linux 6 from the RPMforge repository is 1.4.6 and will not work as described here.
- Create a directory that will be used as the mount point.
- Add the user to the davfs2 group.
- Add the use_locks 0 configuration option to /etc/davfs2/davfs2.conf.
- Add an entry to /etc/fstab that looks like: https://dav.box.com/dav/ /home/username/box davfs rw,user,noauto 0 0
- Copy the /etc/davfs2 directory to .davfs2 in your home directory: $ cp -r /etc/davfs2 ~/.davfs2
- Note: You'll get a "permission denied" error on the secret file but you can ignore it.
- In the .davfs2 directory, create a file named secrets that contains a single line and uses one of the following formats:
- https://dav.box.com/dav box_username
- https://dav.box.com/dav box_username "box_password"
- box_username is your username for the Northwestern Box service (e.g., email@example.com), and box_password is your external Box password.
Note: You must run $ chmod 600 ~/.davfs2/secret to mount using davfs2.
DAVFS mounting and unmounting
- After you've completed the setup, you can mount and unmount your Box filesystem as follows:
- To mount: mount /home/username/box
- To unmount: unmount /home/username/box
- The argument to the mount and unmount commands must exactly match the second entry on the line added to /etc/fstab above.
- You are strongly advised to unmount the filesystem when you're not using it.