Hi Praveen - Is there no stacktrace anywhere? You are only getting the NPE line in the browser?
thanks, --larry On Thu, Aug 16, 2018 at 11:52 PM, Ravikumar, Praveen Krishnamoorthy < [email protected]> wrote: > Attached the SAML Tracer logs for reference. Could anyone please help me > in this? > > > > Thanks, > > Praveen. > > > > *From: *"Ravikumar, Praveen Krishnamoorthy" <[email protected]> > *Date: *Thursday, August 16, 2018 at 6:54 PM > *To: *"[email protected]" <[email protected]> > *Cc: *"Mohanan, Mahesh" <[email protected]> > *Subject: *Knox SSO - throwing null pointer exception on first time login > > > > Greetings, > > > > I’m facing a weird issue on enabling knox-sso functionality for exposing > UI’s running in AWS EMR. On enabling knox-sso, I tried to access the YARNUI > site – after authentication its throwing *java.lang.null.pointer* > exception but on submitting the url again (without clearing the cookies), > the application is getting landed to the proper page. > > > > When I clear the cookies and access the URL again, Its throwing null > pointer exception. We are unable to figure whether it is an issue on the > Identity provider site or in the knox as Im not seeing any error log > messages in both the ends. > > > > I have attached the log messages. Could any please help me in fixing this? > > > > > > Gatway.log -> After the first time login > > > > 2018-08-16 22:30:14,369 DEBUG knox.gateway (GatewayFilter.java:doFilter(119)) > - Received request: GET /yarn/ > > 2018-08-16 22:30:14,370 DEBUG federation.jwt > (SSOCookieFederationFilter.java:doFilter(114)) > - Sending redirect to: https://knox.idf-emr-prd.a.xxxx.com:8446/gateway/ > knoxsso/api/v1/websso?originalUrl=https://knox.idf- > emr-prd.a.xxxxx.com:8446/gateway/gate1/yarn/ > > 2018-08-16 22:30:14,493 DEBUG knox.gateway (GatewayFilter.java:doFilter(119)) > - Received request: GET /api/v1/websso > > > > > > > > > > > > > > > > > > > > [image: cid:[email protected]] > > > > Gateway.log -> Log in second time without clearing browser cookies > > > > Second time: > > > > 2018-08-16 22:34:15,242 DEBUG knox.gateway (GatewayFilter.java:doFilter(119)) > - Received request: GET /yarn/ > > 2018-08-16 22:34:15,242 DEBUG federation.jwt > (SSOCookieFederationFilter.java:doFilter(114)) > - Sending redirect to: https://knox.idf-emr-prd.a.xxxx.com:8446/gateway/ > knoxsso/api/v1/websso?originalUrl=https://knox.idf- > emr-prd.a.xxxx.com:8446/gateway/gate1/yarn/ > > 2018-08-16 22:34:15,362 DEBUG knox.gateway (GatewayFilter.java:doFilter(119)) > - Received request: GET /api/v1/websso > > 2018-08-16 22:34:17,055 DEBUG knox.gateway (GatewayFilter.java:doFilter(119)) > - Received request: POST /api/v1/websso > > 2018-08-16 22:34:17,279 DEBUG knox.gateway (GatewayFilter.java:doFilter(119)) > - Received request: GET /api/v1/websso > > 2018-08-16 22:34:17,279 DEBUG filter.Pac4jIdentityAdapter > (Pac4jIdentityAdapter.java:doFilter(85)) - User authenticated as: > #SAML2Profile# | id: [email protected] | attributes: {Mail=[ > [email protected]], UserID=[pravikumar], > notOnOrAfter=2018-08-16T22:39:16.775Z, > sessionindex=MdgrQer1EH_J2n1l.OX54WupIWl, > notBefore=2018-08-16T22:29:16.775Z} | roles: [] | permissions: [] | > isRemembered: false | clientName: SAML2Client | linkedId: null | > > 2018-08-16 22:34:17,282 INFO service.knoxsso > (WebSSOResource.java:init(113)) - The cookie max age is being set to: > session. > > 2018-08-16 22:34:17,282 WARN service.knoxsso > (WebSSOResource.java:init(117)) - The SSO cookie max age configuration is > invalid: session - using default. > > 2018-08-16 22:34:17,282 INFO service.knoxsso > (WebSSOResource.java:getCookieValue(330)) > - Unable to find cookie with name: original-url > > 2018-08-16 22:34:17,284 DEBUG service.knoxsso > (WebSSOResource.java:addJWTHadoopCookie(288)) > - Adding the following JWT token as a cookie: eyJhbGciOiJSUzI1NiJ9. > eyJzdWIiOiJQcmF2ZWVuX1JhdmlrdW1hckBpbnR1aXQuY29tIiwiaXNzIjoi > S05PWFNTTyIsImV4cCI6MTUzNDQ1ODk1N30.CKWaSVrxyW18O- > SJ7mc8ZieehS8izd90bAdQmTd38y-FkuTXhTMSTDy2_RqERLklgeiPGsE1zQ7TdxRA9wgQ3NB > YIaiAfBKE1epbmgFZ_MyAlmHvaSafXKF4LI49HNHJoUE1m2r4wRXsS1uysAwSMJ2r_ > TGs9obB4z6uYRC09YU > > 2018-08-16 22:34:17,284 INFO service.knoxsso > (WebSSOResource.java:addJWTHadoopCookie(304)) > - JWT cookie successfully added. > > 2018-08-16 22:34:17,284 INFO service.knoxsso > (WebSSOResource.java:getAuthenticationToken(214)) > - About to redirect to original URL: https://knox.idf-emr-prd. > a.intuit.com:8446/gateway/gate1/yarn/ > > 2018-08-16 22:34:17,399 DEBUG knox.gateway (GatewayFilter.java:doFilter(119)) > - Received request: GET /yarn/ > > 2018-08-16 22:34:17,399 DEBUG federation.jwt > (SSOCookieFederationFilter.java:getJWTFromCookie(161)) > - hadoop-jwt Cookie has been found and is being processed. > > 2018-08-16 22:34:17,400 DEBUG knox.gateway > (UrlRewriteProcessor.java:rewrite(161)) > - Rewrote URL: https://knox.idf-emr-prd.a.xxxxxx.com:8446/gateway/ > gate1/yarn/, direction: IN via implicit rule: YARNUI/yarn/inbound/root to > URL: http://ip-10-87-66-201.vpc.internal:8088/cluster > > 2018-08-16 22:34:17,401 DEBUG knox.gateway > (DefaultDispatch.java:executeOutboundRequest(121)) > - Dispatch request: GET http://ip-xx-xx-xx-xxx.vpc.internal:8088/cluster? > user.name=Praveen_Ravikumar%xxxxxxx.com > > 2018-08-16 22:34:17,405 DEBUG knox.gateway > (DefaultDispatch.java:executeOutboundRequest(134)) > - Dispatch response status: 200 > > > > > > Thanks, > > Praveen. > > >
