[exim] error code on redirect router for exceeding max msg s…

Top Page
Delete this message
Reply to this message
Author: Nicola Tiling
Date:  
To: exim-users
Subject: [exim] error code on redirect router for exceeding max msg size
Hi

I restrict the msg size per user with a sql query in a redirect router. The default error code for failed messages is „550“. This code is interpreted on the other mailserver as „recipient unknown“. Thats confusing people who sends to big mails. So I want an error code „552“. According to the manual it should be possible - but I can’t get it work

Chapter 22 - The redirect router: … "By default, Exim sends a 451 SMTP code for a :defer:, and 550 for :fail:. However, if the message starts with three digits followed by a space, optionally followed by an extended code of the form n.n.n, also followed by a space, and the very first digit is the same as the default error code, the code from the message is used instead."

I configured:

  driver              = redirect
  condition           = ${if >{$message_size}{${lookup pgsql{MAX_MSG}{${value}K}fail}} {true}{false}}
  data                = :fail: 552 Your message is too big.\n \



but it does not work. Error code is still „550“. What’s wrong with that item?

Thanks for your help
Nicola