Non-interactive ALB Authentication without UI form?

Viewed 143

AWS ALB performs a 302 redirection to a UI form for login. This use case doesn't apply to me, as I need to implement login strictly in a non-interactive way.

Is there a way to just login to ALB in a non-interactive way, without the default 302 redirection?

Alternatively, I'm able to login using AWS Cognito just fine. Is there a way for ALB to just accept a token from a Cognito login?

1 Answers

We are currently putting an API Gateway that does pure pass-through of the requests in front of the ALB, and using a Lambda authorizer. We then have the option for the non-interactive calls to generate a JWT through API calls to our IdP and then pass that as a bearer token to be verified by the Lambda authorizer. We can then use this same authorizer to do OIDC Flow with the 302 redirects to do auth for interactive users. I'm currently looking for a different solution as the API Gateway feels redundant and only needed for authentication in our solution. However, I thought I'd leave this here since there are no answers so far.

Related