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
• 3,040 points
248 views

1 answer to this question.

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,560 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
2,815 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,940 points
444 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
92 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,440 points
5,960 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,940 points
302 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,940 points
678 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,560 points
475 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,560 points
77 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,560 points
10,310 views