pimcore-members icon indicating copy to clipboard operation
pimcore-members copied to clipboard

[AWS S3] It is not possible to download protected assets with AWS S3

Open aarongerig opened this issue 2 years ago • 0 comments

Q A
Bug report? yes
Feature request? no
BC Break report? no
RFC? yes

When you try to download an asset via a protected link (in a AWS S3 setup) it throws the following error:

request.CRITICAL:
Uncaught PHP Exception ErrorException: "User Warning: Error executing "GetObject" on "https://bucket-name.s3.eu-central-1.amazonaws.com/assetshttps";
AWS HTTP error: Client error: `GET https://bucket-name.s3.eu-central-1.amazonaws.com/assetshttps` resulted in a `404 Not Found` response NotFound (client): 404 Not Found (Request-ID: G0V9FEQ3ZT02SEG2)

<?xml version="1.0" encoding="UTF-8"?> <Error><Code>NoSuchKey</Code><Message>The specified key does not exist.</Message><Key>assetshttps</Key><RequestId>G0V9FEQ3ZT02SEG2</RequestId><HostId>bVouZKh8ba/Wg5Y4mlZ1Eq31xL+8z7v260lR4XdRKP6atg0EN8Bmcn0TXtgVTe6MeELYDPrulmY=</HostId></Error>" at /var/www/html/vendor/aws/aws-sdk-php/src/S3/StreamWrapper.php line 764

aarongerig avatar Nov 28 '22 08:11 aarongerig