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.

cpanel, proftpd and Dedicated IP

Discussion in 'CloudLinux' started by iortiz, Jun 20, 2011.

  1. iortiz

    iortiz Registered

    Joined:
    Jun 19, 2011
    Messages:
    1
    Likes Received:
    0
    Trophy Points:
    1
    Hi everyone,

    Recently I assigned a dedicated ip for a user/domain account. I did that change because I host two different domains on that server, for example:

    *.site1.com (main IP)
    *.site2.com (main IP)

    So, I use extensively ftp service, and I notice that if I assign a use@site1.com ftp account, he can access with that account to both site!!!!, then my first question: Is any way to avoid this user access other domains (in this case ftp.site2.com)?

    As I was desperate for this issue I reassigned the second domain to a new dedicate IP hosted in same server as this:

    *.site1.com (main IP)
    *.site2.com (new dedicated IP)

    all right, but there are another issues:
    **** First: If a create new - even old ones - ftp account for *.site2.com, to access this site the real account to use is "newuser" even if the domain cpanel "ftp setup account" says that the new account is "newuser@site2.com".
    **** Second: I still can access with "newuser@site2.com" to ftp.site1.com!!!!

    I entered to my cloudlinux console and there were two config files that host ftp "user:password" for both sites:
    /etc/proftpd/passwd.vhosts
    /etc/proftpd/site2

    The first one controls access to *.site1.com (main IP), and the second the *.site2.com (Dedicated IP).

    The syntax of first is something like this:
    newuser+site2.com:password .... bla bla ..... :/bin/ftpsh
    newuser@site2.com:password .... etc etc ...:/bin/ftpsh
    otheruser@site1.com:password .... ... ...:/bin/ftpsh

    The second one (/etc/proftpd/site2):
    newuser:password .. .... ... :/bin/ftpsh
    myself:password .... .... ....:/bin/ftpsh

    As you noticed the "newuser" is duplicated in both files. Moreover the second file has only "newuser" without "domain".

    I could change myself that files to just modify what I need, but Is any way that cpanel can do it? what if I want to set up a lot of sites? It is not practical to do "by hand".

    By the way, My server ftp is proftpd.

    Any advices, comments, solutions!!! Please!!!
    Thanks
    Israel
     
  2. ultimatehosting

    Joined:
    Jul 30, 2011
    Messages:
    11
    Likes Received:
    0
    Trophy Points:
    1
    Location:
    India
    cPanel Access Level:
    Root Administrator
    It's very simple no matter how many domains you have the user will be able to connect to your server via FTP as all the domains resolve to the same server. ;)
     
  3. NixTree

    NixTree Well-Known Member

    Joined:
    Aug 19, 2010
    Messages:
    387
    Likes Received:
    1
    Trophy Points:
    18
    Location:
    Gods Own Country
    cPanel Access Level:
    Root Administrator
    Hi Israel,

    Please take a look here http://forums.cpanel.net/f5/multiple-ftp-users-207912.html . I am not sure whether you are trying to report the same issue ( which I failed to convince the cPanel guys :) ) . The issue I reported is basically due to how proftpd handles authentication.

    By the way, /etc/proftpd/passwd.vhosts should contain the passwords of all FTP users. But it will be referred at the end if it doesn't find a match in any of the user files ( how it map the user is here - How cPanel handles FTP authentication ).

    Thank you,
    Nibin
     
Loading...

Share This Page