12-21-2021 05:00 AM
Hello,
Either with Cognito or OIDC, is there any documentation or working case about setting up Duo as MFA gateway for an AWS ALB?
I’ve found documentation accomplishing the same thing with Okta, but I don’t get it to work completely.
Also, does Duo support acting as OIDC provider? (Okta does).
Thanks.
Solved! Go to Solution.
01-07-2022 05:57 AM
Hi @Ruben_Cardenal,
Let me try to translate the documentation I have internally related to this when I tested it out. Please note this is from 2019 so some of the AWS settings might have changed. This assumes you have nothing in Cognito yet so feel free to skip over the steps you’ve already done.
Log on to the Duo Admin Panel and navigate to Applications .
Click Protect an Application and locate the entry for Generic Service Provider with a protection type of “2FA with SSO hosted by Duo (Single Sign-On)” in the applications list. Click Protect to the far-right to start configuring Generic Service Provider. See Protecting Applications for more information about protecting applications in Duo and additional application options. You’ll need the information on the Generic Service Provider page under Metadata later.
Click Download XML under the metadata section to download the XML that will be used later.
Navigate to the Amazon Cognito page in AWS Management Console
Click Manage User Pools
Click Create a user pool
The Policies page leave all values at their default and click Next step
On the MFA and verifications page leave all values at their default and click Next step
On the Message customizations page leave all values at their default and click Next step
On the Tags page leave all values at their default and click Next step
On the Devices page leave all values (Set to No) at their default and click Next step
On the App clients page click Add an app client
On the Triggers page leave all values at their default and click Next step
On the Review page click Create pool
The page will refresh with new settings.
Make note of the Pool Id you will need this later.
Return to the Duo Admin Panel with your generic application open and populate the following fields:
Entity ID: urn:amazon:cognito:sp: + Pool Id
Example: urn:amazon:cognito:sp:us-east-1_8ULmhQ4vz
ACS URL: This will be your Cogntio Domain name + /saml2/idpresponse
Example: https://subdomain.auth.us-east-1.amazoncognito.com/saml2/idpresponse
NameID type : emailAddress
NameID value:: Whatever value you use for email. If using our standard bridge attributes select the <Email Address>
value from the drop-down.
Click Save at the bottom of the page.
Go to the EC2 Dashboard → Load Balancing → Load Balancers
Select the load balancer you created earlier and click on Listeners tab.
Next to the HTTP: 80 rule click View/edit rules
Click the pencil icon at the top of the screen
Click the pencil icon under the Rule name
Click the trash can icon under THEN . This deletes the current routing rule.
Click the “+ Add action” under the THEN and select Redirect to… from the dropdown. New options will appear
Click Update and Update again
Next to the HTTPS: 443 rule click View/edit rules
Click the pencil icon at the top of the screen
Click the pencil icon under the Rule name
Click the trash can icon under THEN . This deletes the current routing rule.
Click the “+ Add action” under the THEN and select Authenticate… from the dropdown. New options will appear
Click the “+ Add action” under the THEN and select Forward to… from the dropdown.
Click Update
12-21-2021 05:11 AM
Okay, I see that no OIDC support as of today (surprise…)
So the only way is Cognito+SAML.
12-29-2021 12:12 AM
Hello,
Paying customer, 150 licenses. Will I get a reply please?
Thanks.
01-06-2022 06:28 AM
Hi @Ruben_Cardenal,
Sorry for the long response time, most of Cisco was closed for the winter break. In the future I’d recommend directly contacting support if you have a question you’d like a faster answer to as those get tracked through a ticketing system and they are able to see your account details.
To answer your original question, Duo SSO does not currently support OIDC but we are actively working on developing it. In the meantime, you can definitely use Cognito + SAML using Duo SSO, I’ve done this before myself. You’ll need to make sure to create a generic SAML service provider in the Duo Admin Panel.
01-07-2022 12:30 AM
Hello Jamie,
Every time I open a support ticket it goes days and days and days and even weeks until I get some sort of initial reply. And other forum’s moderators said that it was better to ask here instead of opening support tickets or even contact you guys by phone for tech support tickets (…).
Anyway… moving on.
Yes, I know that Cognito+SAML works. But what I’m trying to achieve is AWS ALB + Cognito + SAML. I’ve found documentation for Okta about AWS ALB + OIDC, hence my OIDC question here.
Having Cognito + Duo is well documented:
but when I put that user pool behind an AWS ALB (and I have other ALB’s working perfectly with Cognito + Google IdP) it just doesn’t work.
Do you know of any implementation with AWS ALB + Cognito + SAML? Or can you or someone else assist me in this? I can provide screenshots of every single part involved. I also tried to setup the Network Gateway but that requires to triple our monlthy bill with you and, if we had to go to that point, we’d just go to Okta, because it would be cheaper ($7/user/month with Okta, $9/user/month with Duo).
Thanks.
01-07-2022 05:57 AM
Hi @Ruben_Cardenal,
Let me try to translate the documentation I have internally related to this when I tested it out. Please note this is from 2019 so some of the AWS settings might have changed. This assumes you have nothing in Cognito yet so feel free to skip over the steps you’ve already done.
Log on to the Duo Admin Panel and navigate to Applications .
Click Protect an Application and locate the entry for Generic Service Provider with a protection type of “2FA with SSO hosted by Duo (Single Sign-On)” in the applications list. Click Protect to the far-right to start configuring Generic Service Provider. See Protecting Applications for more information about protecting applications in Duo and additional application options. You’ll need the information on the Generic Service Provider page under Metadata later.
Click Download XML under the metadata section to download the XML that will be used later.
Navigate to the Amazon Cognito page in AWS Management Console
Click Manage User Pools
Click Create a user pool
The Policies page leave all values at their default and click Next step
On the MFA and verifications page leave all values at their default and click Next step
On the Message customizations page leave all values at their default and click Next step
On the Tags page leave all values at their default and click Next step
On the Devices page leave all values (Set to No) at their default and click Next step
On the App clients page click Add an app client
On the Triggers page leave all values at their default and click Next step
On the Review page click Create pool
The page will refresh with new settings.
Make note of the Pool Id you will need this later.
Return to the Duo Admin Panel with your generic application open and populate the following fields:
Entity ID: urn:amazon:cognito:sp: + Pool Id
Example: urn:amazon:cognito:sp:us-east-1_8ULmhQ4vz
ACS URL: This will be your Cogntio Domain name + /saml2/idpresponse
Example: https://subdomain.auth.us-east-1.amazoncognito.com/saml2/idpresponse
NameID type : emailAddress
NameID value:: Whatever value you use for email. If using our standard bridge attributes select the <Email Address>
value from the drop-down.
Click Save at the bottom of the page.
Go to the EC2 Dashboard → Load Balancing → Load Balancers
Select the load balancer you created earlier and click on Listeners tab.
Next to the HTTP: 80 rule click View/edit rules
Click the pencil icon at the top of the screen
Click the pencil icon under the Rule name
Click the trash can icon under THEN . This deletes the current routing rule.
Click the “+ Add action” under the THEN and select Redirect to… from the dropdown. New options will appear
Click Update and Update again
Next to the HTTPS: 443 rule click View/edit rules
Click the pencil icon at the top of the screen
Click the pencil icon under the Rule name
Click the trash can icon under THEN . This deletes the current routing rule.
Click the “+ Add action” under the THEN and select Authenticate… from the dropdown. New options will appear
Click the “+ Add action” under the THEN and select Forward to… from the dropdown.
Click Update
01-07-2022 10:15 AM
Hello jamie,
I had kind of the same already configured, but anyway began from scratch again following the guide you shown. At first it wasn’t working, but finally now I am able to do get to use Duo + Cognito with an ALB.
Thanks!
Would be nice, anyway, having OIDC because makes the process way easier to be setup.
Thanks!
05-11-2022 02:02 AM
Hello @jamie,
Could I ask up a follow-up question to this as we just recently set up DUO generic SSO to Cognito as well. How can we configure DUO generic SSO provider and Cognito so we can pass through what DUO groups a user is a member of? I can see “Role attributes” in DUO but not sure what to put in that section nor what to put on the Cognito side.
Cheers
Damien
Discover and save your favorite ideas. Come back to expert answers, step-by-step guides, recent topics, and more.
New here? Get started with these tips. How to use Community New member guide