Wednesday, May 8, 2013

How to map a secure WebDAV share on Windows XP

I was trying to sync my Box files at work, however as I'm sitting behind a proxy I was not able to do that (the default Box client does not support proxy settings). So I decided to try and mount it with WebDAV, like I did on Ubuntu.

The WebDAV client is installed by default in Windows XP, however it seems that ssl support was only introduced in Windows Vista. Not to worry, a simple workaround can get things working for us.

1- Download and install "stunnel". This will allow us to create a listener that will communicate with Box via an encrypted connection

2- Open "Start => All Programs => stunnel => stunnel GUI Start". This will start stunnel and add an icon to your  notification area

3- Right click on the stunnel icon on your notification are and select "Edit stunnel.conf"

4- Comment the unnecessary services (disable)

;accept  = 995
;connect = 110

;accept  = 993
;connect = 143

;accept  = 465
;connect = 25

5- Add the following lines and change the "connect" for the URL of the WebDAV server that you would like to connect. Then save the file

accept = 80
connect =
TIMEOUTclose = 0

6- Right click the stunnel icon in the notification area again and select "Show Log Window". This will allow us to see the requests when we try to mount the drive and possibly troubleshoot any issues

7- Click on "Configuration => Reload stunnel.conf"

8- Open command prompt and mount the drive the following command

NET USE [drive letter]: "http://localhost/[path]" /USER:[WebDAV username] [password]

NET USE B: "http://localhost/dav" /USER:[Box username] [password]

Note: use the option "/PERSISTENT:YES" if you would like this to stick after reboots

You should now be able to access your WebDav files using the drive letter.

No comments: