Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

FTP passive port calculation?

Does anybody know, how the passive port in FTP is calculated? Usually, the server-ip-address is shown in decimal and readable, separated by ",". example:

File Transfer Protocol (FTP)
227 Entering Passive Mode (192,168,145,95,238,20)\r\n
    Response code: Entering Passive Mode (227)
    Response arg: Entering Passive Mode (192,168,145,95,238,20)
    Passive IP address: 192.168.145.95
    Passive port: 60948

192,168,145,95 = ip-address 192.168.145.95 But passive port bytes 238,20 mean passive-port: 60948