KnowledgeHub
Questions
Tags
Users
Search
Alex Rivera
|
Logout
Edit Question
Title
Body
I'v got user with all permissions. { "Statement": [ { "Effect": "Allow", "Action": "*", "Resource": "*" } ] } I'm using aws-sdk-php-2 to put and copy objects in bucket. http://docs.aws.amazon.com/aws-sdk-php-2/latest/class-Aws.S3.S3Client.html Put code works perfect $client->putObject(array( 'Bucket' => 'kiosk', 'Key' => 'test/orders/test.csv', 'SourceFile' => $sourcePath, )); After check if object created on S3 via https://console.aws.amazon.com/s3 I'm executing next script. $result = $client->copyObject(array( 'Bucket' => 'kiosk', 'CopySource' => 'test/orders/test.csv', 'Key' => 'test/test.csv', )); And I'm getting fatal error: Fatal error: Uncaught Aws\S3\Exception\S3Exception: AWS Error Code: AllAccessDisabled, Status Code: 403, AWS Request ID: XXX, AWS Error Type: client, AWS Error Message: All access to this object has been disabled, User-Agent: aws-sdk-php2/2.2.1 Guzzle/3.3.1 curl/7.19.7 PHP/5.4.13 thrown in phar:///usr/share/pear/AWSSDKforPHP/aws.phar/src/Aws/Common/Exception/NamespaceExceptionFactory.php on line 89 After upload file manually console.aws.amazon.com/s3 I see different error when trying to copy: Fatal error: Uncaught Aws\S3\Exception\AccessDeniedException: AWS Error Code: AccessDenied, Status Code: 403, AWS Request ID: XXX, AWS Error Type: client, AWS Error Message: Access Denied, User-Agent: aws-sdk-php2/2.2.1 Guzzle/3.3.1 curl/7.19.7 PHP/5.4.13 thrown in phar:///usr/share/pear/AWSSDKforPHP/aws.phar/src/Aws/Common/Exception/Namespace
Tags (comma-separated)
Save Edits
Cancel