This bash script will grab S3 assets using IAM credentials.
From within the IAM based ec2 image, pull down this repository
git clone http://github.com/tnoeding/s3iamget.git
cd into the directory
cd s3iamget
make sure the script can run
chmod +x s3iamget.sh
run the s3iamget.sh script with the proper arguments
./s3iamget.sh <bucketname> <bucketlocation>
EXAMPLE
./s3iamget.sh testbucket dir1/dir2/file.txt