openssh:ssh

ssh

usage: ssh [-46AaCfGgKkMNnqsTtVvXxYy] [-B bind_interface]
           [-b bind_address] [-c cipher_spec] [-D [bind_address:]port]
           [-E log_file] [-e escape_char] [-F configfile] [-I pkcs11]
           [-i identity_file] [-J [user@]host[:port]] [-L address]
           [-l login_name] [-m mac_spec] [-O ctl_cmd] [-o option] [-p port]
           [-Q query_option] [-R address] [-S ctl_path] [-W host:port]
           [-w local_tun[:remote_tun]] destination [command]
 
ssh -L PORT1:HOSTNAME:PORT2 user@hostB
  • ssh [<switches>…] desitination [command]
  • destination: IP/DNS 지정
    • id@destination: 로그인 아이디 지정. (없으면 현재 사용자)
  • [<switches>…]
    • -L local_port:localhost:target_port: SSH Local Tunneling(Local Port Fowarding). local_port로 접속시 target에 ssh 서버를 통하여 접속한다.
    • -R local_port:target_host:target_port: SSH Remote Tunneling(Remote Port Fowarding). target에 대한요청을 ssh 서버를 통하여 Local 서비스에 연결한다..
    • -N -D port: Dynamic Port Tunneling(SOCK5 proxy).

ssh

  • openssh/ssh.txt
  • 마지막으로 수정됨: 2026/03/11 05:34
  • 저자 writer