Outbound port on sockets
Grant Edwards
grante at visi.com
Fri Sep 15 15:56:09 EDT 2006
On 2006-09-15, Steve Holden <steve at holdenweb.com> wrote:
>> I don't know what "multi-homing problems are either".
>> Apparently there must be some ftp clients that require the
>> source port for the data connection to be port 20.
>>
>> The RFC is pretty vague. It does say the server and clinet but
>> must "support the use of the default data port [port 20]" or
>> something like that. But, it's not all all clear to me what
>> that is supposed to mean. My reading is that they must support
>> the default port as the destination port for a data connection
>> untill it's been changed by receipt of a PORT command.
> Standard (port-mode) FTP has the client send a PORT command to the
> server when data transfer is required. The server then makes a
> connection to the indicated port from its own port 20.
I agree that's certainly the way it seems to work. When I read
the RFC, I couldn't tell if it intended to require that the
source port be 20. It almost sounded like it meant that the
data connection destination was 20 unless a PORT command was
received, but that wouldn't make much sense.
> Passive mode was introduced so that the server is not required
> to make a connection inbound to the client, as more and more
> firewalls were interposed at the perimeter of networks,
> blocking the inbound requests to clients from servers.
>
> I suspect that the reason for the comment is simply that the
> connection out from the server is being bound to the same
> interface (*IP address*) that the inbound request arrived on.
> That way it's less likely that the data stream will be routed
> differently from the control (port 21) stream.
I think that's probably right. It just dawned on me that
"multi-homed" refers to having more than one network interface.
--
Grant Edwards grante Yow! Yow!! That's a GOOD
at IDEA!! Eating a whole FIELD
visi.com of COUGH MEDICINE should
make you feel MUCH BETTER!!
More information about the Python-list
mailing list