Im trying to enable MFA for an existing AWS Cognito user pool.
Im editing the user-pool configuration, but trying to save the new configuration results in a MFA cannot be turned off if an SMS role is configured
error (see picture). I don't understand that error message, and Google is no help.
Question: What am I do wrong, how can I enable MFA for an existing user pool?
Multi-factor authentication (MFA) increases security for your app. It adds a something you have authentication factor to the something you know factor of user name and password. You can choose SMS text messages or time-based one-time passwords (TOTP) as second factors to sign in your users.
Go to AWS Cognito service and click “Manage Identity Pools”. 2. Enter “Identity pool name”, expand the “Authentication providers” section and select “Cognito” tab. This is where the Cognito authentication provider will be registered with the Identity pool.
Amazon Cognito enables simple, secure user authentication, authorization and user management for web and mobile apps. With Cognito, a user or visitor can sign in with a username and password through Amazon, or through a third party like Facebook, Google or Apple.
Go to IAM and make sure you didn't accidently created an SMS role. Under the step :
You must provide a role to allow Amazon Cognito to send SMS messages
If you press Create Role then this will generate the error you mentioned. I guess in order to continue you need to properly configure your SMS.
To solve this issue I had to remove an SMS role (IAM) linked to my Users Pool.
So by removing the SMS role I was able to continue the creation of the new User Pool.
You can do that by signing to your console. Go to IAM on the left side under the dashboard go to Roles. Select from the list the SMS role associated to your User pool and delete it.
The SNSRole is added automatically, can't be changed by any available parameter and can't be modified later. The current workaround is to manually modify the yaml configuration and remove that part.
from: https://github.com/aws-amplify/amplify-js/issues/2906
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With