Community Forums
Connect with us on LinkedIn
Community Notice
+ Reply to Thread
Page 2 of 3 FirstFirst 1 2 3 LastLast
Results 16 to 30 of 42
  1. #16
    Member chican0's Avatar
    Join Date
    Mar 2003
    Location
    Los Angeles
    Posts
    59

    Default

    I would love to use this script but I have been finding that accounts with multiple email accounts (pop3 accounts), start having problems.

    The primary problem is that the Main Account, the primary email address which is automaticaly created when the account is created (account username) will no longer accept emails. The system instead returns the following error:

    Technical details of permanent failure:
    PERM_FAILURE: SMTP Error (state 10): 550 "The recipient cannot be verified. no such address here"
    The only work around I have found is to create a second pop3 mail account and add a forwarder to route mails from the Main Account(username) to the new pop3 account.

    This can be unacceptable for a few customers as some of their preferred email address is that of the Main Account which is automatically created by the system during initial account setup.

    Does anyone know of a way to fix this problem? To set the Default address to :fail: and still receive emails to the Main email Account?

  2. #17
    Super Moderator This forum account has been confirmed by cPanel staff to represent a vendor. chirpy's Avatar
    Join Date
    Jun 2002
    Location
    Go on, have a guess
    Posts
    13,495

    Default

    Create a Forwarder for name@domain.com to point to name@hostname.server.com
    Jonathan Michaelson

    Need your cPanel servers secured and tuned?
    cPanel Server Configuration, Security, Recovery and Antivirus/AntiSpam Services
    Developers of the most effective (and free) Firewall & Security Solution for cPanel Servers - csf
    http://www.configserver.com

  3. #18
    Member chican0's Avatar
    Join Date
    Mar 2003
    Location
    Los Angeles
    Posts
    59

    Default

    That is just freekin awsome!

    Thanks Chirpy. Your a definite help.

    I do have a couple questions.... I have been searching thie board for that answer for the past hour. Was that little bit of info mentioned in other threads that you know of or is it hardly mentioned at all. I would feel quite helpless if it is in other threads and I just could not manage to find it.

    Also, After running your small script... what would be the easiest way to add the required forwarder for the Default Account email address to work on all domains? Or do I need to go into each cPanel and manually add them?

    And finally, is this a cPanel or Exim bug? If so, any word or information about it being fixed/patched? I do know it has been an issue for a while as I remember running into this issue sometime back but only used the workaround mentioned in my previous post.

    Thanks again for your assistance!

  4. #19
    Super Moderator This forum account has been confirmed by cPanel staff to represent a vendor. chirpy's Avatar
    Join Date
    Jun 2002
    Location
    Go on, have a guess
    Posts
    13,495

    Default

    1. It's only something that has come to light recently and was posted by rs-freddo hidden in some other threads, so it's easily missed.

    2. You will need to add it manually without more scripting. You could also do it directly in the /etc/valiases/*

    3. It's a feature Basically, it's an artefact of the way that cPanel has created virtual POP3 accounts together with the exim delivery system works.
    Jonathan Michaelson

    Need your cPanel servers secured and tuned?
    cPanel Server Configuration, Security, Recovery and Antivirus/AntiSpam Services
    Developers of the most effective (and free) Firewall & Security Solution for cPanel Servers - csf
    http://www.configserver.com

  5. #20
    Member
    Join Date
    Aug 2004
    Posts
    10

    Default

    Sometimes need convert :blackhole: to :fail:
    Use this command in ssh

    replace :blackhole: :fail: -- /etc/valiases/*

  6. #21
    cPanel Partner NOC cPanel Partner NOC Badge jester.ro's Avatar
    Join Date
    Feb 2004
    Location
    Bucharest, Romania
    Posts
    304

    Default

    hey, chirpy, have you been contacted by mr wonderfull, about the flaws in you script?

  7. #22
    Super Moderator This forum account has been confirmed by cPanel staff to represent a vendor. chirpy's Avatar
    Join Date
    Jun 2002
    Location
    Go on, have a guess
    Posts
    13,495

    Default

    Funnily enough - no Though I wouldn't be surprised if he were back under a different guise (in fact I know he is).
    Jonathan Michaelson

    Need your cPanel servers secured and tuned?
    cPanel Server Configuration, Security, Recovery and Antivirus/AntiSpam Services
    Developers of the most effective (and free) Firewall & Security Solution for cPanel Servers - csf
    http://www.configserver.com

  8. #23
    Super Moderator This forum account has been confirmed by cPanel staff to represent a vendor. chirpy's Avatar
    Join Date
    Jun 2002
    Location
    Go on, have a guess
    Posts
    13,495

    Default

    It's a neat trick, huh? Posting the answer before you ask the question

    Forum bug I think. I removed the pre-post and reposted after your post - I think.
    Jonathan Michaelson

    Need your cPanel servers secured and tuned?
    cPanel Server Configuration, Security, Recovery and Antivirus/AntiSpam Services
    Developers of the most effective (and free) Firewall & Security Solution for cPanel Servers - csf
    http://www.configserver.com

  9. #24
    Super Moderator This forum account has been confirmed by cPanel staff to represent a vendor. chirpy's Avatar
    Join Date
    Jun 2002
    Location
    Go on, have a guess
    Posts
    13,495

    Default

    Arrrgh! It just happened again
    Jonathan Michaelson

    Need your cPanel servers secured and tuned?
    cPanel Server Configuration, Security, Recovery and Antivirus/AntiSpam Services
    Developers of the most effective (and free) Firewall & Security Solution for cPanel Servers - csf
    http://www.configserver.com

  10. #25
    cPanel Partner NOC cPanel Partner NOC Badge jester.ro's Avatar
    Join Date
    Feb 2004
    Location
    Bucharest, Romania
    Posts
    304

    Default

    ok, how did you reply BEFORE i posted? )


    hmmm, funny

    a moment ago your post was above my post.

  11. #26
    Super Moderator This forum account has been confirmed by cPanel staff to represent a vendor. chirpy's Avatar
    Join Date
    Jun 2002
    Location
    Go on, have a guess
    Posts
    13,495

    Default

    This is just silly now.
    Jonathan Michaelson

    Need your cPanel servers secured and tuned?
    cPanel Server Configuration, Security, Recovery and Antivirus/AntiSpam Services
    Developers of the most effective (and free) Firewall & Security Solution for cPanel Servers - csf
    http://www.configserver.com

  12. #27
    cPanel Partner NOC cPanel Partner NOC Badge jester.ro's Avatar
    Join Date
    Feb 2004
    Location
    Bucharest, Romania
    Posts
    304

    Default

    i'll stop posting, i don;t wanna break the forum )

  13. #28
    Member
    Join Date
    Jan 2004
    Posts
    755

    Default

    Quote Originally Posted by chican0
    The primary problem is that the Main Account, the primary email address which is automaticaly created when the account is created (account username) will no longer accept emails.

    Out of curiosity, why do so many people create accounts with the same name used as the primary email address? On all of my accounts, the account name is never used as an email address. This adds a bit of "security through obscurity" as well as avoid the problems in having to work around :fail:

  14. #29
    Member
    Join Date
    Nov 2004
    Posts
    121

    Default

    Quote Originally Posted by Roy@ENHOST
    I think you have to add extra detection to the script.

    From what I know, this script will also switch the pipings that are required by helpdesk softwares to :fail:
    You have to use pregmatch regex to check that the destination is not a php,cgi or a binary.
    Hope that helps.
    Chirpy, thanks for the script!

    Roy, I modified the regex so that the perl script does not change any piped redirects (mailman seems to use such), and also script will leave default redirects to mail adresses but will still remove redirects to the unix username. This is to not mess with users who actually want to catch all mail of a domain and redirect it an existing mailbox.

    Code:
    #!/usr/bin/perl
    print "Converting all domain Default Accounts to :fail: ...\n\n";
    opendir (DIR, "/etc/valiases/") or die;
    while (my $file = readdir (DIR)) {
      if ($file =~ /^\./) {next}
      open (IN, "</etc/valiases/$file") or die;
      my @data = <IN>;
      close (IN);
      open (OUT, ">/etc/valiases/$file") or die;
      foreach my $line (@data)
      {
        if ($line =~ /^((\*\:\s+[a-zA-Z0-9]+\s*)|(\*\:\s*))$/)
        {
          print OUT "*: :fail:\n";
          print "Converted: [$file] $line";
        }
        else
        {
          print OUT $line;
          if ($line =~ !/^\*\:\s+\:fail\:/)
          {
            print "Kept: [$file] $line";
          }
        }
      }
      close (OUT);
    }
    print "\n\nDone!\n";
    Last edited by panayot; 10-15-2006 at 07:29 AM.

  15. #30
    Member
    Join Date
    Nov 2006
    Posts
    46

    Default script dies at line 9

    I am running Chirpy's script and I am getting output stating it dies at line 9.

    Line 9 is:

    open (OUT, ">/etc/valiases/$file") or die;

    It appears the first few domains might be getting changed to fail.

    I also tried the modified version of the script that is at the end of this thread and receive the same error message.

    Appreciate any thoughts.

    Chris

Similar Threads & Tags
Similar threads

  1. Replies: 1
    Last Post: 03-30-2008, 10:37 PM
  2. :fail: does not work to stop spoofed returned addresses
    By jackie46 in forum cPanel and WHM Discussions
    Replies: 17
    Last Post: 10-04-2006, 08:14 AM
  3. Mail > Default addresses
    By MacZilla in forum cPanel and WHM Discussions
    Replies: 1
    Last Post: 07-09-2004, 07:21 AM
  4. :fail: by default?
    By ckacerguis in forum cPanel and WHM Discussions
    Replies: 7
    Last Post: 03-10-2004, 02:51 PM
  5. Where are default Mail Addresses kept?
    By silentcircuit in forum cPanel and WHM Discussions
    Replies: 2
    Last Post: 07-09-2003, 07:28 PM
Linkedin       Facebook       Twitter       RSS       Flickr       YouTube