FedoraForum.org - Fedora Support Forums and Community
Results 1 to 8 of 8
  1. #1
    tommy916 Guest

    Question vsftpd can't ls via firewall, need to disable passive?

    I'm having problem when ftp to fedora or red hat enterprise while these are behind the firewall SELinux. I'm connecting with MS DOS & other linux server's terminal. I can connect after login but when i type ls or dir, it takes a longer to response and it cannot list the files. I'm using vsftpd that came with fedora & red hat enterprise.

    I've type "passive" while on ftp to disable the passive but still doesn't list the files.

    How can i solve this? I don't want to disable the firewall. I thought the passive uses random ports other than 21. How do I disable passive so i can use port 21 for active ftp?
    Last edited by tommy916; 28th June 2005 at 08:57 AM.

  2. #2
    tommy916 Guest
    does anyone know this issue?

  3. #3
    websavages Guest
    in /etc/sysconfig/iptables-config include ip_conntrack_ftp as a module to load

    Code:
    IPTABLES_MODULES="ip_conntrack_ftp"
    and then add the following to your firewall policy (i am presuming you are using iptables

    Code:
    #######
    # FTP #
    #######
    -A INPUT -p tcp -m tcp --dport 21 -m state --state NEW,ESTABLISHED -j ACCEPT
    -A OUTPUT -p tcp -m tcp --sport 21 -m state --state ESTABLISHED -j ACCEPT
    
    #
    # ACTIVE DATA CHANNEL
    -A OUTPUT -p tcp -m tcp --sport 20 --dport 1024:65535 -m state --state ESTABLISHED,RELATED -j ACCEPT
    -A INPUT -p tcp -m tcp --dport 20 --sport 1024:65535 -m state --state ESTABLISHED -j ACCEPT
    
    #
    # PASSIVE DATA CHANNEL
    -A INPUT -p tcp -m tcp --dport 1024:65535 --sport 1024:65535 -m state --state ESTABLISHED,RELATED -j ACCEPT
    -A OUTPUT -p tcp -m tcp --sport 1024:65535 --dport 1024:65535 -m state --state ESTABLISHED -j ACCEPT
    obviously this is for incoming ftp traffic to the linux box

    Cheers ws

  4. #4
    the_tragic_hip Guest
    I'm having a similar problem. When I connect to the ftp server internally through DOS, I can use the ls and dir commands no problem. When I connect to the ftp server from outside our network through DOS, the ls and dir commands hang and a message comes up 200 port command successful. Consider using pasv.

    When outside people connect via ie explorer or an ftp client there is no problem. I have the min and max set for passive ports in the conf file, and they are forwarded on our router. Am I missing something to allow the outside people from using the ls and dir commands in DOS?

    Thanks in advance.

  5. #5
    tommy916 Guest
    have you add this in /etc/sysconfig/iptables-config

    IPTABLES_MODULES="ip_conntrack_ftp"

  6. #6
    the_tragic_hip Guest
    I tried that already, and got the same results, but I will try again once more, just to put my mind at ease.

    Thanks tommy. Loved ya in TommyBoy.

  7. #7
    the_tragic_hip Guest
    Forgot to mention, I do not use the firewall.

  8. #8
    tommy916 Guest
    try ip_nat_ftp or something.
    dont forget to restart the iptables

    http://www.linuxhomenetworking.com/l...bles-intro.htm

Similar Threads

  1. vsftpd, hang when entering passive mode
    By reynaldo in forum Installation, Upgrades and Live Media
    Replies: 5
    Last Post: 8th February 2014, 05:51 PM
  2. pure-ftpd + passive + router with firewall
    By Trancelucid in forum Using Fedora
    Replies: 1
    Last Post: 4th May 2005, 07:47 PM

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •