How to create expiring URL links to Amazon S3 with ASP.net?

0 votes
I am exploring C# libraries like lits3 in my project. I want to know is if there is a way to create a signed URL which has expiration using ASP.net. I couldn't find any on researching? Any help here will be great.
Jan 25 in AWS by datageek
• 2,940 points
52 views

1 answer to this question.

Your answer

Your name to display (optional):
Privacy: Your email address will only be used for sending these notifications.
0 votes

Yes, there is a solution. Well, using the Amazon .net SDK you can get preSignedUrl.

using (AmazonS3 client = Amazon.AWSClientFactory.CreateAmazonS3Client("your access key ID", "you secret key")) 

{ 

                        GetPreSignedUrlRequest getPreSignedUrl = new GetPreSignedUrlRequest().WithBucketName(bucketName);                                    getPreSignedUrl.Key = key:

                        getPreSignedUrl.Expires = DateTime.Now.AddSeconds(60);

}

answered Jan 25 by Archana
• 5,360 points

Related Questions In AWS

0 votes
1 answer

How do I create folder under an Amazon S3 bucket through PHP API?

Of Course, it is possible to create ...READ MORE

answered Apr 24, 2018 in AWS by anonymous
1,757 views
0 votes
1 answer

How to copy .csv file from Amazon S3 bucket?

Boto3 is the library to use for ...READ MORE

answered Jul 6, 2018 in AWS by Priyaj
• 56,140 points
296 views
0 votes
1 answer

How to upload a file to Amazon S3 without passing it my server?

This article pretty much explains the entire ...READ MORE

answered Aug 14, 2018 in AWS by Archana
• 4,090 points
42 views
0 votes
1 answer

How to list the contents of Amazon S3 by modified date?

One easy solution would be probably to ...READ MORE

answered Aug 21, 2018 in AWS by datageek
• 2,430 points
2,358 views
0 votes
1 answer

AWS S3 uploading hidden files by default

versioning is enabled in your bucket. docs.aws.amazon.com/AmazonS3/latest/user-guide/….... the ...READ MORE

answered Oct 4, 2018 in AWS by Priyaj
• 56,140 points
110 views
0 votes
1 answer

How to decrypt the encrypted S3 file using aws-encryption-cli --decrypt

Use command : aws s3 presign s3://mybucket/abc_count.png you get ...READ MORE

answered Oct 22, 2018 in AWS by Priyaj
• 56,140 points
221 views
0 votes
1 answer

Import my AWS credentials using python script

Using AWS Cli  Configure your IAM user then ...READ MORE

answered Nov 16, 2018 in AWS by Jino
• 5,520 points
136 views
0 votes
2 answers
0 votes
1 answer

How to create analysis with Amazon Quicksight?

The entire process is fairly simple.  Amazon QuickSight ...READ MORE

answered Nov 14, 2018 in AWS by Archana
• 5,360 points
34 views
–1 vote
1 answer

How to read a csv file stored in Amazon S3 using csv.DictReader

The code would be something like this: import ...READ MORE

answered Oct 25, 2018 in AWS by Archana
• 5,360 points
4,329 views

© 2018 Brain4ce Education Solutions Pvt. Ltd. All rights Reserved.
"PMP®","PMI®", "PMI-ACP®" and "PMBOK®" are registered marks of the Project Management Institute, Inc. MongoDB®, Mongo and the leaf logo are the registered trademarks of MongoDB, Inc.