Forums

Create email address on server at registration (3 posts)

  1. wondermade
    Member
    Posted 1 month ago #

    I want to setup a post-by-email feature on the site, but I want to avoid giving every user the same email address to send to for security reasons. My ideal scenario would be to give every user something like username@mysite.com where every address just forwards to a single address that WP is scheduled to check. Then I validate by matching the sending address against the original sent-to address and I'd be set.

    But I can't figure out how to create email address automatically on my server. Any know how I'd go about doing that? Thanks for any help or direction!

  2. tdjcbe
    Member
    Posted 1 month ago #

    It would be helpful if you told us what you were running for a server as well as a hosting platform. What commands are dependent on what you;re running.

  3. SteveAtty
    Member
    Posted 1 month ago #

    To be honest 99% of that is outside of WPMU. You need to set up a virtual domain with wildcard forwarding in your email server . Or that's how I'd do it so there is no creation of email addresses by your code. Postfix can do it very easily - you'd need about 4 lines of configuration to implement it. (in fact I just did it and its 3 lines in total, two files to edit and one postmap command)

    All you need to do then is process the single email file that contains all the email for the virtual domain, and then cross check the sender email and the destination email address to confirm that it is a posting. You might want to include the use of a keyphrase (or a number) which is generated by the user as a double check (which is how LiveJournal do it).

Reply

You must log in to post.

About this Topic