in reply to Re: Avoiding mail loops
in thread Avoiding mail loops

Using the Received field can lead to false positives when one uses multiple MTA's within the same domain.

The proper method is to add a custom header to the email and for incoming emails detect if that particular header is present (if so, then you have a loop condition).

Custom header names should start with 'X-' so as not to conflict with predefined names, e.g.

X-Loop: cormanaz@domain.tld