Am Samstag, 28. Januar 2006 17:51 schrieb Walter Ulmke:
Hallo an alle!
ich muss als root auf host1 per ssh - wiederum als root - auf host2 einen shutdown befehl ausführen.
Das Ganze läuft aus einer Batch-datei heraus. Somit kann ich nicht interaktiv das passwort eingeben.
Wie geht das? Welche Paramter/Voraussetzungen muss ich auf host1 und host2 setzen?
nur kurz, ich muß gleich weg: man ssh man ssh-keygen man ssh-copy-id aus man ssh: As a second authentication method, ssh supports RSA based authentication. The scheme is based on public-key cryptography: there are cryptosystems where encryption and decryption are done using separate keys, and it is not possible to derive the decryption key from the encryption key. RSA is one such system. The idea is that each user creates a public/private key pair for authentication purposes. The server knows the public key, and only the user knows the private key. The file $HOME/.ssh/authorized_keys lists the public keys that are permit- ted for logging in. When the user logs in, the ssh program tells the server which key pair it would like to use for authentication. The server checks if this key is permitted, and if so, sends the user (actually the ssh program running on behalf of the user) a challenge, a random number, encrypted by the user's public key. The challenge can only be decrypted using the proper private key. The user's client then decrypts the chal- lenge using the private key, proving that he/she knows the private key but without disclosing it to the server. Bye Jürgen -- Dr.rer.nat. Juergen Vollmer, Viktoriastrasse 15, D-76133 Karlsruhe Tel: +49(721) 92 04 87 1 Fax: +49(721) 92 04 87 2 Juergen.Vollmer@informatik-vollmer.de www.informatik-vollmer.de Internet-Telefonie: www.skype.com Benutzer: juergen.vollmer