Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revision |
linux:ssh [2020/04/28 18:12] – [X11] tmade | linux:ssh [2021/10/18 09:04] (current) – [ssh-agent] tmade |
---|
==== ssh-agent ==== | ==== ssh-agent ==== |
| |
ssh-agent bash #Start the agent for the required shell (sh, bash etc.) | ssh-agent -s #Start the agent |
eval $(ssh-agent -s) | |
ssh-add ~/.ssh/id_rsa #Add the key (passphrase will be promted) | ssh-add ~/.ssh/id_rsa #Add the key (passphrase will be promted) |
| |
| Script: |
| |
| <code> |
| #!/bin/bash |
| ssh-agent -s && ssh-add ~/.ssh/id_rsa |
| </code> |
==== ssh Tunnel ==== | ==== ssh Tunnel ==== |
ssh -L 4242:suse10.site:110tmade@suse10.site #user tmade forwards the connection comming in on port 4242 of his local host suse10 to port 110(POP3) on the remote host suse10 via ssh tunnel (port forwarding) | ssh -L 4242:suse10.site:110tmade@suse10.site #user tmade forwards the connection comming in on port 4242 of his local host suse10 to port 110(POP3) on the remote host suse10 via ssh tunnel (port forwarding) |