pic
  ClamWin Free Antivirus    
   
ClamWin Wiki
Home
Article
Discussion
Edit
History
Create an account or log in
Main Page
Community portal
Current events
Recent changes
Random page
Help
Donations
What links here
Related changes
Upload file
Special pages
Printable version


Sourceforge Logo
 
 
Thunderbird Extension

From ClamWin

Contents

ClamWin Thunderbird Extension

Features implemented

  • When a mail is opened in the preview-list, the message is exported to a temporary file.
  • load the clam databases using an xpcom-component linked to libclamav
  • scan the files in the temporary folder (using libclamav)
  • move an infected file to quarantine
  • remove files from the temporary folder
  • read configuration settings from the clamwin.conf file

Features on the todo-list for release 0.1

  • Beside the export of the whole message, which will be enough to trap some phishing stuff, we also need to save the attachments to files
  • block the email attachments from being shown in preview while scanning -- show a "scanning" status message instead
  • create a build procedure
  • create an extension installer (.xpi)

features on the list for future releases

  • separate clamwin-specific code into a generic dll that can be used by other software (and plugins/addins/extensions)
  • cleanup the code
  • write a short manual
  • generate a report-file if an infected file is found
  • attach the report-file to the email
  • detach the infected file to quarantine
  • if an error occurs during scanning, show a message to the user and allow him to open the email at his own risk
  • create a settings window that allows to alter configuration
  • create a version of the xpcom file allowing the use of version 1.0 through a pipe
  • do some rework for more portability
  • test on the newer versions of thunderbird
  • handle IMAP messages

Setting up the DevEnv

Here's some notes of what i remember doing (might be incomplete though). Feel free to change them according to your experiences :

  • Install Visual C++ 2005 Express Edition (available from here)
  • I linked with the Platform SDK included with Microsoft Visual Studio .NET 2003. It should also work with the free copy of the Microsoft Platform SDK, available from here.
  • Install the Gecko-SDK (available from here). Gecko is the base package on which Mozilla Firefox and Thunderbird are build.
  • Download and install a package of the precompiled clamav binaries for Win32 from Sherpya's pages.
  • And off course you need a copy of Thunderbird. I'm testing with 1.5.0, which i also built myself, but i don't think this is necessary. See below for creating a separate test profile.
  • What i also installed is a copy of the Moztools package (available from here). I don't think you need this though.

Setting up the test env

  • Before you test the extension, it is best to set up a separate test profile in Thunderbird, so you don't screw your regular profile. Info about this is here.
  • Also perform the instructions on this page. It will help you with testing.
  • Locate the profile directory for your test profile and select the extensions subdirectory (Something like C:\Documents and Settings\budtse\Application Data\Thunderbird\Profiles\xxxxxxx.devel\extensions). Here you add a new textfile called "tbclamwin@clamwin.com". In the textfile, put the path to the javascript extension directory (e.g. "D:\PROJECTS\CLAMWIN\tbclamwin"). This will add the extension to the Thunderbird extensions for the setup profile.
  • Now you should be able to open the solution file ("tbclamwin\src\nsClamWinService.sln"). You might need to change the settings for additional include files and library files. After that try to build. Also set the path for the debugging to the directory where thunderbird.exe can be found. Now when you press F5, Thunderbird should start (first do close down any other Thunderbird instances) and the extension should be loaded.
 

 
pic
                              
pic
pic
   
© 2004-2006 ClamWin Free Antivirus
This page has been accessed 1,975 times.
This page was last modified 18:41, 5 August 2007.
      
pic