[exim] Help needed with tainting

Pàgina inicial
Delete this message
Reply to this message
Autor: Alain D D Williams
Data:  
A: Exim Users
Assumpte: [exim] Help needed with tainting
I'm upgrading to a new exim that implements tainting (runs on Rocky Linux).

This causes a problem as I use $local_part in a file name - both in the router
and in the transport.

The transport works by running a command of which an argument is extracted (the
line starting .dir) from a file /etc/exim/file_domains/$local_part
The transport is taint safe if the router de-taints $local_part

I think that I should be using dsearch but the documentation about dsearch does
not help -- not enough for me to understand it.

My transport & router are below, how should I modify them to do what I want.

Thanks in advance


# Look in /etc/exim/file_domains/$local_part for the sender address
mail_to_url_router:
driver = accept
domains = +file_domains
condition = ${if exists {/etc/exim/file_domains/$local_part}{1}{0}}
require_files = /etc/exim/file_domains/$local_part
senders = ${if exists {/etc/exim/file_domains/$local_part} {lsearch;/etc/exim/file_domains/$local_part}{*}}
transport = mail_to_url_transport
no_more

mail_to_url_transport:
driver = pipe
command = /usr/bin/MailToUrl $local_part $sender_address $header_subject ${lookup{.dir}lsearch{/etc/exim/file_domains/$local_part}}
user = mail
group = apache
return_fail_output = true


--
Alain Williams
Linux/GNU Consultant - Mail systems, Web sites, Networking, Programmer, IT Lecturer.
+44 (0) 787 668 0256 https://www.phcomp.co.uk/
Parliament Hill Computers Ltd. Registration Information: https://www.phcomp.co.uk/Contact.html
#include <std_disclaimer.h>