Bug 1236418 - NullPointerException in index.jsp on fresh Dogtag installation
Summary: NullPointerException in index.jsp on fresh Dogtag installation
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Fedora
Classification: Fedora
Component: dogtag-pki
Version: 22
Hardware: x86_64
OS: Unspecified
unspecified
high
Target Milestone: ---
Assignee: Matthew Harmsen
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2015-06-28 20:16 UTC by Pavel Malyshev
Modified: 2020-10-04 21:04 UTC (History)
5 users (show)

Fixed In Version:
Clone Of:
Environment:
Last Closed: 2016-01-18 19:06:25 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Github dogtagpki pki issues 2290 0 None None None 2020-10-04 21:04:44 UTC

Description Pavel Malyshev 2015-06-28 20:16:46 UTC
Description of problem:

I've installed fresh Fedora 22 Server and Dogtag using instructions here: http://pki.fedoraproject.org/wiki/Quick_Start

Right after pkispawn I try to connect to HTTPS server and get the following exception:

type Exception report

message An exception occurred processing JSP page /index.jsp at line 135

description The server encountered an internal error that prevented it from fulfilling this request.

exception

org.apache.jasper.JasperException: An exception occurred processing JSP page /index.jsp at line 135

132:     }
133: 
134:     ServletContext kraContext = getServletContext().getContext("/kra");
135:     String kraName = kraContext.getServletContextName();
136:     String kraPath = kraContext.getContextPath();
137:     if (!"".equals(kraPath) && request.isSecure()) {
138: %>


Stacktrace:
	org.apache.jasper.servlet.JspServletWrapper.handleJspException(JspServletWrapper.java:571)
	org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:470)
	org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:395)
	org.apache.jasper.servlet.JspServlet.service(JspServlet.java:339)
	javax.servlet.http.HttpServlet.service(HttpServlet.java:727)
	sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
	sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	java.lang.reflect.Method.invoke(Method.java:497)
	org.apache.catalina.security.SecurityUtil$1.run(SecurityUtil.java:276)
	org.apache.catalina.security.SecurityUtil$1.run(SecurityUtil.java:273)
	java.security.AccessController.doPrivileged(Native Method)
	javax.security.auth.Subject.doAsPrivileged(Subject.java:549)
	org.apache.catalina.security.SecurityUtil.execute(SecurityUtil.java:308)
	org.apache.catalina.security.SecurityUtil.doAsPrivilege(SecurityUtil.java:168)
	java.security.AccessController.doPrivileged(Native Method)
	org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:52)
	sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
	sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	java.lang.reflect.Method.invoke(Method.java:497)
	org.apache.catalina.security.SecurityUtil$1.run(SecurityUtil.java:276)
	org.apache.catalina.security.SecurityUtil$1.run(SecurityUtil.java:273)
	java.security.AccessController.doPrivileged(Native Method)
	javax.security.auth.Subject.doAsPrivileged(Subject.java:549)
	org.apache.catalina.security.SecurityUtil.execute(SecurityUtil.java:308)
	org.apache.catalina.security.SecurityUtil.doAsPrivilege(SecurityUtil.java:248)
root cause

java.lang.NullPointerException
	org.apache.jsp.index_jsp._jspService(index_jsp.java:200)
	org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70)
	javax.servlet.http.HttpServlet.service(HttpServlet.java:727)
	org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:432)
	org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:395)
	org.apache.jasper.servlet.JspServlet.service(JspServlet.java:339)
	javax.servlet.http.HttpServlet.service(HttpServlet.java:727)
	sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
	sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	java.lang.reflect.Method.invoke(Method.java:497)
	org.apache.catalina.security.SecurityUtil$1.run(SecurityUtil.java:276)
	org.apache.catalina.security.SecurityUtil$1.run(SecurityUtil.java:273)
	java.security.AccessController.doPrivileged(Native Method)
	javax.security.auth.Subject.doAsPrivileged(Subject.java:549)
	org.apache.catalina.security.SecurityUtil.execute(SecurityUtil.java:308)
	org.apache.catalina.security.SecurityUtil.doAsPrivilege(SecurityUtil.java:168)
	java.security.AccessController.doPrivileged(Native Method)
	org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:52)
	sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
	sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	java.lang.reflect.Method.invoke(Method.java:497)
	org.apache.catalina.security.SecurityUtil$1.run(SecurityUtil.java:276)
	org.apache.catalina.security.SecurityUtil$1.run(SecurityUtil.java:273)
	java.security.AccessController.doPrivileged(Native Method)
	javax.security.auth.Subject.doAsPrivileged(Subject.java:549)
	org.apache.catalina.security.SecurityUtil.execute(SecurityUtil.java:308)
	org.apache.catalina.security.SecurityUtil.doAsPrivilege(SecurityUtil.java:248)
note The full stack trace of the root cause is available in the Apache Tomcat/7.0.59 logs.



Version-Release number of selected component (if applicable):
# rpm -qa | grep dogtag
dogtag-pki-10.2.4-1.fc22.noarch
dogtag-pki-console-theme-10.2.4-1.fc22.noarch
dogtag-pki-server-theme-10.2.4-1.fc22.noarch

How reproducible:

Always

Steps to Reproduce:
1. Install Fedora 22 Server
2. dnf update -y
3. reboot
4. dnf install 389-ds-base dogtag-pki
5. setup-ds.pl --silent\
 General.FullMachineName=`hostname`\
 General.SuiteSpotUserID=nobody\
 General.SuiteSpotGroup=nobody\
 slapd.ServerPort=389\
 slapd.ServerIdentifier=pki-tomcat\
 slapd.Suffix=dc=example,dc=com\
 slapd.RootDN="cn=Directory Manager"\
 slapd.RootDNPwd=Secret123
6. pkispawn
   (for CA)
7. pkispawm
   (for KRA)
8. open https://<IP>:8443


Actual results:

NullPointerException report


Expected results:

Dogtag management interface

Additional info:

Tried to restart service with no luck.

Comment 1 Endi Sukma Dewata 2015-06-29 15:13:19 UTC
The problem was caused by the change of behavior of getServletContext().getContext() in recent Tomcat version. It has been fixed in Dogtag 10.2.5-1. Could you please try again? Thanks.

Comment 2 Pavel Malyshev 2015-06-30 05:49:21 UTC
The issue gone away with 10.2.5-1.f22, but it is still in updates-testing, not in stable.

Comment 3 Matthew Harmsen 2016-01-13 00:38:07 UTC
Upstream ticket:
https://fedorahosted.org/pki/ticket/1732

Comment 4 Endi Sukma Dewata 2016-01-18 19:06:25 UTC
This issue no longer exists in the current release (10.2.6). See also PKI ticket #1407.


Note You need to log in before you can comment on or make changes to this bug.