ip ssh-client algorithm
To enable one or more of the alogrithms used by the client for the SSH session encryption, host-key key exchange (kex) or MAC, use the ip ssh-client algorithm command in Global Configuration mode. To disable one or more of the SSH alogorithm, use the no form of this command.
Syntax
ip ssh-client algorithm {encryption enc-alg1 [enc-alg-2…] | hostkey host-alg1[ host-alg2…] | kex kex-alg1[ kex-alg2…] | mac mac-alg1[ mac-alg2…]}
no ip ssh-client algorithm {encryption enc-alg1 [enc-alg-2…] | hostkey host-alg1[ host-alg2…] | kex kex-alg1[ kex-alg2…] | mac mac-alg1[ mac-alg2…]}
Parameters
-
encryption enc-alg1 [enc-alg-2…] (optional) – list of encryption algorithms advertised to the client. One or more of the following algorithms can be specified:
-
aes128-ctr - AES with 128-bit key in CTR mod
-
aes192-ctr - AES with 192-bit key in CTR mod
-
aes256-ctr - AES with 256-bit key in CTR mod
-
aes128-gcm - AES with 128-bit key in GCM mode. Compatible with aes128-gcm@openssh.com
-
aes256-gcm - AES with 256-bit key in GCM mode. Compatible with aes256-gcm@openssh.com
-
-
hostkey host-alg1[ host-alg2…] (optional) – list of Host-key public-key algorithms advertised to the client. One or more of the following algorithms can be specified:
-
ssh-dss - DSA public-key signature with SHA1 hash
-
ssh-rsa - RSA public-key signature with SHA1 hash
-
rsa-sha2-256 - RSA public-key with SHA2-256 hash
-
rsa-sha2-512 - RSA public-key with SHA2-512 hash
-
-
kex kex-alg1[ kex-alg2…] (Optional) – Enable one or more of the following SSH key exchange (kex) algorithms:
-
diffie-hellman-group16-sha512 - Diffie-Hellman key exchange using SHA2-512 as HASH and 4096-bit MODP Group
-
diffie-hellman-group14-sha1 - Diffie-Hellman key exchange using SHA1 as HASH and 2048-bit MODP Group
-
-
mac mac-alg1[ mac-alg2…] (optional) - Enable one or more of the following SSH
Message Authentication Code (MAC) algorithms:
-
hmac-sha1 - HMAC-SHA1 (digest length = key length = 160 bits)
-
hmac-sha2-256 - HMAC-SHA2-256 (digest length = key length = 256 bits)
-
hmac-sha2-512 - HMAC-SHA2-512 (digest length = key length = 512 bits)
-
Default Configuration
-
Enabled Encryption algorithms: aes128-ctr, aes192-ctr, aes256-ctr, chacha20-poly1305, aes128-gcm and aes256-gcm
-
Enabled host-key alogrithms: ssh-dss, ssh-rsa, rsa-sha2-256 and rsa-sha2-512
-
Enabled kex algorithms: diffie-hellman-group16-sha512 and diffie-hellman-group14-sha1
-
Enabled MAC algorithms: hmac-sha1, hmac-sha2-256 and hmac-sha2-512
Command Mode
Global Configuration mode
User Guidelines
Use the ip ssh-client algorithm command to specify which encryption, host-key, key exchange (kex) and MAC algorithm will be advertised by the SSH client. Algorithms not specified in the command will not be advertised.
The no ip ssh-client algorithm specifies which algorithms to remove from the SSH client advertisement. The no command will change the advertisement list only if it specifies an algorithm that is in the current advertisement list. At least one algorithm must be supported for each category. If the command attempts to remove the last algorithm supported for that category the operation will fail and an error message will be displayed.
The configuration file will include a command that specifies the algorithm that are advertised (even if no ip ssh-client algorithm was used for the configuration)
The following algorithms are supported, and can be disabled only if FIPS mode is disabled:
-
chacha20-poly1305 encryption
-
ssh-dss host-key
In FIPS enabled mode these algorithms are not supported, and therefore do not need to be disabled.
Examples
Example 1 - The following example enables a few of the SSH encryption algorithms on the device. This means that the other encryption algorithms will not be advertised by the SSH client:
Switchxxxxxx(config)# ip ssh-client algorithm encryption aes256-ctr aes256-gcm

Feedback