Re: [Exim] Relay for Domain anywhere, using SMTP Authenticat…

Pàgina inicial
Delete this message
Reply to this message
Autor: Kirill Miazine
Data:  
A: Peter Galbavy
CC: exim-users
Assumpte: Re: [Exim] Relay for Domain anywhere, using SMTP Authentication only?
Peter Galbavy wrote:
> > Excuse my ignorance, but I can't make heads or tales of the
> > documentation on this. I simply want to be able to use my domain
> > anywhere using SMTP authentication without the host being checked. Is
> > there a simple way to do this? I guess I'm spoiled by the Windows
> > mailservers I've used.
>
> Here is what I use for supporting most clients I can:
>
> plain_password:
> driver = plaintext
> public_name = PLAIN
> server_condition = ${if crypteq{$3}{${lookup pgsql{select password from
> users
> where (username || '@' || domain = '$2') or (username = '$2' and domain =
> 'default.com') }{$value}fail}} {1}}
> server_set_id = $2
>
> login_password:
> driver = plaintext
> public_name = LOGIN
> server_prompts = "Username:: : Password::"
> server_condition = ${if crypteq{$2}{${lookup pgsql{select password from
> users
> where (username || '@' || domain = '$1') or (username = '$1' and domain =
> 'default.com') }{$value}fail}} {1}}
> server_set_id = $1


Ever heard about ${quote_pgsql? $2 and $1 can contain random garbage.
That does not mean a lot if the user Exim uses to connect to Pg only has
SELECT rights. Quoting is a good habit though. :)

--
Kirill Miazine
mailto:km@krot.org
http://km.krot.org/