ftp-port.d 1.5 KB

12345678910111213141516171819202122232425262728293031323334353637383940
  1. c: Copyright (C) 1998 - 2022, Daniel Stenberg, <daniel@haxx.se>, et al.
  2. SPDX-License-Identifier: curl
  3. Long: ftp-port
  4. Arg: <address>
  5. Help: Use PORT instead of PASV
  6. Short: P
  7. Protocols: FTP
  8. See-also: ftp-pasv disable-eprt
  9. Category: ftp
  10. Example: -P - ftp:/example.com
  11. Example: -P eth0 ftp:/example.com
  12. Example: -P 192.168.0.2 ftp:/example.com
  13. Added: 4.0
  14. ---
  15. Reverses the default initiator/listener roles when connecting with FTP. This
  16. option makes curl use active mode. curl then tells the server to connect back
  17. to the client's specified address and port, while passive mode asks the server
  18. to setup an IP address and port for it to connect to. <address> should be one
  19. of:
  20. .RS
  21. .IP interface
  22. e.g. "eth0" to specify which interface's IP address you want to use (Unix only)
  23. .IP "IP address"
  24. e.g. "192.168.10.1" to specify the exact IP address
  25. .IP "host name"
  26. e.g. "my.host.domain" to specify the machine
  27. .IP "-"
  28. make curl pick the same IP address that is already used for the control
  29. connection
  30. .RE
  31. If this option is used several times, the last one will be used. Disable the
  32. use of PORT with --ftp-pasv. Disable the attempt to use the EPRT command
  33. instead of PORT by using --disable-eprt. EPRT is really PORT++.
  34. You can also append \&":[start]-[end]\&" to the right of the address, to tell
  35. curl what TCP port range to use. That means you specify a port range, from a
  36. lower to a higher number. A single number works as well, but do note that it
  37. increases the risk of failure since the port may not be available.
  38. (Added in 7.19.5)