Eudora to SpamCop v 1.2. Fixes submission format

This is an AppleScript for quickly reporting spam to SpamCop from within Eudora. This version fixes the format of submissions to SpamCop to comply with SpamCop’s new, more strict header parsing routines.

FEATURES:

  1. Quickly and automatically queues a properly formatted spam report to your outbox
  2. Submission of multiple selected messages at one invocation.
  3. If message has been left on server, script can be configured to set that message to be deleted.
  4. Attachments to the spam are deleted automatically, with or without notification, according to user preferences.
  5. Script can mark the spam as read, and can optionally trash it or move it to the Junk folder.

Download & Enjoy!

Unfortunately, there aren’t adequate verbs in Eudora’s AppleScript dictionary for a robust implementation of the Junk mail feature. Moving an e-mail to the Junk folder does assign a score of 100 to it (though it takes a while to see that), but I’m not sure if it properly updates the Bayesian filters the way the Junk command does. Consider it a workaround implementation until we either get native verbs for it, or until keystroke programming becomes standard in Mac OS X.

* This script is intended for Mac OS X v 10.2.x and up, and Eudora 6.x, but might also work with Eudora 5.2, though obviously without the Junk mail functionality.











If you find you are happy with this script or technique and would like to make a small donation, you can do so very easily simply by clicking on the PayPal icon and following the next two screens. Thank you!

Eudora to SpamCop version 1.2 Read Me

Installation | Configuration | Known Issues | License | Donations | History

Installation:

(If, by some reason, you’ve downloaded this script, but don’t know anything about SpamCop, please go to SpamCop.net to sign up and learn more first.)

  1. Make sure the script menu in Eudora is enabled
    1. First, quit Eudora, if it’s running.
    2. Now, in your home directory, go to Documents:Eudora Folder:Eudora Items. Create a directory there called Scripts. (If you already have this directory, your Scripts menu is already enabled.) In OS 9 the Eudora Items folder is easy to find in the Eudora Application Folder – and a Scripts folder may already be there.
  2. Copy the Report to SpamCop script into your Documents:Eudora Folder:Eudora Items:Scripts folder. When you restart Eudora the Scripts menu will appear between the Window and Help menus. Many Eudora users like to add their most frequently used scripts to the toolbar buttons. This enables you to even assign a function key to the script. Please see the Eudora documentation for how to do this.

Configuration:

  1. Set up the necessary reporting nicknames in Eudora
    1. Open your address book (Cmd+L) and add the following nicknames:
      Nickname Address
      SpamCopReport submit.[SpamCop user password]@spam.spamcop.net*
      SpamReporter the e-mail address you want to use for the From: field of your SpamCop submissions

      * Your SpamCop submission address will usually look something like this submit.W85cO3r6U8kHBLcu@spam.spamcop.net. If you don’t know what your submission address is, you can’t submit spam reports to SpamCop via e-mail. To find your submission address is, submit a spam report to SpamCop via the Web interface. After you’ve submitted your report, you should see a page with the line “Forward your spam to: …” The e-mail address at the end of this line is your SpamCop submission address.

      (These nicknames are just suggestions. You can make your own, but you’ll have to make the appropriate changes in the AppleScript)

  2. The script includes further configuration options. If you would like to edit them, open the Report to SpamCop script in Script Editor, and change the variables to the instructions contained in the script itself. Briefly, your options are:
    Property Type Description Default
    reportingNickname String Eudora nickname for SpamCop submission address SpamCopReport
    fromNickname String Eudora nickname for the from address on your SpamCop reports SpamReporter
    markRead boolean If you want to mark reported messages as already read, set this to true. true
    deleteSpamAttachments boolean If you want to delete spam attachments automatically, set this to true. true
    deleteAlert boolean If you want to be alerted when spam attachments are about to be deleted, set this to true. false
    deleteFromServer boolean If you keep mail on the server and want spam messages to be set to be deleted from server, set this to true. true
    doCleanup enum What do you want the script to do after it has reported the message? Your options are ‘Trash’ or ‘Junk’ or “None” it? Junk

Known Issues:

  1. The main one is that selected messages in mailboxes are deselected when the script has run. I have appealed to some of the finest minds in AppleScript, and there appears to be no workaround for this limitation in Eudora. It’s bad User Interface Design to leave something deselected after processing because the user is left with no visual reminder of which messages were submitted. Plus, if the user wishes to do more with those messages, he or she has to select them all over again.
  2. Eudora 6 does not appear to have any AppleScript verbs for dealing with Junk mail. I have written to Qualcomm asking for this functionality. Who knows if it will ever appear. It is possible for the script to move messages to the Junk folder, and when that’s done, they do appear to get a spam score of 100. It’s just hard to tell if that is doing all the things that executing the “Junk” command does. Mac OS X will soon have native support for keystroke programming in AppleScript (already out in beta form). Once this is standard, I’ll probably write a way to engage the Command+J key on messages that need to be Junked.
  3. Speaking of spam scores. There’s a visual “bugaboo” in Eudora where after you submit some messages via the script from the Junk mail box, it appears as though their spam scores have been erased. If, however, you switch to another mailbox, and then look back at the Junk mailbox, you’ll see that they actually have been assigned a score of 100. Eudora is also slow, sometimes, to update spam scores to 100 on messages that have recently been transferred to Junk.

License:

This script is licensed under a GNU Public License (GPL). This means you can copy it, change it, share it, freely, but you cannot derive economic gain from it, or any product in which you incorporate it, or claim ownership of it yourself. I have put it under a GPL license to make sure this kind of stuff doesn’t get claimed and owned by some corporation somewhere. THERE IS NO WARRANTY EITHER EXPRESSLY OR IMPLIED: USE AT YOUR OWN RISK.

Donations:

If you find this script helpful, and would like to make a small donation, you can do so very easily simply by Donate via Paypal and following the next two screens. Thank you!

Copyright 2003-4, Kristofer Widholm, The Apotek. See http://theapotek.com for more info on this and other projects I’m working on.

History:

This script originated with a hint at SpamCop about a script by “Philipp,” which took a selected message and queued it for delivery to SpamCop. I have expanded on that beginning, by adding features such as being able to delete spam left on server, delete attachments, etc. There is obviously much room for improvement (such as not deselecting mail after processing). If you have suggestions, or want to change the code in any way, please do so and share the results with me, so I can keep the script at scriptbuilders.net up to date. Special thanks to John Delacour, Rob Jorgensen, and Christopher Stone, without whom I would probably still be scratching my head and thinking I should probably get a bite to eat… soooon… I would also like to thank B. Jefferson Le Blanc for helping me improve the clarity of this ReadMe file.

v 1.2: Due to SpamCop’s more strict message parsing rules, I had to fix the format of messages submitted. The junky ???@??? line that Eudora inserts automatically is gone, and I seem to have fixed the problem with long lines in the headers being incorrectly formatted. I fixed that by turning off “wrap” for SpamCop-bound messages.

v 1.1: Ability to process multiple messages at once. Also added automatic Trashing option. Junking not yet possible.

v 1.0.1: Disabled faulty junk mail implementation