Uploaded image for project: 'Struts 1'
  1. Struts 1
  2. STR-3198

Struts 1.3.10/11 File Upload Blocker with indexed property set True.

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Open
    • Blocker
    • Resolution: Unresolved
    • 1.3.10
    • None
    • Core
    • JDK 1.6; Struts core 1.3.11; Weblogic 10.3; oracle 9i
    • Important

    Description

      Our project is to migrate from JDK 1.4 to JDK 1.6 and also we migrated from struts 1.2 to 1.3.

      While migrating we found file upload code blocking our application. This is happening when we use "indexed" property set to true in htm:file tag. But, we need to use index property in order to upload file for some particular sequences.

      PFB sample code:
      <htm:file name="MyForm" property="file" indexed="true" />

      Steps to replicate:
      1. Have page having a file upload code as shown above. Let us page1.do.
      2. Go to Page1.do.
      3. Don't do anything just try to navigate some new page say page2.do. Now system will show the below error on screen:

      Error 500--Internal Server Error
      java.lang.NoSuchMethodException: Unknown property 'MyForm' on bean class 'class org.apache.struts.validator.DynaValidatorForm'
      at org.apache.commons.beanutils.PropertyUtilsBean.getIndexedProperty(PropertyUtilsBean.java:460)
      at org.apache.commons.beanutils.PropertyUtilsBean.getIndexedProperty(PropertyUtilsBean.java:408)
      at org.apache.commons.beanutils.PropertyUtilsBean.getNestedProperty(PropertyUtilsBean.java:760)
      at org.apache.commons.beanutils.PropertyUtilsBean.getProperty(PropertyUtilsBean.java:837)
      at org.apache.commons.beanutils.PropertyUtilsBean.getPropertyType(PropertyUtilsBean.java:1173)
      at org.apache.commons.beanutils.PropertyUtils.getPropertyType(PropertyUtils.java:564)
      at org.apache.struts.util.RequestUtils.rationalizeMultipleFileProperty(RequestUtils.java:504)
      at org.apache.struts.util.RequestUtils.populate(RequestUtils.java:459)
      at org.apache.struts.action.RequestProcessor.processPopulate(RequestProcessor.java:823)
      at org.apache.struts.action.RequestProcessor.process(RequestProcessor.java:194)
      at org.apache.struts.action.ActionServlet.process(ActionServlet.java:1913)
      at org.apache.struts.action.ActionServlet.doPost(ActionServlet.java:462)
      at javax.servlet.http.HttpServlet.service(HttpServlet.java:727)
      at javax.servlet.http.HttpServlet.service(HttpServlet.java:820)
      at weblogic.servlet.internal.StubSecurityHelper$ServletServiceAction.run(StubSecurityHelper.java:227)
      at weblogic.servlet.internal.StubSecurityHelper.invokeServlet(StubSecurityHelper.java:125)
      at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:292)
      at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:175)
      at weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.run(WebAppServletContext.java:3590)
      at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:321)
      at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:121)
      at weblogic.servlet.internal.WebAppServletContext.securedExecute(WebAppServletContext.java:2200)
      at weblogic.servlet.internal.WebAppServletContext.execute(WebAppServletContext.java:2106)
      at weblogic.servlet.internal.ServletRequestImpl.run(ServletRequestImpl.java:1428)
      at weblogic.work.ExecuteThread.execute(ExecuteThread.java:201)
      at weblogic.work.ExecuteThread.run(ExecuteThread.java:173)

      Could you please resolve this as soon as possible. Because we need it within 3days else we will be put into serious trouble.

      FYI: We found the same issue in unreleased version of struts 1.3.11 too. But to resolve BUG ID: STR-3173 we are right now using struts 1.3.11

      Thanks,
      Rajesh

      Attachments

        Activity

          People

            Unassigned Unassigned
            rajesh734 Rajesh A
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated: