Advertisement
jdefelice

sendmail.mc.gmail.diff

Dec 9th, 2012
369
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Diff 4.66 KB | None | 0 0
  1. #
  2. # this has been tested on centos 5.x and 6.x and seems to work just fine.
  3. # when downloading this patch in raw mode you may need to convert it using dos2unix.
  4. #
  5. --- sendmail.mc 2012-12-09 14:21:02.000000000 -0500
  6. +++ sendmail.mc.gmail   2012-12-09 14:24:44.000000000 -0500
  7. @@ -24,6 +24,9 @@
  8.  dnl # be sent out through an external mail server:
  9.  dnl #
  10.  dnl define(`SMART_HOST', `smtp.your.provider')dnl
  11. +define(`SMART_HOST', `smtp.gmail.com')dnl
  12. +define(`RELAY_MAILER_ARGS', `TCP $h 587')dnl
  13. +define(`ESMTP_MAILER_ARGS', `TCP $h 587')dnl
  14.  dnl #
  15.  define(`confDEF_USER_ID', ``8:12'')dnl
  16.  dnl define(`confAUTO_REBUILD')dnl
  17. @@ -41,7 +44,7 @@
  18.  dnl # The following allows relaying if the user authenticates, and disallows
  19.  dnl # plaintext authentication (PLAIN/LOGIN) on non-TLS links
  20.  dnl #
  21. -dnl define(`confAUTH_OPTIONS', `A p')dnl
  22. +define(`confAUTH_OPTIONS', `A p')dnl
  23.  dnl #
  24.  dnl # PLAIN is the preferred plaintext authentication method and used by
  25.  dnl # Mozilla Mail and Evolution, though Outlook Express and other MUAs do
  26. @@ -49,18 +52,20 @@
  27.  dnl # guaranteed secure.
  28.  dnl # Please remember that saslauthd needs to be running for AUTH.
  29.  dnl #
  30. -dnl TRUST_AUTH_MECH(`EXTERNAL DIGEST-MD5 CRAM-MD5 LOGIN PLAIN')dnl
  31. -dnl define(`confAUTH_MECHANISMS', `EXTERNAL GSSAPI DIGEST-MD5 CRAM-MD5 LOGIN PLAIN')dnl
  32. +TRUST_AUTH_MECH(`EXTERNAL DIGEST-MD5 CRAM-MD5 LOGIN PLAIN')dnl
  33. +define(`confAUTH_MECHANISMS', `EXTERNAL GSSAPI DIGEST-MD5 CRAM-MD5 LOGIN PLAIN')dnl
  34.  dnl #
  35.  dnl # Rudimentary information on creating certificates for sendmail TLS:
  36.  dnl #     cd /etc/pki/tls/certs; make sendmail.pem
  37.  dnl # Complete usage:
  38.  dnl #     make -C /etc/pki/tls/certs usage
  39.  dnl #
  40. -dnl define(`confCACERT_PATH', `/etc/pki/tls/certs')dnl
  41. -dnl define(`confCACERT', `/etc/pki/tls/certs/ca-bundle.crt')dnl
  42. -dnl define(`confSERVER_CERT', `/etc/pki/tls/certs/sendmail.pem')dnl
  43. -dnl define(`confSERVER_KEY', `/etc/pki/tls/certs/sendmail.pem')dnl
  44. +define(`confCACERT_PATH', `/etc/pki/tls/certs')dnl
  45. +define(`confCACERT', `/etc/pki/tls/certs/ca-bundle.crt')dnl
  46. +define(`confSERVER_CERT', `/etc/pki/tls/certs/sendmail.pem')dnl
  47. +define(`confSERVER_KEY', `/etc/pki/tls/certs/sendmail.pem')dnl
  48. +define(`confCLIENT_CERT', `/etc/pki/tls/certs/sendmail.pem')dnl
  49. +define(`confCLIENT_KEY', `/etc/pki/tls/certs/sendmail.pem')dnl
  50.  dnl #
  51.  dnl # This allows sendmail to use a keyfile that is shared with OpenLDAP's
  52.  dnl # slapd, which requires the file to be readble by group ldap
  53. @@ -75,6 +80,7 @@
  54.  dnl FEATURE(delay_checks)dnl
  55.  FEATURE(`no_default_msa', `dnl')dnl
  56.  FEATURE(`smrsh', `/usr/sbin/smrsh')dnl
  57. +FEATURE(`authinfo', `hash -o /etc/mail/auth/client-info.db')dnl
  58.  FEATURE(`mailertable', `hash -o /etc/mail/mailertable.db')dnl
  59.  FEATURE(`virtusertable', `hash -o /etc/mail/virtusertable.db')dnl
  60.  FEATURE(redirect)dnl
  61. @@ -113,14 +119,14 @@
  62.  dnl # 127.0.0.1 and not on any other network devices. Remove the loopback
  63.  dnl # address restriction to accept email from the internet or intranet.
  64.  dnl #
  65. -DAEMON_OPTIONS(`Port=smtp,Addr=127.0.0.1, Name=MTA')dnl
  66. +DAEMON_OPTIONS(`Port=smtp, Name=MTA')dnl
  67.  dnl #
  68.  dnl # The following causes sendmail to additionally listen to port 587 for
  69.  dnl # mail from MUAs that authenticate. Roaming users who can't reach their
  70.  dnl # preferred sendmail daemon due to port 25 being blocked or redirected find
  71.  dnl # this useful.
  72.  dnl #
  73. -dnl DAEMON_OPTIONS(`Port=submission, Name=MSA, M=Ea')dnl
  74. +DAEMON_OPTIONS(`Port=submission, Name=MSA, M=Ea')dnl
  75.  dnl #
  76.  dnl # The following causes sendmail to additionally listen to port 465, but
  77.  dnl # starting immediately in TLS mode upon connecting. Port 25 or 587 followed
  78. @@ -153,24 +159,25 @@
  79.  dnl # Also accept email sent to "localhost.localdomain" as local email.
  80.  dnl #
  81.  LOCAL_DOMAIN(`localhost.localdomain')dnl
  82. +LOCAL_DOMAIN(`mail.int.foobar.com')dnl
  83. +LOCAL_DOMAIN(`int.foobar.com')dnl
  84.  dnl #
  85.  dnl # The following example makes mail from this host and any additional
  86.  dnl # specified domains appear to be sent from mydomain.com
  87.  dnl #
  88. -dnl MASQUERADE_AS(`mydomain.com')dnl
  89. +dnl # MASQUERADE_AS(`mydomain.com')dnl
  90.  dnl #
  91.  dnl # masquerade not just the headers, but the envelope as well
  92.  dnl #
  93. -dnl FEATURE(masquerade_envelope)dnl
  94. +dnl # FEATURE(masquerade_envelope)dnl
  95.  dnl #
  96.  dnl # masquerade not just @mydomainalias.com, but @*.mydomainalias.com as well
  97.  dnl #
  98. -dnl FEATURE(masquerade_entire_domain)dnl
  99. +dnl # FEATURE(masquerade_entire_domain)dnl
  100.  dnl #
  101.  dnl MASQUERADE_DOMAIN(localhost)dnl
  102.  dnl MASQUERADE_DOMAIN(localhost.localdomain)dnl
  103. -dnl MASQUERADE_DOMAIN(mydomainalias.com)dnl
  104. -dnl MASQUERADE_DOMAIN(mydomain.lan)dnl
  105. +dnl MASQUERADE_DOMAIN(int.foobar.com)dnl
  106.  MAILER(smtp)dnl
  107.  MAILER(procmail)dnl
  108.  dnl MAILER(cyrusv2)dnl
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement