Magneto Cat
Magneto Cat

Reputation: 35

Amazon S3 file storage via Rest API in C# with roles

I'm building a project that will use Amazon S3 to store documents. In particular there are two apps:

...so the public app should only have 'write' permission, and the admin tool 'read' and 'list' permissions.

The coding for this project will be done with ASP.NET and C#, and the preference is to use S3's REST API. This use case (uploading, listing and downloading documents) seems pretty basic, but I haven't had much luck finding simple examples. Can some you suggest some links?

Upvotes: 2

Views: 2878

Answers (1)

Norm Johanson
Norm Johanson

Reputation: 3177

If you install the AWS SDK for .NET from http://aws.amazon.com/sdkfornet it will also put down a sample S3 application at C:\Program Files (x86)\AWS SDK for .NET\Samples\AmazonS3Sample\AmazonS3Sample that will show the basic CRUD operations for S3.

As far as permissions go you should take a look at Identity and Access Management with AWS, http://aws.amazon.com/iam/. Using this service you can create different users with profiles that restrict access. So you could create one user for your public application that only has write access and even restrict write to a specific S3 bucket. Then create another user for admin application that has more admin permissions.

Upvotes: 3

Related Questions