CISCO SSH Server: Unterschied zwischen den Versionen

Aus Xinux Wiki
Zur Navigation springen Zur Suche springen
 
(8 dazwischenliegende Versionen von einem anderen Benutzer werden nicht angezeigt)
Zeile 1: Zeile 1:
 
===Enabling AAA ===
 
===Enabling AAA ===
 +
*configure terminal
 
  aaa new-model
 
  aaa new-model
  
 
===rsa key generieren und starten===
 
===rsa key generieren und starten===
 
  unkerich#configure terminal
 
  unkerich#configure terminal
  unkerich(config)#crypto key generate rsa                                      
+
  unkerich(config)#crypto key generate rsa general-keys modulus 2048                                 
 
  The name for the keys will be: unkerich.schluries.int                           
 
  The name for the keys will be: unkerich.schluries.int                           
 
  Choose the size of the key modulus in the range of 360 to 2048 for your         
 
  Choose the size of the key modulus in the range of 360 to 2048 for your         
Zeile 19: Zeile 20:
 
===ssh time out einstellen===
 
===ssh time out einstellen===
 
  unkerich(config)#ip ssh time-out 120
 
  unkerich(config)#ip ssh time-out 120
 +
===ssh version 2===
 +
unkerich(config)# ip ssh version 2
 +
 +
=copy and paste=
 +
<pre>
 +
configure terminal
 +
crypto key generate rsa general-keys modulus 2048
 +
ip ssh time-out 120
 +
ip ssh version 2
 +
line vty 0 4
 +
logging synchronous
 +
transport input ssh
 +
</pre>
 +
 
=auto exec=
 
=auto exec=
unkerich(config)#aaa authorization exec default local
+
*username admin privilege 15 secret oimel
 +
*aaa new-model
 +
*aaa authorization exec default local
  
 
===user anlegen===                                                                                 
 
===user anlegen===                                                                                 

Aktuelle Version vom 12. Dezember 2023, 16:01 Uhr

Enabling AAA

  • configure terminal
aaa new-model

rsa key generieren und starten

unkerich#configure terminal
unkerich(config)#crypto key generate rsa general-keys modulus 2048                                   
The name for the keys will be: unkerich.schluries.int                           
Choose the size of the key modulus in the range of 360 to 2048 for your         
General Purpose Keys. Choosing a key modulus greater than 512 may take a few minutes.
                                                                               
How many bits in the modulus [512]: 1024                                        
 % Generating 1024 bit RSA keys, keys will be non-exportable...[OK]              
                                                                             
unkerich(config)#                                                               
*Mar  1 01:22:47.054: %SSH-5-ENABLED: SSH 1.99 has been enabled  
unkerich(config)#exit
unkerich#

ssh time out einstellen

unkerich(config)#ip ssh time-out 120

ssh version 2

unkerich(config)# ip ssh version 2

copy and paste

configure terminal
crypto key generate rsa general-keys modulus 2048 
ip ssh time-out 120
ip ssh version 2
line vty 0 4
 logging synchronous
 transport input ssh

auto exec

  • username admin privilege 15 secret oimel
  • aaa new-model
  • aaa authorization exec default local

user anlegen

unkerich(config)#username admin password oimel

rsa key löschen

unkerich(config)#crypto key zeroize rsa