Menü +

find ./ -type f -name '*source-string*'

ssh | ssh-add | ssh-keygen

#   $ ssh-add ~/.ssh/id_rsa.pub
#   Could not open a connection to your authentication agent.
eval `ssh-agent`
#
mkdir -p $HOME/.ssh
chmod 0700 $HOME/.ssh
#
vi ~/.ssh/config
#
Host server1
     HostName server1.cyberciti.biz
     User nixcraft
     Port 4242
     IdentityFile /nfs/shared/users/nixcraft/keys/server1/id_rsa


### default for all ##
Host *
     ForwardAgent no
     ForwardX11 no
     ForwardX11Trusted yes
     User nixcraft
     Port 22
     Protocol 2
     ServerAliveInterval 60
     ServerAliveCountMax 30
 
## override as per host ##
Host server1
     HostName server1.cyberciti.biz
     User nixcraft
     Port 4242
     IdentityFile /nfs/shared/users/nixcraft/keys/server1/id_rsa
 
## Home nas server ##
Host nas01
     HostName 192.168.1.100
     User root
     IdentityFile ~/.ssh/nas01.key
 
## Login AWS Cloud ##
Host aws.apache
     HostName 1.2.3.4
     User wwwdata
     IdentityFile ~/.ssh/aws.apache.key
 
## Login to internal lan server at 192.168.0.251 via our public uk office ssh based gateway using ##
## $ ssh uk.gw.lan ##
Host uk.gw.lan uk.lan
     HostName 192.168.0.251
     User nixcraft
     ProxyCommand  ssh [email protected] nc %h %p 2> /dev/null
 
## Our Us Proxy Server ##
## Forward all local port 3128 traffic to port 3128 on the remote vps1.cyberciti.biz server ##
## $ ssh -f -N  proxyus ##
Host proxyus
    HostName vps1.cyberciti.biz
    User breakfree
    IdentityFile ~/.ssh/vps1.cyberciti.biz.key
    LocalForward 3128 127.0.0.1:3128


#    puttygen supports exporting your private key to an OpenSSH compatible format. You can then use OpenSSH tools to recreate the public key.
#    Open PuttyGen
#    Click Load
#    Load your private key
#    Go to Conversions->Export OpenSSH and export your private key
#    Copy your private key to ~/.ssh/id_dsa (or id_rsa).
#
#    Create the RFC 4716 version of the public key using ssh-keygen

     ssh-keygen -e -f ~/.ssh/id_dsa > ~/.ssh/id_dsa_com.pub

#    Convert the RFC 4716 version of the public key to the OpenSSH format:

     ssh-keygen -i -f ~/.ssh/id_dsa_com.pub > ~/.ssh/id_dsa.pub

# See this and this for more information.

#  Show public key from a SSH private key?
ssh-keygen -y -f ~/.ssh/id_rsa > ~/.ssh/id_rsa.pub

http://www.cyberciti.biz/faq/create-ssh-config-file-on-linux-unix/

https://help.github.com/articles/working-with-ssh-key-passphrases/

http://www.thegeekstuff.com/2008/11/3-steps-to-perform-ssh-login-without-password-using-ssh-keygen-ssh-copy-id/

Schreibe einen Kommentar

Deine E-Mail-Adresse wird nicht veröffentlicht. Erforderliche Felder sind mit * markiert.