How to alllow an email address to send email but not recieve emal

Discussion in 'HOWTO-Related Questions' started by tyliong, Jan 8, 2009.

  1. tyliong

    tyliong New Member

    Hi,

    I am creating an autentication system, i want to turn one of my accounts into a sender account. but stop all external emails from being recieved by it.
     
  2. falko

    falko Super Moderator

    You could create a new alias in /etc/aliases:
    Code:
    username: /dev/null
    (Replace username with the username of the account.)
    Run
    Code:
    newaliases
    afterwards and restart Postfix.
     
  3. tyliong

    tyliong New Member

    is the username with the @mydomain.com??
    cause i have tried both with out the @ and with and i can still sendmail to the account.

    I tried what u said but i got this instead
    mydomain_mailer@mydomain.com... cannot alias non-local names
     
  4. falko

    falko Super Moderator

    It's the system user name of that account (works unless you have a virtual user setup).
     
  5. tyliong

    tyliong New Member

    Is there any work around for a virtual account?
     
  6. falko

    falko Super Moderator

    You could forward the mail to a system user and then send that mail to /dev/null using the aliases file.
     
  7. tyliong

    tyliong New Member

    but that means mail is still recieved by the virtual email client right?

    How do i set up a local account to accept or send mail?
    Can i access this local account through pop3 and smtp?
     
  8. falko

    falko Super Moderator

  9. tyliong

    tyliong New Member

    postconf -e 'home_mailbox = Maildir/'
    postconf -e 'mailbox_command ='
    /etc/init.d/postfix restart

    if i do these commands will all my virtual users be disabled? and only local accounts will recieve email?

    do i need to modify any of the values here or i just literally take all the values u stated?
     
  10. falko

    falko Super Moderator

    If you're currently using Maildir, you can use these settings. If you're using mbox, you shouldn't use them.
     

Share This Page