Opened 17 years ago

Closed 17 years ago

#735 closed defect (fixed)

PermissionDeniedException on array design list view

Reported by: base Owned by: Nicklas Nordborg
Priority: critical Milestone: BASE 2.4.2
Component: core Version:
Keywords: Cc:

Description

As a normal user, another blank list view with the following in catalina.out:

15:10:36,853 ERROR [jsp]:253 - Servlet.service() for servlet jsp threw exception
net.sf.basedb.core.PermissionDeniedException: Permission denied: Not allowed to read File[id=281; name=Plasmodium_Anopheles.cdf]
        at net.sf.basedb.core.BasicItem.checkPermission(BasicItem.java:110)
        at net.sf.basedb.core.DbControl.getItem(DbControl.java:807)
        at net.sf.basedb.core.DbControl.loadItem(DbControl.java:692)
        at net.sf.basedb.core.File.getById(File.java:116)
        at sun.reflect.GeneratedMethodAccessor614.invoke(Unknown Source)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
        at java.lang.reflect.Method.invoke(Method.java:597)
        at net.sf.basedb.core.Item.getById(Item.java:661)
        at net.sf.basedb.core.AnyToAny.getTo(AnyToAny.java:533)
        at net.sf.basedb.core.Affymetrix.getCdfFile(Affymetrix.java:134)
        at net.sf.basedb.core.ArrayDesign.getNumFeatures(ArrayDesign.java:544)
        at org.apache.jsp.lims.arraydesigns.list_005fdesigns_jsp._jspService(list_005fdesigns_jsp.java:1085)
        at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:97)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
        at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:334)
        at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:314)

BASE 2.4.0, jdk 1.6.0

I will now go and see if I can fix the permissions on that .cdf file, but you'll want to fix this anyway.

thanks! Bob.

Change History (5)

comment:1 by base, 17 years ago

yes that fixed it (sharing the cdf file to Everyone).

comment:2 by Nicklas Nordborg, 17 years ago

Milestone: BASE 2.4.2
Priority: majorcritical

I think we need a try-catch around the problematic part in ArrayDesign.getNumFeatures. We should return -1 or something if the user doesn't have access to the file.

Note! See also ticket #758 which solves this problem in another way. But not until 2.5 so I think we need the try-catch approach in 2.4.2

comment:3 by Nicklas Nordborg, 17 years ago

Owner: changed from everyone to Nicklas Nordborg
Status: newassigned

comment:4 by Nicklas Nordborg, 17 years ago

Component: webcore

comment:5 by Nicklas Nordborg, 17 years ago

Resolution: fixed
Status: assignedclosed

(In [3742]) Fixes #735: PermissionDeniedException on array design list view

Note: See TracTickets for help on using tickets.