Details
-
Bug
-
Status: Closed
-
Resolution: Fixed
-
6.2.10 EE GA1, 7.0.0 M3
Description
https://issues.liferay.com/browse/LPS-45614 fixed this for DM.
Steps to reproduce:
1. Apply the
dl.store.antivirus.enabled=true
in the portal-ext.properties and start the portal.
2. Deploy the fake-antivirus-scanner-hook-7.0.0.1.war (it acts a virus scanner, but does nothing special, simply throws AntivirusScannerException for each uploaded file. See: https://github.com/lipusz/liferay-plugins/commits/LPS-45614-test-hook-master)
3. Try to upload any file as logo in
- My Account (User's portrait on the details tab)
- Organization Logo (Edit organization view/Details tab)
- Site logo (Admin/Site configuration/Logo)
- Company logo (Control Panel/Portal Settings/Display settings)
Result:
12:39:09,083 ERROR [http-bio-8080-exec-9][render_portlet_jsp:132] null
com.liferay.portlet.documentlibrary.antivirus.AntivirusScannerException
at com.liferay.test.antivirus.FakeAntivirusScanner.scan(FakeAntivirusScanner.java:19)
at com.liferay.portal.kernel.bean.ClassLoaderBeanHandler.invoke(ClassLoaderBeanHandler.java:67)
at com.liferay.portlet.documentlibrary.antivirus.AntivirusScannerWrapper.scan(AntivirusScannerWrapper.java:42)
at com.liferay.portlet.documentlibrary.antivirus.AntivirusScannerUtil.scan(AntivirusScannerUtil.java:53)
at com.liferay.portlet.documentlibrary.store.DLStoreImpl.addFile(DLStoreImpl.java:96)
at com.liferay.portlet.documentlibrary.store.DLStoreUtil.addFile(DLStoreUtil.java:120)
at com.liferay.portlet.documentlibrary.service.impl.DLFileEntryLocalServiceImpl.addFileEntry(DLFileEntryLocalServiceImpl.java:253)
at com.liferay.portal.spring.aop.ServiceBeanMethodInvocation.proceed(ServiceBeanMethodInvocation.java:115)
at com.liferay.portal.spring.transaction.DefaultTransactionExecutor.execute(DefaultTransactionExecutor.java:53)
at com.liferay.portal.spring.transaction.TransactionInterceptor.invoke(TransactionInterceptor.java:55)
at com.liferay.portal.spring.aop.ServiceBeanMethodInvocation.proceed(ServiceBeanMethodInvocation.java:111)
at com.liferay.portal.spring.aop.ChainableMethodAdvice.invoke(ChainableMethodAdvice.java:56)
at com.liferay.portal.spring.aop.ServiceBeanMethodInvocation.proceed(ServiceBeanMethodInvocation.java:111)
at com.liferay.portal.spring.aop.ChainableMethodAdvice.invoke(ChainableMethodAdvice.java:56)
at com.liferay.portal.spring.aop.ServiceBeanMethodInvocation.proceed(ServiceBeanMethodInvocation.java:111)
at com.liferay.portal.spring.aop.ChainableMethodAdvice.invoke(ChainableMethodAdvice.java:56)
at com.liferay.portal.spring.aop.ServiceBeanMethodInvocation.proceed(ServiceBeanMethodInvocation.java:111)
at com.liferay.portal.spring.aop.ChainableMethodAdvice.invoke(ChainableMethodAdvice.java:56)
at com.liferay.portal.spring.aop.ServiceBeanMethodInvocation.proceed(ServiceBeanMethodInvocation.java:111)
at com.liferay.portal.spring.aop.ChainableMethodAdvice.invoke(ChainableMethodAdvice.java:56)
And you cannot save the logo.
It may seem unreal to throw ASE for each uploaded file, though, it's just for reproduction purposes. These portlets also should handle this exception.
Attachments
Issue Links
- Discovered while testing
-
LPS-45614 AntivirusScannerException is not handled very well in components using document library
- Closed