changing incoming Subject: headers?
lnxgeek at us.ibm.com
Wed Apr 17 20:48:04 UTC 2002
Thanks, this was the pointer I was looking for.
On Wed, Apr 17, 2002 at 04:44:34PM -0400, Jeffrey M. Vinocur wrote:
> On Wed, 17 Apr 2002, Scott Russell wrote:
> > I see with inn 2.3.2 I can use perl filters to do things. Is it possible to
> > strip out some contents of the Subject: header before it's posted to the
> > group?
> Sure (and doing what you describe with a regular expression in Perl would
> be quite easy). Read the README.perl_hook file in your source tree.
> Unlike the innd Perl filter, the nnrpd Perl filter can modify the %hdr
> hash. In fact, if the Perl variable $modify_headers is set to true
> after filter_post() returns, the contents of the %hdr hash will be
> written back to the article replacing the original headers.
> filter_post() can therefore make any modifications it wishes to the
> headers and those modifications will be reflected in the article as it's
> finally posted. The article body cannot be modified in this way; any
> changes to $body will just be ignored.
> Jeffrey M. Vinocur
> jeff at litech.org
Scott Russell (lnxgeek at us.ibm.com)
Linux Technology Center, System Admin, RHCE.
T/L 441-9289 / External 919-543-9289
More information about the inn-workers