Good afternoon, here I have the code:

import paramiko ssh = paramiko.SSHClient() ssh.set_missing_host_key_policy(paramiko.AutoAddPolicy()) ssh.connect('ip', username='usr', password='pass') stdin, stdout, stderr = ssh.exec_command('echo "LOL"') output = stdout.readlines()[0].rstrip('\n').rstrip('\r') print(output) ssh.close() 

How do I make the connection happen through a proxy? I will be very grateful.

  • Do you want to tunnel ssh through http proxy with support for the CONNECT command or something else? - jfs
  • Yes, that would be a connection that is not through my ip, but through a connected proxy - Corle
  • related question: how to ssh over http proxy in python? (response summary: create a simple TCP socket, execute http CONNECT, transfer the created socket to paramiko). - jfs

0