Files for Signed cookie-based authentication with Amazon CloudFront and AWS Lambda@Edge + Email Logging

0

I'm trying to follow the demo in the blog posts:

  1. Signed cookie-based authentication with Amazon CloudFront and AWS Lambda@Edge: Part 1 -Authentication and
  2. Signed cookie-based authentication with Amazon CloudFront and AWS Lambda@Edge: Part 2 – Authorization

However, there aren't any files provided for login.html, restricted-content.html, and assets/*.

My questions are:

  1. How could I find these .html files, or how could I create these files on my own?
  2. How could I modify the Lambda@Edge function if I wanted to log the email addresses to a file in an S3 bucket?
1개 답변
0

Hi Nathaniel, thanks for asking this question on re:Post!

Where to find missing files:

The main emphasis of the blog posts is on setting up the authentication and authorization mechanisms. The HTML pages and assets serve to contextualise the authentication process and showcase its functionality. You're encouraged to align your application's HTML pages, assets, design and other requirements with the contents of the blog post.

You can introduce any additional JavaScript, CSS, or other assets as needed for your specific implementation. The primary takeaway is that the provided authentication and authorization setup can be seamlessly integrated with your chosen HTML and UI frameworks to develop a comprehensive web application with secure access controls.

Modifying Lambda@Edge for Logging:

When you want to keep track of email addresses, you have different ways to do it, depending on your use-case. On S3, you can, for example create a separate object for each email, or store all emails in one file, adding new ones as they come, making a big list.

Which way you pick depends on how you want to use the email records, like if you need to look at them later, how often you'll be adding new emails, and how important it is to keep track of the history. You can also consider using a database such as DynamoDB instead of an object to facilitate easier querying your records for your specific needs.

AWS
Piotrek
답변함 8달 전

로그인하지 않았습니다. 로그인해야 답변을 게시할 수 있습니다.

좋은 답변은 질문에 명확하게 답하고 건설적인 피드백을 제공하며 질문자의 전문적인 성장을 장려합니다.

질문 답변하기에 대한 가이드라인

관련 콘텐츠