1. Can you please share the exact bounce email ?

It would provide more infos on the failure and where it happens.

2. Please provide smtpserver.xml.

Smtp layer may validate that local domains users exists. Failure to do so will 
result in bounces.

3. I would encourage writing a dedicaed matcher "LocalPartIsPhoneNumber"
Paired with DomainIs matcher which shall be case incentive we will ge something 
way more resilient.

Alast, I encourage you to test the regex suppied in RecipientIsRegex unit 
tests: 
https://github.com/apache/james-project/blob/master/mailet/standard/src/test/java/org/apache/james/transport/matchers/RecipientIsRegexTest.java
 

Cheers

-- 

Best regards,

Benoit TELLIER

General manager of Linagora VIETNAM.
Product owner for Team-Mail product.
Chairman of the Apache James project.

Mail: btell...@linagora.com
Tel: (0033) 6 77 26 04 58 (WhatsApp, Signal)


On Aug 20, 2025 4:48 PM, from Matt Pryor <pr...@international-presence.com>Hi 
there

I have the following in my mailetcontainer.xml:

    <processor state="root" enableJmx="true">
       <mailet
match="RecipientIsRegex=\+?\d[\.\d\-]+@[iI][mM][pP][sS][cC][lL][oO][uU][dD]\.[cC][oO][mM]"
class="Redirect">
       <recipients>outbo...@impscloud.com</recipients>
       <to>to</to>
       <inline>unaltered</inline>
       <passThrough>FALSE</passThrough>
       <static>TRUE</static>
     </mailet>
     ....

The idea being that if emails come into (phone number)@impscloud.com the
email gets redirected to outbo...@impscloud.com, and then we have a
pop/imap process picking up the email from that mailbox which sends the
email contents as a fax to the phone number part.
This used to work perfectly under James 3.0.1.
However since upgrading to James 3.8.2 it no longer works, instead the
emails get bounced with "address not found".
Am I missing some other subtle config setting? Everything else in the xml
file looks the same as our old mail server from what I can tell.
Happy to share the whole mailetcontainer.xml if nothing is obvious from
this snippet.

Thanks a lot
Matt







Kind regards
Matt Pryor
Research and Development Manager

The International Presence Group of Companies
EMAIL: pr...@presencebpm.com
URL: International-presence.com

Reply via email to