Welcome to the Lab Guide for the Secure API Gateway Endpoints with Custom Authorizers!
In this Lab, you will learn how to implement a custom authorizer in AWS Lambda to secure your API Gateway Resources.
Below are the steps that I have taken to pass the reported step: Creating a Simple API Gateway Endpoint
- Ensure the lab environments have loaded 100% before starting:
- Log into the AWS console using the given credentials for the lab session.
- Proceed to step: Custom Authorizer Use Cases and read the details. Once done proceed to the next step.
- Once on this step: Creating a Simple API Gateway Endpoint
- Go to Lambda service and create a function:
- In the Author from scratch form, enter the following values before clicking Create function:
- Name: HelloWorld
- Runtime: Select Node.js 14.x (The latest version of Node.js 14)
- Click Change default execution role
- Select Use an existing role, Existing role: Select lambda_basic_execution:
- Click Create function and you will be able to create the function successfully:
- Scroll down to the Code source section, double-click the index.js file, and overwrite the contents with the provided code in the instructions:
- Once done, click deploy:
- Now go to the functions view and add a trigger: In the Trigger configuration panel, choose REST API as Choose a template option and select Open under Security:
- Click Add in the lower-right corner of the Trigger configuration panel.
- You should now pass both checks:
Note that our policies are very strict and any small change can compromise the lab. Ensure you selected the correct region and that all settings, values, and names are exactly as described in the instructions.
Take a look at our Help Center article Troubleshooting Problems With Labs.
Comments
0 comments
Please sign in to leave a comment.