Discarding defers from the command line
Is there a command-line way to "discard all messags marked defer"? /Bernie\
-- Bernie Cosell Fantasy Farm Fibers mailto:bernie@fantasyfarm.com Pearisburg, VA --> Too many people, too few sheep <--
On Tue, May 12, 2009 at 08:27:45AM -0400, Bernie Cosell wrote:
Is there a command-line way to "discard all messags marked defer"?
listadmin, perhaps?
q.v., <http://wiki.list.org/x/aIA9>
-- If all else fails, immortality can always be assured by spectacular error. (Galbraith)
Adam McGreggor wrote:
On Tue, May 12, 2009 at 08:27:45AM -0400, Bernie Cosell wrote:
Is there a command-line way to "discard all messags marked defer"?
listadmin, perhaps?
q.v., <http://wiki.list.org/x/aIA9>
Actually a FAQ more specific to this question is <http://wiki.list.org/x/nIA9>.
-- Mark Sapiro <mark@msapiro.net> The highway is for gamblers, San Francisco Bay Area, California better use your sense - B. Dylan
On 12 May 2009 at 17:58, Mark Sapiro wrote:
On Tue, May 12, 2009 at 08:27:45AM -0400, Bernie Cosell wrote:
Is there a command-line way to "discard all messags marked defer"?
Actually a FAQ more specific to this question is <http://wiki.list.org/x/nIA9>.
I've been pushing on this some, to no avail at the moment. The simple part was finding the data directory, the wiki isn't exactly correct: on our install, at least, the data directory is in /var/lib/mailman. Since it seems to be constructed from VAR_PREFIX I'd guess that on most setups it'd be in a different place than ~mailman.
What I'm running into now is that the command-line pgm has to be run as user 'mailman' and I can't do that [at least not very easily]. I tried setting discard to be setgid, but that seems not to work, so I guess this is a followon question: is there a way to make python scripts run setuid/setgid? [basically, my situation is that I can only get to the mail server logged in as me, NOT logged in as mailman] -- I suppose I could always write a setgid Perl one-liner to run the Python discard..:o)
/Bernie\
-- Bernie Cosell Fantasy Farm Fibers mailto:bernie@fantasyfarm.com Pearisburg, VA --> Too many people, too few sheep <--
Bernie Cosell wrote:
On 12 May 2009 at 17:58, Mark Sapiro wrote:
On Tue, May 12, 2009 at 08:27:45AM -0400, Bernie Cosell wrote:
Is there a command-line way to "discard all messags marked defer"?
Actually a FAQ more specific to this question is <http://wiki.list.org/x/nIA9>.
I've been pushing on this some, to no avail at the moment. The simple part was finding the data directory, the wiki isn't exactly correct: on our install, at least, the data directory is in /var/lib/mailman. Since it seems to be constructed from VAR_PREFIX I'd guess that on most setups it'd be in a different place than ~mailman.
I added a note to the FAQ about this.
What I'm running into now is that the command-line pgm has to be run as user 'mailman' and I can't do that [at least not very easily]. I tried setting discard to be setgid, but that seems not to work,
SETGID only works for binary executables. It doesn't work for scripts of any kind.
Can you add yourself to the 'mailman' group? That should be sufficient.
so I guess this is a followon question: is there a way to make python scripts run setuid/setgid? [basically, my situation is that I can only get to the mail server logged in as me, NOT logged in as mailman] -- I suppose I could always write a setgid Perl one-liner to run the Python discard..:o)
It won't work with Perl either. It has to be a binary executable. Thats the reason for all the compiled SETGID wrappers in mailman's cgi-bin/ and mail/ directories.
It seems you are able to get some kind of privileges on the mail server if you are able to make mailman files SETGID. Can you run sudo? Can you run newgrp to set your logged in group to 'mailman'?
The attached members.c.txt file is the source of a wrapper I use (the executable is SETGID mailman) to allow apache (php scripts) to execute certain mailman commands. If all else fails, you could strip the command check logic or add discard to the array of allowed commands and use it.
-- Mark Sapiro <mark@msapiro.net> The highway is for gamblers, San Francisco Bay Area, California better use your sense - B. Dylan
on 5/16/09 9:57 AM, Bernie Cosell said:
I've been pushing on this some, to no avail at the moment. The simple part was finding the data directory, the wiki isn't exactly correct: on our install, at least, the data directory is in /var/lib/mailman.
Then you're using a version of Mailman that was provided as part of a binary package from some other source, and not our canonical source-only distribution of Mailman.
That's not necessarily a problem, but you do need to keep in mind that all our documentation and FAQs are written to the only standard we have, which is the original source code that we provide. We can't control what anyone else does with whatever they provide, nor can we write their documentation for them.
-- Brad Knowles <brad@shub-internet.org> If you like Jazz/R&B guitar, check out LinkedIn Profile: my friend bigsbytracks on YouTube at <http://tinyurl.com/y8kpxu> http://preview.tinyurl.com/bigsbytracks
participants (4)
-
Adam McGreggor
-
Bernie Cosell
-
Brad Knowles
-
Mark Sapiro