[pmwiki-users] what is the best way to clear out spammer droppings??

Patrick R. Michaud pmichaud at pobox.com
Thu Aug 11 14:37:53 CDT 2005


On Thu, Aug 11, 2005 at 02:08:48PM -0400, Neil Herber wrote:
> Now that the blocklist is working again and our recent spammer has been 
> slowed down (stopped??), what is (are)  the best way(s) to remove their 
> droppings?
> ...
> Are there any other shortcuts for getting rid of bags of spam?

In this case, since I have Unix Crunchy Goodness(TM) at my disposal :-),
I did the following:

    $ rm $(grep -l "^text=.*joy\.by" Main.*)

This simply removed all of the pages in Main that had "joy.by" in the
text somewhere.  Since there aren't any pages in Main on pmwiki.org
that I feel strongly about keeping, this works out okay.

But it obviously would've posed some difficulties if the spammed
pages had some text I wanted to keep.  In that instance I could've
done something like:

    $ for f in $(grep -l "^text=.*joy\.by" *);
    > do
    >   echo "http://www.pmwiki.org/wiki?n=$f&action=diff"
    > done

which gives me a nice listing of the ?action=diff urls.  Since 
clicking such urls in my terminal program automatically opens a
browser window to the page, I can just click down the list,
opening pages as I go and fixing them.

But not everyone has a Unix shell at their disposal, so the
answer is probably to build something into the (:pagelist:)
function for this.  One simple thing to do might be to add
an "action=" parameter which specifies an action to be added
to each page url displayed.  For example,

    (:pagelist "joy.by" action=diff:)

would generate a list of pages containing "joy.by", and each of
the page urls would have ?action=diff appended to the end.
Then one could open the pages from that display and fix them
as appropriate.

Much more than that would require developing the specialized
mass-page-handling facility that I've been thinking about for
the pagelist function but haven't had time to develop yet
(or need for it--see PmWikiPhilosophy #3).

Thoughts...?

Pm




More information about the pmwiki-users mailing list