LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Networking
User Name
Password
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.

Notices

Reply
 
Search this Thread
Old 02-23-2007, 06:13 AM   #1
lasantha
Member
 
Registered: Oct 2005
Location: Sri Lanka
Distribution: Red Hat, Cent OS
Posts: 38

Rep: Reputation: 16
Thumbs down sendmail.cf mail rule written language


Hi All,
I would like to learn language which used to write rulesets in the sendmail.cf file for write custom ruleset for mail routing. Pls send me any urls that will discribe thease?
Indika
 
Old 02-24-2007, 07:33 AM   #2
MensaWater
Guru
 
Registered: May 2005
Location: Atlanta Georgia USA
Distribution: Redhat (RHEL), CentOS, Fedora, Debian, FreeBSD, HP-UX, Solaris, SCO
Posts: 5,950
Blog Entries: 5

Rep: Reputation: 755Reputation: 755Reputation: 755Reputation: 755Reputation: 755Reputation: 755Reputation: 755
Strictly speaking you're not supposed to update sendmail.cf but rather sendmail.mc then use m4 to "compile" it to the sendmail.cf.

Have a a look at /etc/mail/sendmail.mc for information on this.

From the top of /etc/mail/sendmail.mc on my FC4 workstations:

Quote:
dnl # This is the sendmail macro config file for m4. If you make changes to
dnl # /etc/mail/sendmail.mc, you will need to regenerate the
dnl # /etc/mail/sendmail.cf file by confirming that the sendmail-cf package is
dnl # installed and then performing a
dnl #
dnl # make -C /etc/mail
 
Old 02-26-2007, 12:10 AM   #3
lasantha
Member
 
Registered: Oct 2005
Location: Sri Lanka
Distribution: Red Hat, Cent OS
Posts: 38

Original Poster
Rep: Reputation: 16
Thanks for your comment on this, I am really advised me to not to use sendmail.cf in free hand. Yes I believe that.
But I need to write my own rulesets for sendmail header rewriting and sending to given recepient via local mailer according to my own way. I need to study this mail ruleset written language because of this. Pls update me any way of learning this...
Thanks
 
Old 02-26-2007, 10:08 AM   #4
MensaWater
Guru
 
Registered: May 2005
Location: Atlanta Georgia USA
Distribution: Redhat (RHEL), CentOS, Fedora, Debian, FreeBSD, HP-UX, Solaris, SCO
Posts: 5,950
Blog Entries: 5

Rep: Reputation: 755Reputation: 755Reputation: 755Reputation: 755Reputation: 755Reputation: 755Reputation: 755
I think you missed the point in my post. The point is you create the ruleset in the sendmail.mc then use m4 to make senmail.cf file based on what you wrote in the sendmail.mc. Otherwise you risk having someone down the road running the make on you and blowing away your cf modifications.

If you really want to figure out what it does when you do the make you can have a look at the include file that it uses (grep include /etc/mail/sendmail.cf) then look at the files that the include includes then look at the source for sendmail if it still doesn't make sense. It seems it would be a lot easier to work with the way it is designed than to try to go around it.
 
Old 02-27-2007, 12:10 AM   #5
lasantha
Member
 
Registered: Oct 2005
Location: Sri Lanka
Distribution: Red Hat, Cent OS
Posts: 38

Original Poster
Rep: Reputation: 16
Thank you very much for the comment.
I have checked this But I couldnt find out any good information on writing rule-sets in sendmail.mc file in the web.
I you kone any link pls post it.
Thanks.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
How to make Sendmail forward all incoming mail to localhost port 26 (Domino mail) speedgelb Linux - Software 3 09-27-2013 10:18 AM
Import Mail from /var/spool/mail (sendmail) to a MailDir Format in Postfix shawnbishop Linux - Software 0 04-06-2006 10:44 AM
What language was the unreal tournament installer written in? Onemessedupjedi Programming 2 07-05-2004 01:48 AM
How to control the rule of netfilter using C language? bobowd Linux - General 1 06-07-2002 10:32 PM
Sendmail - RunAsUser=sendmail:mail/What files to i have to change ForumKid Linux - Security 45 01-18-2002 11:47 AM


All times are GMT -5. The time now is 01:29 AM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration