Search code examples
emailemail-bouncesverp

Explaining VERP


I am in the middle of making a bounce detection program, that reads bounce mails. Our setup is that we are sending out emails, adding a [email protected] to the sent mails. Some of the recipients does not exist anymore and therefor we want to read the bounce, and detect whom it was sent to. I have crumbled over this for a day or two now doing my googling and so. Now I have stumbled over something named VERP, Variable envelope return path. But is there someone here who can explain the technic to me in "human" terms?

I understand it in this way: send a mail to a recipient with a "FROM:" header set to [email protected].

But how do the recipient mail server deduct the return address in the FROM header if the recipient does not exists? Does it deduct it from the Return-Path instead set in the sent mail?

Hope someone understands my question, and can explain me how it works, or maybe tell me an alternat way of doing it.


Solution

  • Imagine this:

    You send a newsletter to :

    Bob and Jane addresses are no longer existent.

    Therefore for each mail address that you target you generate a unique Return-Path: address like so :

    Then checking your catch-all account on bounce.yourdomain.com (programatically) you find two emails :

    One for [email protected] and one for [email protected].

    You previously stored somewhere that 1 belongs to bob and 2 to Jane so you remove them from the newsletter list.