Bug 104907

Summary: passive address returns wrong IP
Product: [Retired] Red Hat Linux Reporter: Need Real Name <willem>
Component: wu-ftpdAssignee: Thomas Woerner <twoerner>
Status: CLOSED WONTFIX QA Contact: David Lawrence <dkl>
Severity: high Docs Contact:
Priority: medium    
Version: 7.2   
Target Milestone: ---   
Target Release: ---   
Hardware: i386   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2004-02-19 13:26:07 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Need Real Name 2003-09-23 14:28:25 UTC
From Bugzilla Helper:
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.0.2) Gecko/20030716

Description of problem:
There appears to be a problem with the passive address resolution in that it
always returns the "everybody else" address.  Here is a snippet from ftpaccess

passive address 192.168.4.2   192.168.100.0/24
passive address 192.168.4.2   192.168.4.0/24
passive address 66.180.108.10 0.0.0.0/0
passive ports   0.0.0.0/0  40000 40015

This ALWAYS returns 66.180.108.10, even when connecting from 192.168.100.X. 
E.g. from host 192.168.100.12

   ftp> ls
   227 Entering Passive Mode (66,180,108,10,156,76)

The logs correctly identify the connection as from 192.168.100.12
  Sep 23 08:14:58 split ftpd[4204]: ANONYMOUS FTP LOGIN FROM
     sherkhan.prinmath.com [192.168.100.12], willem
  Sep 23 08:19:08 split ftpd[4204]: FTP session closed

Commenting out the 0.0.0.0/0 line has it return the right address (192.168.4.2)
but breaks connections from outside.

There are comments on the wu-ftpd-2.8 prerelease mailing list about errors in
the routevector code, which may be related:  See
  http://www.landfield.com/wu-ftpd/mail-archive/wuftpd-dev/2003/May/0003.html

Version-Release number of selected component (if applicable):
wu-ftpd-2.6.2-11.72.1.i386.rpm

How reproducible:
Always

Steps to Reproduce:
1.Add "passive address" lines to ftpaccess
2.One should be 0.0.0.0/0
3.One should be on your local network with different IP that 0.0.0.0/0
Connect with ftp from local network and do an 'ls'
    

Actual Results:  wu-ftpd will make a passive connection to the external IP

Expected Results:  Should make a passive connection to the internal IP

Additional info:  This appears to be a problem in all 2.6.2 versions.

Comment 1 Thomas Woerner 2004-02-19 13:26:07 UTC
Please use vsftpd, wu-ftpd is not maintained anymore.