sendmail transition: Do not pre-generate sendmail.cf
[dragonfly.git] / contrib / sendmail-8.14 / mail.local / README
1 This directory contains the source files for mail.local.
2
3 This is not intended to be used on *stock* System V derived systems such as
4 Solaris or HP-UX, since they use a totally different approach to mailboxes
5 (essentially, they have a set-group-ID program rather than set-user-ID, and
6 they rely on the ability to "give away" files to do their work).
7
8 If you choose to run *this* mail.local on these systems then you may also
9 need to replace the existing MUAs, as well as IMAP and POP servers, with
10 ones that are compatible with the BSD interface.  You have been warned!
11
12 For systems with maillock() support, compile with -DMAILLOCK and link with
13 -lmail to use the maillock() routines.  This can be accomplished in your
14 site.config.m4 file with:
15
16         APPENDDEF(`conf_mail_local_ENVDEF', `-DMAILLOCK')
17         APPENDDEF(`conf_mail_local_LIBS', `-lmail')
18
19 Defining CONTENTLENGTH (-DCONTENTLENGTH) will build a mail.local which
20 outputs a Content-Length: header.  Solaris 2.3 and later will automatically
21 include Content-Length: support.  This can be accomplished in your
22 site.config.m4 file with:
23
24         APPENDDEF(`conf_mail_local_ENVDEF', `-DCONTENTLENGTH')
25
26 Defining MAILGID to a 'gid' (-DMAILGID=6) will cause mailboxes to be
27 written group writable and with group 'gid'.  This can be accomplished in
28 your site.config.m4 file with:
29
30         APPENDDEF(`conf_mail_local_ENVDEF', `-DMAILGID=6')
31
32 mail.local will not be installed set-user-ID root. To use it as local
33 delivery agent without LMTP mode, use:
34
35          MODIFY_MAILER_FLAGS(`LOCAL', `+S')
36
37 in the .mc file.
38
39 Defining HASHSPOOL (-DHASHSPOOL) will build a mail.local which supports
40 delivering to subdirectories of the mail spool, based on a hash of the
41 username (i.e., a hash depth of 2 and a username of "user" will result in
42 /var/spool/mail/u/s/user).  If the hash depth is greater than the length
43 of the username, "_" will be used.  The necessary subdirectories must
44 exist; mail.local will not create them.  Use the "-H" option to set the
45 hash type and depth (like "-H u2" for a username hash two levels deep).
46
47 The HASHSPOOL option also adds two other options: "-p path" to specify
48 an alternate mail spool path (i.e., "-p /local/mail") and "-n" to specify
49 that mail.local should not strip the @domain part of recipient addresses
50 in LMTP mode.
51
52 In addition to HASHSPOOL, defining HASHSPOOLMD5 and linking against
53 libcrypto from OpenSSL like:
54
55         APPENDDEF(`conf_mail_local_ENVDEF', `-DHASHSPOOL -DHASHSPOOLMD5')
56         APPENDDEF(`conf_mail_local_LIBS', `-lcrypto')
57
58 will offer an alternate hash, using a base64 encoding (changing / to _)
59 of an MD5 hash of the username.  This results in a more balanced
60 subdirectory tree.  The subdirectories will be named with A-Z, a-z, 0-9,
61 +, and _.  The hash type is "m", so use "-H m3" to get a three level MD5
62 based hash.
63
64 $Revision: 8.11 $, Last updated $Date: 2003/10/20 20:19:13 $