Chapter 8. Designing an authentication service
This chapter covers
- Designing a sample event-driven application
- Interacting with your users via JavaScript
- Sending emails from Lambda functions
- Storing data in Amazon DynamoDB
- Managing encrypted data
In the previous chapter you learned how to use standalone Lambda functions from different client applications:
- A web page, using JavaScript
- A native Mobile App, with the help of the AWS Mobile Hub to generate your starting code
- An Amazon API Gateway to generate server-side dynamic content for web browsers
Now it’s time to build your first event-driven serverless application, using multiple functions together to achieve your purpose. Your goal is to implement a sample authentication service that can be used by itself or together with Amazon Cognito with developer-authenticated identities.
Note
The authentication service you’re going to build is an example of an event-driven serverless application and hasn’t been validated by a security audit. If you need such a service, my advice is to use an already built and production-ready implementation, such as Amazon Cognito User Pools.
You’ll define the architecture of your serverless back end built with AWS Lambda. In the chapter after this one, you’ll implement all the required components. The first step is to define how your users interact with the application.