Advertisement
Guest User

Untitled

a guest
Sep 15th, 2017
494
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.20 KB | None | 0 0
  1. Host target.machine
  2. User targetuser
  3. HostName target.machine
  4. ProxyCommand ssh proxyuser@proxy.machine nc %h %p 2> /dev/null
  5.  
  6. ssh target.machine
  7.  
  8. ssh -o "ProxyCommand ssh poxyuser@proxy.machine nc -w 1 %h 22" targetuser@target.machine
  9.  
  10. rsync -v --rsh "ssh proxy.machine ssh" target.machine:/remote/file /local/dir/
  11.  
  12. $ ssh -f -N -L <localport>:<target.machine:port> user@proxy.machine
  13. $ scp target-user@local.machine:/remote/file -P <localport> .
  14.  
  15. scp -o "ProxyCommand ssh pcreds@proxy.machine -W %h:%p" tcreds@target.machine:file .
  16.  
  17. Host target.machine
  18. ProxyCommand ssh pcreds@proxy.machine -W %h:%p
  19.  
  20. scp tcreds@target.machine:file .
  21.  
  22. scp -o "ProxyCommand=nc -X connect -x proxyhost:proxyport %h %p" remote_user@remote_host:remote_path local_path
  23.  
  24. ssh user@proxy.machine "ssh user@target.machine 'cat > file'" < file
  25.  
  26. tar cf - file1 file2 folder1/ | ssh user@proxy.machine "ssh user@target.machine 'tar xvf -'"
  27.  
  28. scp -o "ProxyCommand ssh user@myproxyserver.com nc %h %p" your.filename username@yourdestination.yourdomain.com:/whatever_location
  29.  
  30. ssh login@proxy_host
  31.  
  32. scp login@source_host:/path_to_source_file
  33. login@destination_host:/path_to_destination_directory
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement