🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: news.software.nntp
Article #58968

INN : Removing headers with Python filter?

#58968
From: G Hardman
Date: Fri, 24 May 2002 14:33
26 lines
1707 bytes
Hi all,

I have *almost* got an all-singing, all-dancing Python article filter 
working on our INN server. However, as part of a local security hack, we 
add an extra header containing a token to verify the sender is who he says 
he is, match this token against one stored on the news server, and then 
remove the header so the user is none the wiser (and more importantly, 
can't use it to get access to restricted groups).

However I can't seem to be able to remove headers from the dictionary (or 
at least, the removal isn't passed on to INN). I'm currently doing 
something like :

....
permit = art[Posting_Permit]
del art[Posting_Permit]
....

Is there something more I should know (ie am I missing something obvious),
or alternatively, does anyone have the required hacks to python.c to
enable this to work?

Cheers in advance,
G

Technical Details
Message-ID: <slrnaesjq3.i8n.gph@cslin200.leeds.ac.uk>
Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!archive.pugleaf.net!archive.newsdeef.eu!mbox2nntp-news.software.nntp.mbox.zip!archiver1.google.com!news1.google.com!newsfeed.stanford.edu!news-spur1.maxwell.syr.edu!news.maxwell.syr.edu!fu-berlin.de!server1.netnews.ja.net!server5.netnews.ja.net!leeds-iss.ac.uk!gph

Show Full Headers
Complete Article Headers
Message-ID: <slrnaesjq3.i8n.gph@cslin200.leeds.ac.uk>
Subject: INN : Removing headers with Python filter?
Date: Fri, 24 May 2002 14:33:41 GMT
From: G Hardman <gph@nospam.comp.leeds.ac.uk>
Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!archive.pugleaf.net!archive.newsdeef.eu!mbox2nntp-news.software.nntp.mbox.zip!archiver1.google.com!news1.google.com!newsfeed.stanford.edu!news-spur1.maxwell.syr.edu!news.maxwell.syr.edu!fu-berlin.de!server1.netnews.ja.net!server5.netnews.ja.net!leeds-iss.ac.uk!gph
Newsgroups: news.software.nntp
User-Agent: slrn/0.9.7.2 (Linux)
Sender: usenet@leeds.ac.uk (Usenet admin)
Organization: School of Computing, University of Leeds
Originator: gph@Linux
X-Nntp-Posting-Host: cslin200.leeds.ac.uk
Lines: 25