As I’ve been playing with some Amazon S3 Buckets I stumbled upon the XML index in the root of S3 buckets that is exposed when the bucket is set to public. As an experiment I extended a ruby script written by Rodrigo De Castro to download the files listed in the root XML and recreate the directory structure that is present in the bucket.

I’ve posted the modified script for everyone to enjoy to the S3 Bucket Downloader repo on github.