Operating System - HP-UX
1835818 Members
3139 Online
110085 Solutions
New Discussion

Re: ftp -d port definition

 
j773303
Super Advisor

ftp -d port definition

#ftp -d hputaiz
ftp> ls
---> PORT 161,57,175,64,206,61
200 PORT command successful.


When "ftp -d", type ls, it shows "161,57,175,64,206,61",
"161.57.175.64" is the remote host.
Does anyone knows what's the meaning of "206,61" ?

Thanks.
Hero
1 REPLY 1
Joel Girot
Trusted Contributor

Re: ftp -d port definition

Hi
In an active FTP session, the first four octets are the IP address while the last two octets comprise the port that will be used for the data connection. To find the actual port multiply the fifth octet by 256 and then add the sixth octet to the total. Thus in your example the port number is ( (206*256) + 61), or 52797. A quick check with netstat should confirm this information.

Joel