rohityadavcloud commented on issue #145: URL: https://github.com/apache/cloudstack-cloudmonkey/issues/145#issuecomment-2011832202
Ideally the improvement in `cmk` would be to do the following: 1. This applies only when username and password is provided, upon login the response contains whether 2FA is enabled or not: { "loginresponse": { "username": "rohit", "userid": "9e9ba412-d3ca-4bf4-aead-768c0b09531f", "domainid": "d3806260-e766-11ee-b2c1-525400b612b4", "timeout": 1800, "account": "rohit", "firstname": "Rohit", "lastname": "Yadav", "type": "0", "timezone": "UTC", "timezoneoffset": "0.0", "registered": "false", "sessionkey": "9Gyo6QrVnC4UNd_S9Em64rjlBwE", "is2faenabled": "true", "is2faverified": "false", "providerfor2fa": "totp", "issuerfor2fa": "CloudStack" } } 2. Next, the validate API should be called after taking user input of the 2FA code such as: URL: http://172.20.0.86:8080/client/api/?codefor2fa=217258&command=validateUserTwoFactorAuthenticationCode&response=json Query String Parameters must pass: codefor2fa: 217258 command: validateUserTwoFactorAuthenticationCode 3. Upon successful code the following is returned, otherwise cmk may prompt additional input: { "validateusertwofactorauthenticationcoderesponse": { "success": true } } -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: dev-unsubscr...@cloudstack.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org