added Amazon S3 support