ssh-agent.py 338 B

1234567891011121314151617
  1. #!/usr/bin/env python3
  2. import os
  3. import subprocess
  4. import sys
  5. ssh_proxy = os.path.join(os.path.dirname(__file__), "ssh-proxy.py")
  6. argv = [
  7. os.environ.get("__SSH_PROGRAM_NAME__", "ssh"),
  8. "-o",
  9. "ProxyCommand={} %h %p".format(ssh_proxy),
  10. "-o",
  11. "Compression=yes",
  12. ]
  13. subprocess.call(argv + sys.argv[1:], env=os.environ)