Network requirements
As shown in
•
You can log in to Router B through the SCP client that runs on Router A.
After login, you are assigned the user role network-admin and can securely transfer files with
•
Router B.
Router B uses the password authentication method.
•
The client's username and password are saved on Router B.
•
Figure 79 Network diagram
Configuration procedure
1.
Configure the SCP server:
# Generate the RSA key pairs.
<RouterB> system-view
[RouterB] public-key local create rsa
The range of public key size is (512 ~ 2048).
If the key modulus is greater than 512, it will take a few minutes.
Press CTRL+C to abort.
Input the modulus length [default = 1024]:
Generating Keys...
........................++++++
...................++++++
..++++++++
............++++++++
Create the key pair successfully.
# Generate a DSA key pair.
[RouterB] public-key local create dsa
The range of public key size is (512 ~ 2048).
If the key modulus is greater than 512, it will take a few minutes.
Press CTRL+C to abort.
Input the modulus length [default = 1024]:
Generating Keys...
.++++++++++++++++++++++++++++++++++++++++++++++++++*
........+......+.....+......................................+
...+.................+..........+...+.
Create the key pair successfully.
# Enable the SSH server function.
[RouterB] ssh server enable
# Configure an IP address for GigabitEthernet 1/0. The client uses this address as the destination
for SCP connection.
[RouterB] interface gigabitethernet 1/0
[RouterB-GigabitEthernet1/0] ip address 192.168.0.1 255.255.255.0
Figure
79:
280