Uploaded image for project: 'OpenMRS Core'
  1. OpenMRS Core
  2. TRUNK-837

FormEntry privilege is required immediately after login

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Should
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: None

      Description

      I think we have many issues with User privileges, but this one seems very problematic at the moment. If a new User is created (with anything other than System Developer role), we get a ServletException. Not only should that not happen to begin with, but also, failures that are caused by lack of privileges should probably be more graceful and say something simple like "User does not have permissions. Contact administrator if user should have access to this resource." or something like that.

      The following is the stack trace from the email on Implementers list:

      An Internal Error has Occured
      javax.servlet.ServletException
      javax.servlet.jsp.JspException: Privilege required: Form Entry

      Consult the help document.
      Contact your friendly neighborhood administrator if it cannot be resolved.

      Show stack trace

        • Root cause is: Privilege required: Form Entry org.openmrs.api.APIAuthenticationException: Privilege required: Form Entry at org.openmrs.formentry.impl.FormEntryServiceImpl.getForms(FormEntryServiceImpl.java:331) at org.openmrs.formentry.impl.FormEntryServiceImpl.getForms(FormEntryServiceImpl.java:326) at sun.reflect.GeneratedMethodAccessor67.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) at java.lang.reflect.Method.invoke(Unknown Source) at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:292) at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:155) at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:122) at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:96) at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:144) at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:174) at $Proxy34.getForms(Unknown Source) at sun.reflect.GeneratedMethodAccessor67.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) at java.lang.reflect.Method.invoke(Unknown Source) at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:292) at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:155) at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:122) at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:96) at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:144) at org.springframework.aop.framework.adapter.MethodBeforeAdviceInterceptor.invoke(MethodBeforeAdviceInterceptor.java:53) at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:144) at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:174) at $Proxy35.getForms(Unknown Source) at org.openmrs.web.controller.PatientSetPortletController.populateModel(PatientSetPortletController.java:59) at org.openmrs.web.controller.PortletController.handleRequest(PortletController.java:261) at org.springframework.web.servlet.mvc.SimpleControllerHandlerAdapter.handle(SimpleControllerHandlerAdapter.java:44) at org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:684) at org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:625) at org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:392) at org.springframework.web.servlet.FrameworkServlet.doGet(FrameworkServlet.java:347) at javax.servlet.http.HttpServlet.service(HttpServlet.java:689) at javax.servlet.http.HttpServlet.service(HttpServlet.java:802) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:270) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:191) at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:672) at org.apache.catalina.core.ApplicationDispatcher.doInclude(ApplicationDispatcher.java:574) at org.apache.catalina.core.ApplicationDispatcher.include(ApplicationDispatcher.java:499) at org.apache.taglibs.standard.tag.common.core.ImportSupport.acquireString(Unknown Source) at org.apache.taglibs.standard.tag.common.core.ImportSupport.doEndTag(Unknown Source) at org.openmrs.web.taglib.PortletTag.doEndTag(PortletTag.java:70) at org.apache.jsp.WEB_002dINF.view.index_jsp._jspx_meth_openmrs_005fportlet_005f0(index_jsp.java:1316) at org.apache.jsp.WEB_002dINF.view.index_jsp._jspx_meth_c_005fif_005f3(index_jsp.java:1280) at org.apache.jsp.WEB_002dINF.view.index_jsp._jspService(index_jsp.java:417) 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:389) at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:319) at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:265) at javax.servlet.http.HttpServlet.service(HttpServlet.java:802) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:270) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:191) at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:672) at org.apache.catalina.core.ApplicationDispatcher.processRequest(ApplicationDispatcher.java:463) at org.apache.catalina.core.ApplicationDispatcher.doForward(ApplicationDispatcher.java:398) at org.apache.catalina.core.ApplicationDispatcher.forward(ApplicationDispatcher.java:301) at org.springframework.web.servlet.view.InternalResourceView.renderMergedOutputModel(InternalResourceView.java:97) at org.springframework.web.servlet.view.AbstractView.render(AbstractView.java:250) at org.springframework.web.servlet.DispatcherServlet.render(DispatcherServlet.java:928) at org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:705) at org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:625) at org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:392) at org.springframework.web.servlet.FrameworkServlet.doGet(FrameworkServlet.java:347) at javax.servlet.http.HttpServlet.service(HttpServlet.java:689) at javax.servlet.http.HttpServlet.service(HttpServlet.java:802) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:270) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:191) at org.openmrs.web.OpenmrsFilter.doFilter(OpenmrsFilter.java:70) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:220) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:191) at org.springframework.orm.hibernate3.support.OpenSessionInViewFilter.doFilterInternal(OpenSessionInViewFilter.java:174) at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:76) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:220) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:191) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:227) at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:174) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127) at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:104) at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:108) at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:211) at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:817) at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:623) at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:444) at java.lang.Thread.run(Unknown Source)

      Cookies:
      JSESSIONID=[391CF7719F3C5D600CA8EBA6DAFB97E4] __openmrs_language=[en_US]

        Gliffy Diagrams

          Attachments

            Activity

              People

              Assignee:
              bwolfe Ben Wolfe
              Reporter:
              callen Christian Allen [X] (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              5 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved: