okta-aws-cli-assume-role icon indicating copy to clipboard operation
okta-aws-cli-assume-role copied to clipboard

SMS MFA option is broken in v2.0.4 release

Open tmann-fuze opened this issue 4 years ago • 1 comments

I updated to v2.0.4 and while MFA Push was fixed, SMS still doesn't work for me.

----snippet----
# okta-aws lab sts get-caller-identity
Username: myusername
Password:

Multi-Factor authentication is required. Please select a factor to use.
Factors:
[ 1 ] : Okta Verify (Push)
[ 2 ] : SMS Verification
[ 3 ] : Google Authenticator
[ 4 ] : Okta Verify (TOTP)
Selection: 2
SMS Factor Authentication
Enter 'change factor' to use a different factor
Exception in thread "main" org.json.JSONException: JSONObject["sessionToken"] not found.
    at org.json.JSONObject.get(JSONObject.java:566)
    at org.json.JSONObject.getString(JSONObject.java:851)
    at com.okta.tools.authentication.OktaMFA.verifyAnswer(OktaMFA.java:287)
    at com.okta.tools.authentication.OktaMFA.smsFactor(OktaMFA.java:166)
    at com.okta.tools.authentication.OktaMFA.getSessionToken(OktaMFA.java:97)
    at com.okta.tools.authentication.OktaMFA.promptForFactor(OktaMFA.java:64)
    at com.okta.tools.authentication.OktaAuthentication.getOktaSessionToken(OktaAuthentication.java:87)
    at com.okta.tools.saml.OktaSaml.getSamlResponse(OktaSaml.java:47)
    at com.okta.tools.OktaAwsCliAssumeRole.doRequest(OktaAwsCliAssumeRole.java:132)
    at com.okta.tools.OktaAwsCliAssumeRole.run(OktaAwsCliAssumeRole.java:102)
    at com.okta.tools.WithOkta.main(WithOkta.java:30)```

tmann-fuze avatar Sep 24 '19 13:09 tmann-fuze