276
SCP configuration
This chapter includes these sections:
• SCP overview
• Configuring the switch as an SCP server
• Configuring the switch as the SCP client
• SCP client configuration example
• SCP server configuration example
SCP overview
Secure copy (SCP) is based on SSH2.0 and offers a secure approach to copying files.
SCP uses SSH connections for copying files. The switch can act as the SCP server, allowing a user to log
in to the switch for file upload and download. The switch can also act as an SCP client, enabling a user
to log in from the switch to a remote server for secure file transfer.
NOTE:
hen the switch acts as an SCP server, only one of the FTP, SFTP or SCP user can access the switch.
Configuring the switch as an SCP server
Follow these steps to configure the switch as an SCP server:
To do… Use the command…
Remarks
Enter system view. system-view
N/A
Configure the SSH server.
For more information, see the security
guide for your switch.
N/A
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
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:
a. local-user
b. password
c. service-type ssh
d. 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: