I have to automate login into Citrix VDI but it has two-factor authentication which has two options.
1.) Send OTP code in Mobile SMS
2) Get a call on mobile and click a particular number as per instruction
Please help me on this how can I automate this so I can make Unattended robot.
Two-Factor authentication is pretty hard, but might be doable. The issue is you need to get the code from the phone to the desktop. The only option I can think of is as follows:
Desktop
login to citrix up to the point a code is sent to the mobile phone
Mobile
connect the phone to the same desktop, and install a remote viewer app, like TeamViewer or some other.
add a delay to make sure the text message gets there
next steps could be done with ComputerVision or (I guess) Mobile automation
you’ll need to find a way to “open” the phone, like pressing the home button. I think the mobile remote app should have some way of triggering those hardware buttons.
using CV or Mobile automation unlock the phone by entering the PIN# (should be easier if the phone authentication is with a PIN than with the swipy thing android has)
go to text messages
go to the contact that sent the Citrix auth code
scrape the area of the screen that contains the message
do some string manipulation on it to get only the code