How to resolve Multi Factor authentication for AAD in Selenium test in CI

萝らか妹 提交于 2021-01-28 05:34:11

问题


I am trying to integrate Selenium tests to CI. The problem I am facing is all the users (even test user) is protected by Multi-factor authentication and when I will run test cases on the server with each login there will a prompt user for the Multi factor. We are running selenium test cases on SPA using adal-angular.js and adal.js How to resolve this issue? Is there any way to create a logical switch on API server or SPA to bypass the authentication prompt?

Thanks.


回答1:


You cannot do this directly. Frankly if you could, I would be very concerned about the security of MFA at all.

Having said that, there is probably a way to help move forward. An SMS Modem (i.e. https://www.diafaan.com/how-to/choose-gsm-modem/) you could register a SIM card with Test User and use the modem to parse the incoming MFA challenge.

Another alternative is to use 3rd pary messaging service (as Twilio) and register a dedicated incoming phone number. Then register that number with the MFA. Then use the Twilio API to parse the MFA challenge.



来源:https://stackoverflow.com/questions/48350590/how-to-resolve-multi-factor-authentication-for-aad-in-selenium-test-in-ci

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!