title: Client error (403) when downloading file from AWS S3 to local file
body: <p>I uploaded several .zip files to my AWS S3 bucket a while back using the AWS CLI. Now I can't seem to download those files when using the following command:</p>
  
  <pre><code>aws s3 cp s3://mybucket/test.zip test2.zip
  </code></pre>
  
  <p>because it yields the following error:</p>
  
  <pre><code>A client error (403) occurred when calling the HeadObject operation: Forbidden
  Completed 1 part(s) with ... file(s) remaining
  </code></pre>
  
  <p>How can I resolve this issue?</p>
  
  <p>Edit:</p>
  
  <p>Running the following command shows the existing bucket policies</p>
  
  <pre><code>aws s3api get-bucket-policy --bucket mybucket
  </code></pre>
  
  <hr>
  
  <pre><code>{
      "Policy": "{\"Version\":\"2012-10-17\",\"Statement\":[{\"Sid\":\"Example permissions\",\"Effect\":\"Allow\",\"Principal\":{\"AWS\":\"arn:aws:iam::221234567819:root\"},\"Action\":[\"s3:ListBucket\",\"s3:GetBucketLocation\"],\"Resource\":\"arn:aws:s3:::mybucket\"},{\"Sid\":\"Examplepermissions\",\"Effect\":\"Allow\",\"Principal\":{\"AWS\":\"arn:aws:iam::221234567819:root\"},\"Action\":[\"s3:PutObject\",\"s3:AbortMultipartUpload\",\"s3:PutObjectAcl\",\"s3:GetObject\",\"s3:DeleteObject\",\"s3:GetObjectAcl\",\"s3:ListMultipartUploadParts\",\"s3:PutObjectAcl\"],\"Resource\":\"arn:aws:s3:::mybucket/*\"}]}"
  }
  </code></pre>