java.lang.NullPointerException

runawfe | gritsenko_s | 3 years ago
  1. 0

    NPE

    runawfe | 3 years ago | gritsenko_s
    java.lang.NullPointerException
  2. 0

    This NPE should be prevented by checking if the function `org.forgerock.util.encode.Base64.decode(encoded.toCharArray())` returns a null value in the class `openam-shared/src/main/java/com/sun/identity/shared/encode/Base64.java`. {code} /** * Decodes a BASE64 encoded char array. All illegal characters will be * ignored and can handle both arrays with and without line separators. * * @param sArr * The source array. <code>null</code> or length 0 will return an * empty array. * @return The decoded array of bytes. May be of length 0. Will be * <code>null</code> if the legal characters (including '=') isn't * divideable by 4. (I.e. definitely corrupted). */ public static byte[] decode(final char[] sArr) { {code} The NPE: {code} ERROR: AuthenticationServletBase.onUncaughtException: java.lang.NullPointerException at java.lang.String.<init>(String.java:505) at com.sun.identity.shared.encode.Base64.decodeAsUTF8String(Base64.java:86) at com.sun.identity.authentication.client.AuthClientUtils.decodeHash(AuthClientUtils.java:381) at com.sun.identity.authentication.client.AuthClientUtils.parseRequestParameters(AuthClientUtils.java:354) at com.sun.identity.authentication.UI.LoginViewBean.forwardTo(LoginViewBean.java:279) at com.iplanet.jato.ApplicationServletBase.dispatchRequest(ApplicationServletBase.java:981) at com.iplanet.jato.ApplicationServletBase.processRequest(ApplicationServletBase.java:615) at com.iplanet.jato.ApplicationServletBase.doPost(ApplicationServletBase.java:473) at javax.servlet.http.HttpServlet.service(HttpServlet.java:647) at javax.servlet.http.HttpServlet.service(HttpServlet.java:728) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:305) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210) at org.forgerock.openam.validation.ResponseValidationFilter.doFilter(ResponseValidationFilter.java:44) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:243) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210) at org.forgerock.openam.xui.XUIFilter.doFilter(XUIFilter.java:112) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:243) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210) at com.sun.identity.setup.AMSetupFilter.doFilter(AMSetupFilter.java:100) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:243) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210) at de.o2.servlet.filter.setup.LoopProtectServletFilter.doFilter(LoopProtectServletFilter.java:77) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:243) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:222) at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:123) at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:472) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:171) at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:99) at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:931) at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:118) at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:407) at org.apache.coyote.ajp.AjpProcessor.process(AjpProcessor.java:200) at org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(AbstractProtocol.java:589) at org.apache.tomcat.util.net.JIoEndpoint$SocketProcessor.run(JIoEndpoint.java:310) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) at java.lang.Thread.run(Thread.java:745) {code}

    ForgeRock JIRA | 1 year ago | Quentin CASTEL
    java.lang.NullPointerException
  3. Speed up your debug routine!

    Automated exception search integrated into your IDE

  4. 0

    pipelined get command: java.lang.NullPointerException

    GitHub | 5 years ago | shijinkui
    java.lang.NullPointerException
  5. 0

    Response<String> throws NPE for not existed fields

    GitHub | 5 years ago | kalondar
    java.lang.NullPointerException

  1. Handemelindo 1 times, last 1 month ago
  2. RoiOtero 9 times, last 8 months ago
  3. saumitras 2 times, last 9 months ago
5 unregistered visitors
Not finding the right solution?
Take a tour to get the most out of Samebug.

Tired of useless tips?

Automated exception search integrated into your IDE

Root Cause Analysis

  1. java.lang.NullPointerException

    No message provided

    at java.lang.String.<init>()
  2. Java RT
    String.<init>
    1. java.lang.String.<init>(String.java:505)
    1 frame
  3. ru.runa.wf
    StartFormTag.fillFormElement
    1. ru.runa.wf.web.quick.BaseQuickFormBuilder.quickTemplateProcess(BaseQuickFormBuilder.java:87)
    2. ru.runa.wf.web.quick.BaseQuickFormBuilder.build(BaseQuickFormBuilder.java:68)
    3. ru.runa.wf.web.quick.QuickFormStartBuilder.build(QuickFormStartBuilder.java:19)
    4. ru.runa.wf.web.tag.StartFormTag.buildForm(StartFormTag.java:58)
    5. ru.runa.wf.web.tag.WFFormTag.fillFormElement(WFFormTag.java:48)
    6. ru.runa.wf.web.tag.StartFormTag.fillFormElement(StartFormTag.java:82)
    6 frames
  4. ru.runa.common
    VisibleTag.doEndTag
    1. ru.runa.common.web.tag.FormTag.getEndElement(FormTag.java:139)
    2. ru.runa.common.web.tag.TitledFormTag.getEndElement(TitledFormTag.java:90)
    3. ru.runa.common.web.tag.VisibleTag.doEndTag(VisibleTag.java:104)
    3 frames
  5. org.apache.jsp
    submit_005fstart_005fprocess_jsp._jspService
    1. org.apache.jsp.WEB_002dINF.wf.submit_005fstart_005fprocess_jsp._jspService(submit_005fstart_005fprocess_jsp.java:126)
    1 frame