Skip to content

Can customer programmatic access to S3 objects be direct to S3?

0

We are contemplating a design where we create S3 objects containing data files for our customers to download, and are trying to understand what options we have for those customers that use their own automated back-end systems (not in AWS, in many cases) to programmatically download these files. Maintaining a directory of users and using S3 Access Grants specifying the granular access each user has across specific S3 objects sounds appealing, if some of the users are allowed to represent the customers' back-end systems.

The S3 Access Grant documentation appears to focus on an application working with credentials in order to prepare for actual S3 download:

With these S3 Access Grants capabilities, applications can request data from Amazon S3 on behalf of the application's current authenticated user.

But it's not clear to me whether this is always an application I own and trust, that customers must access S3 through, or whether this can be an application the customers own, that I do not trust. There are code snippets of pieces of this process, Request access to Amazon S3 data through S3 Access Grants and Use GetObject with an AWS SDK or CLI, but without a complete working sample client, it's hard to understand whether this is an approach that untrusted customer applications can use to access my S3 resources.

In short, is S3 Access Grants always meant to have my application standing in front of it? Or can it work with customers building their own applications?

Thanks!

1 Answer
0

S3 Access Grants can indeed work with customers building their own applications, allowing for direct programmatic access to S3 objects without requiring your application to stand in front of it. However, there are some important considerations to keep in mind.

S3 Access Grants provides a way to grant access to S3 data for both IAM identities and corporate directory identities. This means you can set up access for your customers' backend systems, even if they are not in AWS, by creating appropriate grants.

When using S3 Access Grants, the process typically involves the following steps:

  1. Authentication: The user or system authenticates with their identity provider.
  2. Token Exchange: The authenticated identity is used to obtain temporary AWS credentials.
  3. S3 Access: These credentials are then used to access S3 objects directly.

For customers with their own automated backend systems, you can set up S3 Access Grants to allow their systems to access specific S3 objects or prefixes. This can be done by associating their identity (which could be an IAM user or role, or an identity from a supported corporate directory) with the appropriate grants.

It's important to note that while S3 Access Grants simplifies managing access at scale, you still need to ensure proper authentication and authorization. Your customers' applications would need to implement the necessary steps to authenticate and obtain the required tokens before they can access S3 directly.

To address your concern about trusting customer applications, S3 Access Grants allows you to define fine-grained permissions. You can specify exactly which S3 resources (buckets, prefixes, or objects) each identity can access, and what operations they can perform (read-only, write-only, or read-write).

Additionally, S3 Access Grants integrates with AWS CloudTrail, providing detailed audit logs that include the end-user identity and the application used to access S3 data. This gives you visibility into who is accessing your data and how, even when the access is coming from external applications.

In summary, while the documentation may focus on scenarios involving your own trusted applications, S3 Access Grants can indeed be used to allow direct programmatic access from your customers' backend systems. You maintain control over the access through granular permissions, and you get detailed auditing capabilities. However, you'll need to carefully design your authentication and authorization flow to ensure secure access for these external systems.
Sources
Managing access with S3 Access Grants - Amazon Simple Storage Service
Access control in Amazon S3 - Amazon Simple Storage Service
S3 Access Grants and corporate directory identities - Amazon Simple Storage Service

answered a year ago

You are not logged in. Log in to post an answer.

A good answer clearly answers the question and provides constructive feedback and encourages professional growth in the question asker.