Our mail server hasn't been touched in a couple years before I got here.
I am trying to add a LOCAL_RULESET to our sendmail.mc so I can run the m4 command to generate the sendmail.cf file.
we have about 25 *.mc files on the server, and I am not sure which one was used to make our current config.
is there a way to find out which mc file was used, or can I re-generate the mc file from the existing *.cf file?
I had tried adding this rule to our best-guess at which mc file it was
Code:
LOCAL_CONFIG
F{Internal}/etc/mail/intern.only
LOCAL_RULESETS
SLocal_check_rcpt
# if the recipient isn't internal, they get the mail
R$+ $: <@> $>3 $1
R<@> $={Internal}<@$=w.> $: <$1@$2>
R<@> $={Internal} $: <$1@$j>
# no internal alias
R<@>$+ $@ OK
# check to see if the sender is local
R$* $: $>3 $&f
R$+<@$=w.> $@ OK
# empty sender: accept (RFC 1123)
R<@> $@ OK
R$+ $#error $: 551 $&f not allowed to send to recipient
after I put that code into our mc file and ran the m4 command, the resulting file was nothing like the cf file we have in production.
I have looked on google to see about how exactly to add LOCAL_RULESETS, and I have a sendmail book here (for version 8.8) but I am having problems making it make sense.
Any assistance would be thrilling!