0

My company requires a passcode when SSHing to a server:

ssh myserver
Enter a passcode or select one of the following options:

Passcode:

I want call SSH in the background from a GUI so want to detect when a passcode is requested and prompt the user, then pass the passcode to SSH.

I've tried Paramiko, but we have a super complicated cert process that would require a lot of custom code (I've tried). I've also tried pexpect.popen_spawn with no luck.

Is there any way to capture ssh output/supply ssh with input on windows + python?

0

Browse other questions tagged or ask your own question.