CISCO Packet Tracer - Telnet + SSH

Опубликовано: 04 Октябрь 2024
на канале: schOOl's in!
1,632
18

Configurazione di uno switch mediante Telnet ed SSH

References
Telnet: https://it.wikipedia.org/wiki/Telnet
SSH: https://it.wikipedia.org/wiki/Secure_...

Comandi usati:

Telnet
Preconditions: in order to connect via TELNET it is necessary to have:
pre-configured a password for “secure privileged access”
pre-configured an ip address on interface VLAN 1

Switch#conf t
Switch(config)#user TYPEYOURUSERNAME password TYPETOURPASSWORD
Switch(config)#line vty 0 15
Switch(config-line)#login local
Switch(config-line)#transport input telnet
Switch(config-line)#exit

from PC: telnet TYPESWITCHIP

SSH
Preconditions: in order to connect via TELNET it is necessary to have:
pre-configured a password for “secure privileged access”
pre-configured an ip address on interface VLAN 1
pre-configured an hostname for the device
pre-configured an ip domain name

Switch(config)#hostname MYSWITCH
MYSWITCH(config)#ip domain-name MYDOMAIN
MYSWITCH(config)#username myUser password myPass
MYSWITCH(config)#line vty 0 15
MYSWITCH(config-line)#transport input ssh
MYSWITCH(config-line)#login local
MYSWITCH(config-line)#exit
MYSWITCH(config)#crypto key generate rsa

The name for the keys will be: MYSWITCH.MYDOMAIN
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]:
% Generating 512 bit RSA keys, keys will be non-exportable...[OK]
MYSWITCH(config)#
*Mar 1 0:12:47.796: RSA key size needs to be at least 768 bits for ssh version 2
*Mar 1 0:12:47.796: %SSH-5-ENABLED: SSH 1.5 has been enabled

from PC: ssh -l myUser 192.168.1.2