Establishing an ftp connection – H3C Technologies H3C SecPath F1000-E User Manual

Page 133

Advertising
background image

3

Establishing an FTP Connection

To access an FTP server, an FTP client must establish a connection with the FTP server. Two ways are
available to establish a connection: using the ftp command to establish the connection directly; using
the open command in FTP client view.
Source address binding means to configure an IP address on a stable interface such as a loopback

interface or Dialer interface, and then use this IP address as the source IP address of an FTP connection.

The source address binding function simplifies the configuration of ACL rules and security policies. You

just need to specify the source or destination address argument in an ACL rule as this address to filter

inbound and outbound packets on the device, ignoring the difference between interface IP addresses as
well as the affect of interface statuses. You can configure the source address by configuring the source

interface or source IP address. The primary IP address configured on the source interface is the source

address of the transmitted packets. The source address of the transmitted packets is selected following

these rules:

If no source address is specified, the IP address of the output interface of the route to the server is
used as the source IP address.

The source IP address specified with the ftp client source or ftp command is used.

If you first use the ftp client source command to specify a source IP address and then use the ftp
command to specify another source IP address, the latter is used.

The source address specified with the ftp client source command applies to all FTP connections
while the one specified with the ftp command applies to the current FTP connection only.

Follow these steps to establish an IPv4 FTP connection:

To do…

Use the command…

Remarks

Enter system view

system-view

Configure the source address of
sent FTP packets

ftp client source { interface
interface-type interface-number | ip

source-ip-address }

Optional
A device uses the IP address
of the interface determined by

the matched route as the

source IP address to

communicate with the FTP
server by default.

Return to user view

quit

Log in to the remote FTP server
directly in user view

ftp [ server-address [ service-port ]
[ [ vpn-instance vpn-instance-name ] |
[ source { interface interface-type
interface-number
| ip

source-ip-address } ] ] ]

ftp

Log in to the remote FTP server
indirectly in FTP client view

open server-address [ service-port ]

Use either approach.
The ftp command is
available in user view; and
the open command is

available in FTP client view.

NOTE:

If no primary IP address is configured on the specified source interface, no FTP connection can be
established.

If you use the ftp client source command to configure a source interface and then use it to configure a
source IP address, the source IP address overwrites the source interface, and vice versa.

Advertising
This manual is related to the following products: