Configuring the switch as an SCP server

Step

Command

Remarks

1. Enter system view.

system-view

N/A

2. Configure the SSH server.

For more information, see the security guide for your switch.

N/A

3. Create an SSH user for a SCP client, set the service type to all or scp, and specify the authentication method.

ssh user username service-type { all | scp } authentication-type { password | { any | password-publickey | publickey } assign publickey keyname work-directory directory-name }

N/A

4. Create a user account and assign a working directory for the SSH user on the switch or a remote server if password authentication is used.

  • On the remote server (Details not shown.)

  • On the switch:

    1. local-user

    2. password

    3. service-type ssh

    4. authorization-attribute work-directory directory-name

Skip this step if publickey authentication, whether with password authentication or not, is used.

Make sure that the local user account has the name username as the username specified in the ssh user command.

When you set the working directory for the user, follow these guidelines: