Sftp configuration example – H3C Technologies H3C WX3000 Series Unified Switches User Manual
Page 529
49-16
To do…
Use the command…
Remarks
Specify an interface as the source
interface of the specified SFTP
client
sftp source-interface
interface-type interface-number
Specify an IP address as the
source IP address of the specified
SFTP client
sftp source-ip ip-address
Use either command
Not specified by default
Display the source IP address
used by the current SFTP client
display sftp source-ip
Optional
Available in any view.
SFTP Configuration Example
Network requirements
As shown in
, establish an SSH connection between the SFTP client (Switch A) and the
SFTP server (switch B). Log in to Switch B through switch A to manage and transmit files. An SFTP user
account with the user name client001 and password abc exists on the SFTP server.
Figure 49-6
Network diagram for SFTP configuration
Switch B
SFTP Server
SFTP Client
Vlan-Int1
192.168.0.1/24
Vlan-Int1
192.168.0.2/24
Switch A
Configuration procedure
1) Configure the SFTP server (Switch B)
# Create key pairs.
[device] public-key local create rsa
[device] public-key local create dsa
# Create a VLAN interface on the device and assign to it an IP address, which is used as the destination
address for the client to connect to the SFTP server.
[device] interface vlan-interface 1
[device-Vlan-interface1] ip address 192.168.0.1 255.255.255.0
[device-Vlan-interface1] quit
# Specify the SSH authentication mode as AAA.
[device] user-interface vty 0 4
[device-ui-vty0-4] authentication-mode scheme
# Configure the protocol through which the remote user logs in to the device as SSH.
[device-ui-vty0-4] protocol inbound ssh
[device-ui-vty0-4] quit
# Create a local user client001.
[device] local-user client001
[device-luser-client001] password simple abc
[device-luser-client001] service-type ssh
[device-luser-client001] quit