# # LMTP2NNTP example.conf # ### DAEMON ### childsmax 10 #see -C aka --childsmax daemonize #see -D aka --daemonize kill #see -K aka --kill pidfile "/tmp/pid" #see -P aka --pidfile veryverbose #see -V aka --veryverbose # obsolete since v1.2 # remove the "buffer" channel from l2spec acl 10.0.0.0/8 #see -a aka --acl acl 172.16.0.0/12 acl 192.168.0.0/16 acl 127.0.0.1/32 bind 127.0.0.1:12345 #see -b aka --bind, use IPv4:port #bind "/tmp/uds:600" # UNIX domain socket path:permissions ### GATEWAY ### client 127.0.0.1:45678 #see -c aka --client destination 127.0.0.1:nntp #see -d aka --destination groupmode envelope #see -g aka --groupmode headervalue 'X-gateway: lmtp2nntp gateway' #see -h aka --headervalue #include "sampleconfig.two" # -i aka --include # -l is obsolete since v1.2, see l2spec l2spec ' \ debug: prefix(prefix="%%b %%d %%H:%%M:%%S <%%L> lmtp2nntp[%%P]: ",timezone=local) \ -> buffer(size=65536) \ -> file(path="2.log",append=0,perm=0666) \ ' #see -l aka --l2spec mailfrom "any.*@example\.org" #see -m aka --mailfrom nodename "gateway.example.com" #see -n aka --nodename operationmode post #see -o aka --operationmode restrictheader "Cc: j\.doe@example\.org" #see -r aka --restrictheader size 555000 #see -s aka --size timeoutlmtp 0 #see --timeoutlmtp, default for accept, read, write timeoutlmtpaccept 0 #see --timeoutlmtpaccept timeoutlmtpread 10 #see --timeoutlmtpread timeoutlmtpwrite 10 #see --timeoutlmtpwrite timeoutnntp 30 #see --timeoutnntp, default for connect, read, write timeoutnntpconnect 360 #see --timeoutnntpconnect timeoutnntpread 60 #see --timeoutnntpread timeoutnntpwrite 60 #see --timeoutnntpwrite user nobody #see -u aka --user version #see -v aka --version newsgroup "test" newsgroup "alt.test" #see man page for information about newsgroup ### CRUCIAL GATEWAY HEADER REWRITE RULES ### # merge values from duplicate headers and separte them with "comma space" headerrule 500:(Reply-To|To|Cc|Bcc):$0: [%{$0[#]}%{$0[#+1]:+, }] # keep only first value from duplicate headers headerrule 510:(X-Firstonly):$0: %{$0[0]} # replace empty Subject with text "None" headerrule 520:Subject: %{$Subject:-None} # create Message-ID if omitted or illegal (<> single @) headerrule 530:Message-id: %{messagid:s/^([^@+@[^@]+)$/<$1/:s/^[^<].*$/%{tool.createmessageid}/} # append a header headerrule 540::X-Append: Tail # remove a header (empty value) headerrule 550::X-Delete: