ubuntuusers.de

ssh

Datum:
16. August 2012 01:13
Code:
 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
benutzername@server:~$ ssh-keygen
Generating public/private rsa key pair.
Enter file in which to save the key (/home/benutzername/.ssh/id_rsa): 
Created directory '/home/benutzername/.ssh'.
Enter passphrase (empty for no passphrase): 
Enter same passphrase again: 
Your identification has been saved in /home/benutzername/.ssh/id_rsa.
Your public key has been saved in /home/benutzername/.ssh/id_rsa.pub.
The key fingerprint is:
xxxx benutzername@server.de
The key's randomart image is:
+--[ RSA 2048]----+
|   ..            |
|    ..E          |
|   + o.+         |
|  = B O..        |
| . * B .S        |
|  . o    .       |
|   o             |
|  o o.           |
|   =o            |
+-----------------+
benutzername@server:~$ ssh-copy-id -i ~/.ssh/id_rsa.pub '-p 555 benutzername@ip-adresse'
The authenticity of host '[ip-adresse]:555 ([ip-adresse]:555)' can't be established.
RSA key fingerprint is xxx
Are you sure you want to continue connecting (yes/no)? yes
Warning: Permanently added '[ip-adresse]:1974' (RSA) to the list of known hosts.
benutzername@ip-adresse's password: 
Now try logging into the machine, with "ssh '-p 555 benutzername@ip-adresse'", and check in:

  .ssh/authorized_keys

to make sure we haven't added extra keys that you weren't expecting.

benutzername@server:~$