Skip to content

Instantly share code, notes, and snippets.

@Moos1e
Created February 24, 2020 04:37
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Moos1e/1914b15ffaab1f61e56721ee1029c2f5 to your computer and use it in GitHub Desktop.
Save Moos1e/1914b15ffaab1f61e56721ee1029c2f5 to your computer and use it in GitHub Desktop.
#!/bin/bash
while read F ; do
count=$(curl $1/$F -s | grep -E "NoSuchBucket|InvalidBucketName" |wc -l)
if [[ $count -eq 0 ]]
then
echo "Bucket Found: "$F
fi
done < $2
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment