416
ssh client source
Use ssh client source to specify the source IPv4 address for SSH packets.
Use undo ssh client source to restore the default.
Syntax
ssh client source { interface interface-type interface-number | ip ip-address }
undo ssh client source
Default
The source IP address for SSH packets is not configured. The SSH packets use the primary IP address of
the output interface specified in the routing entry as their source IP address.
Views
System view
Predefined user roles
network-admin
Parameters
interface interface-type interface-number: Specifies a source interface by its type and number. The SSH
packets use the primary IP address of the interface as the source address.
ip ip-address: Specifies a source IPv4 address.
Usage guidelines
If you execute this command multiple times, the most recent configuration takes effect.
This command takes effect on all Stelnet connections. The source IP address specified in the ssh2
command takes effect only on the current Stelnet connection.
If you specify the source IP address both in this command and the ssh command, the source IP address
specified in the ssh command takes effect.
Examples
# Specify the source IPv4 address for SSH packets as 192.168.0.1.
<Sysname> system-view
[Sysname] ssh client source ip 192.168.0.1
Related commands
display ssh client source
ssh2
Use ssh2 to establish a connection to an IPv4 Stelnet server.
Syntax
In non-FIPS mode:
ssh2 server [ port-number ] [ vpn-instance vpn-instance-name ] [ identity-key { dsa | rsa } |
prefer-compress zlib | prefer-ctos-cipher { 3des | aes128 | aes256 | des } | prefer-ctos-hmac { md5 |
md5-96 | sha1 | sha1-96 } | prefer-kex { dh-group-exchange | dh-group1 | dh-group14 } |
prefer-stoc-cipher { 3des | aes128 | aes256 | des } | prefer-stoc-hmac { md5 | md5-96 | sha1 |