Uploaded image for project: 'PUBLIC - Liferay Portal Community Edition'
  1. PUBLIC - Liferay Portal Community Edition
  2. LPS-52156

Wrong AntivirusScannerException is thrown from ClamAntivirusScannerImpl, when virus is detected

    Details

      Description

      1. install clamAv virus scanner:
      Windows:

      (make sure clamscan working fine by checking in terminal: )

      clamscan --stdout --no-summary [path to test file]

      (You should see output message like clam-output.png)

      2. Put these properties into portal-ext.properties file:

      dl.store.antivirus.enabled=true 
      dl.store.antivirus.impl=com.liferay.portlet.documentlibrary.antivirus.ClamAntivirusScannerImpl
      

      3. Start liferay

      4. Log in as Test Test user and go to admin >content > documents and media

      5. upload an anti virus test file to Documents and Media, I used eicar.com.txt downloaded from http://www.eicar.org/85-0-Download.html

      Expected result: a message on Documents and Media portlet, saying "A virus was detected in the file."

      Actual result: "Unable to scan file for viruses." (picture)

      reproduced on master

        Attachments

        1. clam-output.png
          clam-output.png
          70 kB
        2. unable.png
          unable.png
          17 kB
        3. virus_result.png
          virus_result.png
          110 kB

          Issue Links

            Activity

              People

              Assignee:
              yvonne.han Yvonne Han
              Reporter:
              zsolt.olah Zsolt Oláh (Inactive)
              Participants of an Issue:
              Recent user:
              Esther Sanz
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved:
                Days since last comment:
                7 years, 24 weeks, 5 days ago

                  Packages

                  Version Package
                  6.2.3 CE GA4
                  6.2.X EE
                  7.0.0 M4