Carapace

Virus Checking

Because the CAT receives job applications by email it is important to ensure that these emails do not introduce viruses into your organisation. The CAT can integrate with your system's virus checking software so that each job application can be checked for viruses. Any application which is found to contain a virus is removed before it can be accessed by any user of the CAT.

Virus Checker Integration

The Carapace script file catvcheck.cpl defines the class CatVirusChecker. Once virus checking is enabled, each received application is passed through the virusCheck method. Provide this method reports ok the application is allowed to proceed. Any other value returned indicates a virus is detected and the application is stopped.

The empty CatVirusChecker class supplied with the CAT is as follows:


    (class CatVirusChecker

        (interface

            (properties

                # determines if virus checking is enabled
                #
                # Values: enabled
                #         disabled
                #
                (status String)

                # NOTE: put any other private virus checker properties here


            )

            (methods

                (NIL CatVirusChecker ())

                # check the supplied mail attachment for viruses
                #
                # return "ok" if there are no detected viruses
                # any other return value indicates a virus is detected
                #
                (String virusCheck ( (messageId String)
                                     (sender String)
                                     (data Binary) 
                                     (mediaType String) 
                                     (mediaSubType String) 
                                   )
                )


                # NOTE: put any other private virus checker methods here
            )
        )
    )

    (defun NIL CatVirusChecker::CatVirusChecker ()

        # NOTE: change this to "enabled" for virus checking to be performed
        
        (this.status "disabled")
    )

    (defun String CatVirusChecker::virusCheck ( (messageId String)
                                                (sender String) 
                                                (data Binary) 
                                                (mediaType String) 
                                                (mediaSubType String) 
                                              )

        (local  (result String)
        )

        (set result "ok")

        # NOTE: integrate the virus checker here 
        #
        #       return "ok" to indicate no viruses found
        #       return any other string to indicate the presence of a virus
        #  
        
        (return result)
    )

This class provides the link between the virus checker on your server and the receipt of emails by the CAT. The following method and properties are required on the primary interface:

name type description
status property a String which defines whether virus checking is enabled or disabled
virusCheck method checks the received mail attachment for viruses using the system's virus checking software

Enabling Virus Checking

To enable virus checking, edit the script catvcheck.cpl in the Carapace scripts directory and ensure the status property is set to enabled

Checking for a Virus

Ensure the virus checking is enabled.

Edit the script catvcheck.cpl in the Carapace scripts directory and use the virusCheck method to check the received mail attachment using the system's virus checking software.

The parameters to this method are as follows:

name type description
messageId String the message identifier as supplied by the message transfer system
sender String the address of the sender of the email
data Binary the data of the mail attachment
mediaType String the coarse type of the data within the attachment -- e.g. text
mediaSubType String the fine type of the data within the attachment -- e.g. plain

The pair of parameters mediaType and mediaSubType define the type of data received. Common values are:

mediaType mediaSubType description
textplainplain text attachment
texthtmlan HTML attachment
applicationmsworda Microsoft Word document
imagegifa GIF image attachment


Contents Index Current topic: Carapace Application Tracker Related topics: Carapace Hub