Issue with AWS S3 Authentication

Hey guys, how are you?

I’m trying to integrate n8n with AWS S3, I performed the connection through Postman, so I validated the key, secret and permissions I have in the bucket.

I created the AWS credential informing the region us-west-2, the pair of key and secret and tested the connection, that was tested successfuly.

Then I tried to connect with this bucket in a workflow, I’m getting the following error:

ERROR: Forbidden - perhaps check your credentials?

AccessDenied Access DeniedKZGEVHJ8RPVMBKMBtjQavvVNvacnl5ixcaztyJUeGtoMk8JdOkqldBD/bHUqrzqKQ6EDOQpJlWlKCXHjWqFSs0IOx9s=

With the following Stack:

NodeApiError: Forbidden - perhaps check your credentials?
    at Object.requestWithAuthentication (/root/.nvm/versions/node/v18.14.1/lib/node_modules/n8n/node_modules/n8n-core/src/NodeExecuteFunctions.ts:1607:10)
    at processTicksAndRejections (node:internal/process/task_queues:95:5)
    at Object.awsApiRequestSOAP (/root/.nvm/versions/node/v18.14.1/lib/node_modules/n8n/node_modules/n8n-nodes-base/nodes/Aws/S3/GenericFunctions.ts:85:19)
    at Object.execute (/root/.nvm/versions/node/v18.14.1/lib/node_modules/n8n/node_modules/n8n-nodes-base/nodes/Aws/S3/AwsS3.node.ts:698:22)
    at Workflow.runNode (/root/.nvm/versions/node/v18.14.1/lib/node_modules/n8n/node_modules/n8n-workflow/src/Workflow.ts:1261:19)
    at /root/.nvm/versions/node/v18.14.1/lib/node_modules/n8n/node_modules/n8n-core/src/WorkflowExecute.ts:949:29

This is the AWS S3 node

Can you help me?

I’m runnin n8n self hosted version 0.221.2

Hey @MCARVALHO,

Welcome to the community :cake:

When using the API from Postman did you also try listing the contents of that bucket? It looks like AWS is returning the access denied message although I am not sure why, Normally I would assume the region is incorrect or there is some kind of permission missing on the credential being used.

Hi Jon, yes I can list all the bucket contents.

Do you have any special ACLs / rules in place? I will need to double check but I think we use the soap api so if that is disabled it will likely show errors. It could be worth checking the logging in AWS to see if it shows anything as well.

No, the EC2 instance that n8n is hosted has outbound traffic all liberated.
The S3 is not in our infraestructure, we are enabling a partnership with AWS, so we are integrating our CRM with their, this integration will work through an EDI with their S3, I will perform other test here and ask them to check the permissions we have in their S3.

1 Like

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.