Tag Archives: WebDAV

iCloud Bookmarks: WebDAV + XBEL format

Just a few small notes and random thoughts.

iCloud Bookmarks are stored in WebDAV, as evidenced by the name of the syncing process: SafariDAVClient. Some googling revealed that you can find out the URL by opening the ~/Library/Safari/Bookmarks.plist file. (If you don’t have Xcode, convert it using plutil -convert xml1.) Each bookmark has a remote XBEL file associated with it; so just cut the part of the URL up to and including .../bookmarks.

Now you have URL you can browse using a WebDAV client. I didn’t have any success with Cyberduck; I kept getting ‘Unauthorized’ error. I presume it’s confused by the @ symbol in the username (the email address, y’know), but I don’t know.

Mac OS X’s built in WebDAV client (also known as ‘Finder’s WebDAV client’) can correctly mount the remote filesystem; but you can’t view the file list in Finder. Once it’s mounted, listing it through Terminal works very well.

It’s interesting that XBEL appears to originated within the Python community, as evidenced in its XML namespace: http://www.python.org/topics/xml/xbel/.

Apple really, really, REALLY likes to use existing standards wherever possible. The original push notification system was done via XMPP, for example, but noone dug deep into it; and FaceTime is suspected to be RTP deep inside. The strategy may be embrace, extend and lock down, but it’s ok. If I start having problem with it, the data is still accessible, I can still take it out.

And not just because they use WebDAV and XBEL for their cloud storage, but because I actually have the data on my local machine. Which brings me to another topic: knowing they use WebDAV and XBEL would have been useless, since you ordinarily would not be touching that directly. It would have been far better to actually mess with Safari, whose bookmark sync support is more-or-less documented. Via SyncServices.framework. Except it is not. Since that magical underused technology has been deprecated in 10.7.