I am just learning the Python API so bear with me. A strange text box appears before the password prompt (appears twice). Not sure what is causing it.
I enter the password four times
The text boxes are a result of calling getpass() twice. The getpass() function prompts for user input without revealing it in plaintext. If you don't mind me asking, what is the goal of this script? Do you wish to authenticate to both the target and source portal anonymously? If so, there is no need to use the getpass() function.