Re: A couple of problems
- Original Message - From: Benny Pedersen m...@junc.org To: postfix-users@postfix.org Date: Wed, 02 Sep 2009 20:43:10 +0200 Subject: Re: A couple of problems On ons 02 sep 2009 20:06:08 CEST, Daniel L'Hommedieu wrote I guess nobody has any ideas on the other problem I mentioned, because nobody has responded to that half of my original email. :( are you saying that your wife cant use smtp auth ? :) -- xpoint I bet it definitely must be that! :)) Well, look like its time for you, to supply your wife with a proper amount of educatinon. ;)
Re: Simple filter via pipe
It seems Noel was right: you need to learn your basics before moving forward with Postfix. See 'Explanations of Man Sections' here: http://www.freebsd.org/cgi/man.cgi -- Sahil Tandon sa...@tandon.net There was some error when user, other than root, has been filtering mail. Error was visible only when I manually executed: # cat mail_in_file | ./mail_filter.php r...@example1.com j...@example2.com Syntax error: ( unexpected I simply changed php code related to execution of shell functions.(to work for user other than root) Finally, I've completely solved a problem. Error: Syntax error: ( unexpected, wasn't in postfix error log: /var/log/maillog And by passing macro ${sasl_method} in addition to ${sender} ${recipient} in /usr/local/etc/postfix/master.cf I am able to selectivly apply filtering ONLY to SASL authed users and avoid all others Guys! You are constantly totally confusing me, literally not saying anything useful to me! Just giving me too ambiguous(many possible interpretations) DIRECTIONS. Thankx anyway ;)
Re: Simple filter via pipe
- Original Message - From: Sahil Tandon sa...@tandon.net To: postfix-users@postfix.org Date: Mon, 31 Aug 2009 23:37:56 -0400 Subject: Re: Simple filter via pipe On Tue, 01 Sep 2009, rank1see...@gmail.com wrote: I don't believe I can help you any further. I think it is about me comprehending pipe term. I know how data is piped from one command to another or from file, or to file descriptor, etc. Ie: output only mp3 files from current dir list # ls -al | grep *.mp3 So what does sendmail is a pipe means, in this context? At your shell, type 'man 8 pipe' and read carefully. -- Sahil Tandon sa...@tandon.net Thanks. On FreeBSD that is section 2 http://www.freebsd.org/cgi/man.cgi?query=pipesektion=2apropos=0manpath=FreeBSD+7.2-RELEASE I've read it and still have no logical clue.
Re: Simple filter via pipe
- Original Message - From: Noel Jones njo...@megan.vbhcs.org To: postfix-users@postfix.org Date: Mon, 31 Aug 2009 19:42:02 -0500 Subject: Re: Simple filter via pipe On 8/31/2009 6:09 PM, none none wrote: If you describe what original problem you're trying to solve maybe you can get some better pointers. -- Noel Jones Done Noel! ;) Your problem report is a mess. ROFLMAO! :))) That is very funny Noel! ;) I don't believe I can help you any further. I think it is about me comprehending pipe term. I know how data is piped from one command to another or from file, or to file descriptor, etc. Ie: output only mp3 files from current dir list # ls -al | grep *.mp3 So what does sendmail is a pipe means, in this context? Since you don't seem to have understood my answers, probably a book on using Unix or Linux would help you most at this point. Actually I am on Freebsd 7.2 So UNIX book type..., I have already. But not went through it all... If you have further questions, please see: http://www.postfix.org/DEBUG_README.html#mail -- Noel Jones I asked too much... So instead of 2 issues, I should ask 0.5 question instead ;) Maybe tactic of isolation of problem and focusing only on it and ignoring rest in context, at least while that one ain't solved. Then going in logical upward, to next It is 3 am here, so I'll hit a bed now. Tomorow..., I'll be smarter...
Re: Building milter in PHP
- Original Message - From: wie...@porcupine.org (Wietse Venema) To: Postfix users postfix-users@postfix.org Date: Sat, 22 Aug 2009 19:18:19 -0400 (EDT) Subject: Re: Building milter in PHP none none: I've setup postfix for before queue I have not chosen to install milter but to create my own. I did that in PHP. Now, I am at a part, where my PHP milter has to communicate with postfix. Aim is to get string from postfix, evaluate it and send it back to postfix. So I started to read as a first action. Errors I did received were: can't read SMFIC_OPTNEG reply packet header: Operation timed out The Sendmail MILTER protocol is completely different from SMTP. PHP already comes with a SAPI (server API) that supports this protocol, and you should probably build your application that way. See, for example: http://www.google.com/search?q=php+milter Wietse It did, but not anymore. It is now depreciated.(php-milter) I use PHP 5.3 and already have working filter. To finalise it, I just need a list and description of milter commands. Those milter commands works for any type of coding language Up to now I've found out these but without explanation or examples connect helo envfrom envrcpt header eoh body eom abort close
Re: Special needs(filter - SASL)
- Original Message - From: Brian Evans - Postfix List grkni...@scent-team.com To: Postfix users postfix-users@postfix.org Date: Wed, 19 Aug 2009 14:41:51 -0400 Subject: Re: Special needs(filter - SASL) none none wrote: I would like email to be filtered ONLY from user that relays(SASL authed) mail to the outside(not localhost) mailbox. That is, if that same user is sending mail from local machine(no relaying) then filter doesn't kicks in. I've looked at postfix man pages and documentation and it is too much hassle about creating other instances of smtp ot smtpd etc... and pcre has limited caps for me. I am very skilled when it comes to PHP, so would like to create PHP script that would suck that mail in and spit it out for delivery by postfix. But Right now I would be happy even with in /usr/local/etc/postfix/main.cf: header_checks = pcre:/usr/local/etc/postfix/strip_relay_header BUT, that header_checks rule should kick in ONLY for remote SASL authed user when target mailbox is NOT locally hosted (goes out to the internet) header_checks are applied globally for an instance. There is no way around that fact. What *is* possible is to use a content_filter or milter instead. See some ideas here: http://www.postfix.org/FILTER_README.html http://www.postfix.org/MILTER_README.html I think I will go for before-queue Milter support SMTP-only - which means It will be applied to incoming mail from the internet(Both SASL authed and those from outside senders with target as/for local mailboxes) I am a little bit puzzled with qmqpd. When it kicks in? I read only explicitly authorized client hosts are allowed to use the service And is in network category, so were hopping that, it would be my ticket to apply filter only to SASL authed users and no one else. /etc/postfix/main.cf: # Milters for mail that arrives via the smtpd(8) server. # See below for socket address syntax. smtpd_milters = unix:/path/to/php_daemon/its.sock This is how I link to my php daemon. Now tell me, how does string(which is mail[it's header body]) is PASSED to and RETRIEVED back to postfix? I mean, is it true, that string(which is mail[it's header body]) goes to its.sock AND after filtering, is returned to postfix, again, via its.sock