1 Date: Tue, 23 Nov 1999 02:49:32 +0200
2 From: Vadim Vygonets <vadik@cs.huji.ac.il>
4 Something Hans Matzen and I did.
6 # These are config file snippets for handling certain remote
7 # addresses as local, and making only real external addresses
12 # Hans Matzen <hans@tm.informatik.uni-frankfurt.de>,
13 # Vadim Vygonets <vadik@vygo.net>. All rights reserved.
15 #################################################################
16 # These are config file snippets for handling certain remote
17 # addresses as local, and making only real external addresses
20 # First, adjust values of the following definitions, which will
21 # be used in configuration snippets below:
25 LOCAL_NET = 192.168.0.0/16
26 SMART_HOST = cc.huji.ac.il
29 # The scheme is to use global addresses everywhere, which is done
30 # by rewriting envelope sender and all headers, using a dbm file
31 # EXIM_DIR/in2ex, which maps internal local parts to external
32 # e-mail addresses using entries like:
33 # user: someone@remote.dom
35 # To do this, it good to hide hostnames in all envelope and
36 # header addresses first, using this rewriting rule:
38 *@*.LOCAL_DOM $1@LOCAL_DOM Eh
40 # Then, rewrite envelope sender and all headers to external
41 # addresses with this rule:
43 *@LOCAL_DOM ${lookup{${lc:$1}}dbm{EXIM_DIR/in2ex}{$value}fail} Fh
46 # This means that envelope recipients must be somehow rewritten
47 # back to local addresses, which is done in one of the two
48 # proposed ways (you choose).
50 # One way to do it is by rewriting, using a dbm file
51 # EXIM_DIR/ex2in, which maps external e-mail addresses to
52 # internal local parts using entries like:
53 # someone@remote.dom: user
55 # This is done with the rewriting rule:
57 # *@* ${lookup{${lc:$0}}dbm{EXIM_DIR/ex2in}{$value@LOCAL_DOM}fail} T
60 # The preferred way to do it is by treating certain e-mail
61 # addresses on remote domains as local, using route_list and self
62 # options to the domainlist routers, looking up e-mail addresses
63 # in dbm file EXIM_DIR/ex2in and throwing values away. This is
64 # an example of such router. It should probably the only router
65 # in the configuration.
69 transport = remote_smtp
70 route_list = "* ${lookup{$local_part@$domain}dbm\
71 {EXIM_DIR/ex2in}{@}{SMART_HOST}} bydns_a"
75 # Then, IF local parts of some of your users are different in
76 # their internal and external addresses, it's nice to have the
77 # internal_adjust smartuser director to rewrite the address. It
78 # should probably be the first director.
82 new_address = "${lookup{${lc:$local_part@$domain}}dbm{EXIM_DIR/ex2in}\
83 {$value@LOCAL_DOM}fail}"