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.

How to import a user level filtering list to a cpanel account ?

Discussion in 'E-mail Discussions' started by menkom, Sep 22, 2013.

  1. menkom

    menkom Member

    Joined:
    Sep 22, 2013
    Messages:
    8
    Likes Received:
    0
    Trophy Points:
    1
    cPanel Access Level:
    Reseller Owner
    Hello,

    So i am finding that the user level filtering options in cpanel are very powerful especially with spammers that user common keywords.

    I have a nice list of about 30 filters that i want to reuse, i would like to know if this file gets stored on the hosting account ? if so where?

    Can i reuse this list ? and if i create a new hosting account can i ftp this list to a specific directory and it will inherit the filters as well ?

    I really do not want to manually typing in all the filters again if at all possible, its just a tedious task.

    Finally if the above can be achieved is it possible to include this filter list in a specific directory in the Skeleton directory so that when a new hosting account is setup it will inherit the filters.

    I hope some guru can answer my questions.

    Thanks in advance. :)
    Mitch
     
  2. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    30,678
    Likes Received:
    649
    Trophy Points:
    113
    cPanel Access Level:
    Root Administrator
    Hello :)

    You can manually edit the following files:

    Code:
    /home/$user/etc/filter
    /home/$user/etc/filter.yaml
    It's acceptable to use the same list for multiple accounts, and the skeleton directory can include filter files. EX:

    Code:
    /root/cpanel3-skel/etc/filter
    /root/cpanel3-skel/etc/filter.yaml
    
    Thank you.
     
  3. menkom

    menkom Member

    Joined:
    Sep 22, 2013
    Messages:
    8
    Likes Received:
    0
    Trophy Points:
    1
    cPanel Access Level:
    Reseller Owner
    Thank you so much for this, is the filter you mention above USER LEVEL FILTERING or ACCOUNT LEVEL FILTERING or do they inherit the same ?

    Thank you so much for your answer
     
  4. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    30,678
    Likes Received:
    649
    Trophy Points:
    113
    cPanel Access Level:
    Root Administrator
    My previous post is intended for the "User Level Filtering" option in cPanel. The "Account Level Filtering" values are stored per domain name in:

    Code:
    /etc/vfilters/
    Thank you.
     
    StoneyCreeker likes this.
  5. menkom

    menkom Member

    Joined:
    Sep 22, 2013
    Messages:
    8
    Likes Received:
    0
    Trophy Points:
    1
    cPanel Access Level:
    Reseller Owner
    Ok my setup is a little different i am on sharedhost so i am not sure if this still applies to me ?

    My directly for USER LEVEL FILTERING IS

    /etc/domain.com/username/filter.yaml

    not exactly as you specified.

    I do not have a directory under root /etc directory called /vfilters ?

    Please advise, sorry for all the question. Thank you so much.
     
  6. menkom

    menkom Member

    Joined:
    Sep 22, 2013
    Messages:
    8
    Likes Received:
    0
    Trophy Points:
    1
    cPanel Access Level:
    Reseller Owner
    I tried manually creating /etc/vfilters and putting the yaml file but there is no difference i cannot see the rule in cpanel

    I also tried putting the yaml file into /etc and no difference as well

    for both USER LEVEL FILTERING and ACCOUNT LEVEL FILTERING, do you think its because im in a shared environment ?
     
  7. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    30,678
    Likes Received:
    649
    Trophy Points:
    113
    cPanel Access Level:
    Root Administrator
    The /etc/vfilters directory is only accessible with "root" access. You will not be able to modify the files in this directory with a shared hosting account. As for the user level filtering, it's fine to use the additional domain name in the directory path. That's typically for parked or addon domain names.

    Thank you.
     
  8. menkom

    menkom Member

    Joined:
    Sep 22, 2013
    Messages:
    8
    Likes Received:
    0
    Trophy Points:
    1
    cPanel Access Level:
    Reseller Owner
    I had a feeling, i will ask my host admin if we can gain root access, sometimes they allow it on reseller accounts.

    Is it possible to user the USER LEVEL FILTERING on ALL ACCOUNT but not specifically to a domain i think, for example is it possible to not use the domain path and just add the user level filter yaml file to be available for all domains ?

    You have been very helpful
     
  9. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    30,678
    Likes Received:
    649
    Trophy Points:
    113
    cPanel Access Level:
    Root Administrator
    The user level filters are stored in the directory associated with the email account. For example, if you create "123@domain.com", then the user level filter is stored in:

    /home/username/etc/domain.com/123

    The exception to this is the default email address of the account, which is the account username. That filter is stored in:

    /home/username/etc

    It's not possible to apply a user level filter to all accounts, as that is essentially what the account level filtering option is for.

    Thank you.
     
  10. menkom

    menkom Member

    Joined:
    Sep 22, 2013
    Messages:
    8
    Likes Received:
    0
    Trophy Points:
    1
    cPanel Access Level:
    Reseller Owner
    Ok thanks very much you have answered my question :)
     
  11. PCZero

    PCZero Well-Known Member

    Joined:
    Dec 13, 2003
    Messages:
    524
    Likes Received:
    32
    Trophy Points:
    28
    Location:
    Earth
    Michael I fond this when looking for a way to manually restore account level filters. I see that /etc/vfilters is the file that holds the filters in question which is great. However when I go into that file and add in the filters manually, then go into that clients cPanel/Account Level Filters, they are not listed. How do I make sure these manually added filters show up and are used?
     
  12. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    30,678
    Likes Received:
    649
    Trophy Points:
    113
    cPanel Access Level:
    Root Administrator
    Ensure you remove any filter.cache files in the /home/$username/.cpanel directory. Also, make sure /home/$username/.cpanel/filter.yaml is accurate.

    Thank you.
     
Loading...

Share This Page