Configuring the SSH service by using the command line

You can configure the SSH service by using the config and ssh commands on the command line.

About this task

You configure the SSH service, and can then optionally go on to configure the ciphers that the SSH service uses. By default the service uses 16 ciphers in a recommended order. You can, if required, disable or re-enable certain ciphers and reorder them.

Procedure

  1. Enter the configuration mode by entering the following command:
    
    config
    
  2. Specify the IP address and port that the SSH service listens on by entering the following command:
    
    ssh IPAddress:Port
    
    where:
    IPAddress
    Specifies the IP address of the Ethernet interface that you want to use to access the SSH service.
    port
    Specifies the port number that you want to use to access the SSH service.
  3. Exit the configuration mode by entering the following command:
    
    exit
    
  4. To work with SSH ciphers, enter the crypto SSH server mode by entering the following commands:
    crypto
    sshserverprofile
  5. Enter the following command to change the enabled ciphers and the order of preference that they are used in:
    ciphers cipher_string
    Where cipher_string lists the enabled ciphers in the required preference order. See ciphers for the names of ciphers that you can specify in the string.
  6. Exit the configuration mode by entering the following command:
    
    exit
    
  7. Exit the crypto mode by entering the following command:
    
    exit