The Community Forums

Interact with an entire community of cPanel & WHM users!
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

disable ftp account to specific user

Discussion in 'Security' started by whm-expert, Nov 24, 2012.

  1. whm-expert

    whm-expert Active Member

    Joined:
    Nov 10, 2012
    Messages:
    40
    Likes Received:
    0
    Trophy Points:
    6
    cPanel Access Level:
    DataCenter Provider
    hello is there any way so i can disable FTP to a specific user? but i want him to still be able to login to cpanel?
     
  2. PlotHost

    PlotHost Well-Known Member

    Joined:
    Apr 29, 2011
    Messages:
    253
    Likes Received:
    1
    Trophy Points:
    18
    Location:
    US
    cPanel Access Level:
    Root Administrator
    Twitter:
  3. yapluka

    yapluka Well-Known Member

    Joined:
    Dec 24, 2003
    Messages:
    301
    Likes Received:
    1
    Trophy Points:
    18
    Location:
    France
    cPanel Access Level:
    Root Administrator
    Yes, you can :
    echo username >> /etc/ftpusers

    This will disable the FTP access to any user listed in this file /etc/ftpusers
     
  4. mikelegg

    mikelegg Well-Known Member

    Joined:
    Mar 29, 2005
    Messages:
    330
    Likes Received:
    0
    Trophy Points:
    16
    I just found that this doesn't work on one of my servers.

    I even restarted the FTP server, but users listed in /etc/ftpusers can still connect via FTP.

    The file didn't actually exist, so I had to create it. Does it require special permissions in order to work?
     
  5. cPanelJared

    cPanelJared Technical Analyst
    Staff Member

    Joined:
    Feb 25, 2010
    Messages:
    1,842
    Likes Received:
    18
    Trophy Points:
    38
    Location:
    Houston, TX
    cPanel Access Level:
    Root Administrator
    This is actually documented here:

    Denying FTP Access

    I tested this on a test server, and when I tried to log in as a user listed in /etc/ftpusers, I got this message:

    Code:
    Password: 
    530 Login authentication failed
    ftp: Login failed
    ftp>
    /etc/ftpusers does not require non-default ownerships or permissions, and you do not need to restart the FTP service. If it is not working for you, please submit a ticket so we can take a look.
     
  6. Mullen

    Mullen Member

    Joined:
    Jul 29, 2004
    Messages:
    8
    Likes Received:
    0
    Trophy Points:
    1
    Location:
    Sunderland, UK
    I've actually found that you need to remove (or rename) the user in /etc/proftpd, even when you're running pure-ftpd. This successfully blocks that user from logging in via FTP.
     
Loading...

Share This Page