spamcup - frontend program for App-SpamcupNG project


In your favorite shell:

    $ spamcup

That's it! See the configuration file details.

You can also provide all the parameters in the command line. Check the command line documentation:

Usage: spamcup [options] <Spamcop-Username>

   $ spamcup -h
   spamcup <options> <Spamcop-Username>

    -n Does nothing, just shows if you have unreported SPAM or not.
    -a Run in a loop untill all SPAM is reported.
    -s Stupid. Runs without asking confirmation. Use with care.
    -c Alternate method for signifying code. (Unpaid users WITHOUT username & password)
    -l Alternate method for providing username. (Paid & unpaid users with password)
    -p Method for providing password. (Required for users with password)
    -v Show version and quit.
    -V <LEVEL> Verbosity level of information during program execution. Or log level. Valid values are: DEBUG, INFO, WARN, ERROR, FATAL.
    -h You are reading it.


App-SpamcupNG is a Perl web crawler for finishing reports automatically.

It will use your account details to login into web page and finish reporting your SPAM. App-SpamcupNG tries to be as polite as possible, introducing forced delays to not overwhelm website. All reports are sent sequentially.

App-SpamcupNG is a fork from the original Spamcup project.

Spamcup is copyright (C) Toni Willberg.


App-SpamcupNG provides the following features:

  • Can use both command line parameters and/or a configuration file. The configuration file allows you to define and use multiple accounts of Spamcop (but you can't send reports from them in parallel and never will since we want to be as polite as possible with Spamcop website).

  • Advanced logging capabilities (provided by usage of Log::Log4perl): you can setup additional levels of information on screen or even have everything logged into a text file (if DEBUG is enabled). See App::SpamcupNG for details about that.

  • Compatibility with the original Spamcup project: you can reuse your configuration file and/or command line options with minor adjustments.

  • Can optionally store the SPAM reports details to an local SQLite3 database for further queries, if desirable.


The motivations for this distribution might be inquired while comparing it to WWW::Mechanize::SpamCop. Here is the rationale:

Compatible with Spamcup

App-SpamcupNG is a directly replacement for Spamcup original project. I used myself Spamcup for years and never had an issue, since the webpage didn't change that much. The reasons for writing a replacement was to be able to use multiple accounts in the configuration file.

That said, you can use the same configuration file you have for Spamcup, with small changes.

App-SpamcupNG is ready for using

App-SpamcupNG is an application ready to use, while WWW::Mechanize::SpamCop is a Perl module. Of course, you probably can make the same command line program by using it, or even a GUI for it. Maybe in the future App-SpamcupNG uses WWW::Mechanize::SpamCop internally.

More features

Being a application, App-SpamcupNG has more features (see previous section).

Uses modern Perl coding practices

App-SpamcupNG uses more modern practices for Perl development, which might (or not!) make it more robust. Also, this distribution is being activaly developed.

WWW::Mechanize is not required

WWW::Mechanize (the base of WWW::Mechanize::SpamCop) is pretty neaty, easier to use than LWP::UserAgent, but on the other hand has more dependencies and wouldn't add any value compared to the already in place webcrawler implementation. If the website changes, I might consider moving to it, but not before that.


Some important warnings before starting using it:

  • The script does NOT know where the SPAM report will be sent so IT'S YOUR RESPONSIBILITY!

  • If the script asks Spamcop to send reports to wrong places IT'S YOUR FAULT!

  • If the script has a bug that causes same report being sent thousand times IT'S YOUR MAIL ADDRESSES!



You can also provide a configuration file to avoid having to provide the same information every time you want to execute the program.

Another advantage of using the configuration file is that you can setup multiple in the same file and the spamcup program will loop over them and report the associated SPAM automatically.

The program will look for a configuration file named .spamcup.yml in the corresponding home directory of the user (that will dependend on the OS you're executing it).

The configuration file must be written as an YAML file, with the exact properties below:

    all: y
    stupid: y
    nothing: n
    alt_code: n
    verbosity: INFO
    alt_user: n
      enabled: true
      path: /var/spamcupng/reports.db
        password: FOOBAR
        password: FOOBAR

You can use any name instead of "Provider1" or "Provider2" as long as their are valid key names for YAML format.

All those options have their corresponding command line parameter. Be sure to take care of file permissions to avoid disclosure of your password!


spamcup uses Log::Log4perl, so you can use the default values for logging.

If you use INFO, only basic information is printed to STDOUT. This should be your default level.

If you define DEBUG, all messages (including HTML from website) will go to the spamcup.log file, located at your home directory. Nothing will be printed to STDOUT or STDERR.

All other levels will show more or less messages to STDOUT, depending on the severity of the messages.



Alceu Rodrigues de Freitas Junior, <>


This software is copyright (c) 2015 of Alceu Rodrigues de Freitas Junior, <>

This file is part of App-SpamcupNG distribution.

App-SpamcupNG is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.

App-SpamcupNG is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

You should have received a copy of the GNU General Public License along with spamcupNG. If not, see <>.