On 05/17/2011 06:22 PM, Yessica De Ascencao wrote:
Hi people!

I have my system in an internal email using Postfix.
I saw this way of implementing a filter. However, I am trying script

  1 #!/bin/sh
  2
  3 # Simple shell-based filter. It is meant to be invoked as follows:
  4 #       /path/to/script -f sender recipients...
  5
  6 # Localize these. The -G option does nothing before Postfix 2.3.
  7 INSPECT_DIR=/var/spool/filter
  8 SENDMAIL="/usr/sbin/sendmail -G -i" # NEVER NEVER NEVER use "-t" here.
  9
10 # Exit codes from<sysexits.h>
11 EX_TEMPFAIL=75
12 EX_UNAVAILABLE=69
13
14 # Clean up when done or when aborting.
15 trap "rm -f in.$$" 0 1 2 3 15
16
17 # Start processing.
18 cd $INSPECT_DIR || {
19     echo $INSPECT_DIR does not exist; exit $EX_TEMPFAIL; }
20
21 cat>in.$$ || {
22     echo Cannot save mail to file; exit $EX_TEMPFAIL; }
23
24 # Specify your content filter here.
25 # filter<in.$$ || {
26 #   echo Message content rejected; exit $EX_UNAVAILABLE; }
27
28 $SENDMAIL "$@"<in.$$
29
30 exit $?


Ask the author of this script how it is intended to be used.

as is, without any change but not copying.
I'm not sure how to execute the instruction, this line is not clear:
% /path/to/script -f sender -- recipient...<message-file

Ask the author of this script how it is intended to be used.


Know  anything about this?

I hope you can  help me.

Thank you very much.
Greetings!

http://www.postfix.org/FILTER_README.html

--
J.

Reply via email to