OpenConext / OpenConext-oidcng

OpenID Connect gateway - The Next Generation
3 stars 5 forks source link

less verbose logging when an unsupported prompt parameter is requested #185

Closed phavekes closed 1 month ago

phavekes commented 1 month ago

This issue is imported from pivotal - Originaly created at Jan 26, 2023 by Bart Geesink

When "prompt=none" or any other prompt value that is not supported is requested, a full stack trace is logged. This is unnecessary, one line is sufficient: "Unsupported prompt=$wrongvalue is requested, redirecting the user back to the RP"

phavekes commented 1 month ago

Jan 26 11:45:29 japp2.prd.ams.surfconext.nl oidcng: [http-nio-9195-exec-9] org.apache.catalina.core.ContainerBase.[Tomcat].[localhost].[/].[dispatcherServlet] Servlet.service() for servlet [dispatcherServlet] in context with path [] threw exception Jan 26 11:45:29 japp2.prd.ams.surfconext.nl #011oidc.exceptions.UnsupportedPromptValueException: Unsupported Prompt value Jan 26 11:45:29 japp2.prd.ams.surfconext.nl #011at oidc.endpoints.AuthorizationEndpoint.lambda$validatePrompt$8(AuthorizationEndpoint.java:399) Jan 26 11:45:29 japp2.prd.ams.surfconext.nl #011at java.base/java.util.ArrayList.forEach(ArrayList.java:1541) Jan 26 11:45:29 japp2.prd.ams.surfconext.nl #011at oidc.endpoints.AuthorizationEndpoint.validatePrompt(AuthorizationEndpoint.java:397) Jan 26 11:45:29 japp2.prd.ams.surfconext.nl #011at oidc.endpoints.AuthorizationEndpoint.validatePrompt(AuthorizationEndpoint.java:390) Jan 26 11:45:29 japp2.prd.ams.surfconext.nl #011at oidc.saml.AuthnRequestConverter.enhanceAuthenticationRequest(AuthnRequestConverter.java:157) Jan 26 11:45:29 japp2.prd.ams.surfconext.nl #011at oidc.saml.AuthnRequestConverter.convert(AuthnRequestConverter.java:133) Jan 26 11:45:29 japp2.prd.ams.surfconext.nl #011at oidc.saml.AuthnRequestConverter.convert(AuthnRequestConverter.java:50) Jan 26 11:45:29 japp2.prd.ams.surfconext.nl #011at org.springframework.security.saml2.provider.service.authentication.OpenSaml4AuthenticationRequestFactory.createRedirectAuthenticationRequest(OpenSaml4AuthenticationRequestFactory.java:123) Jan 26 11:45:29 japp2.prd.ams.surfconext.nl #011at org.springframework.security.saml2.provider.service.servlet.filter.Saml2WebSsoAuthenticationRequestFilter$FactorySaml2AuthenticationRequestResolver.resolve(Saml2WebSsoAuthenticationRequestFilter.java:304) Jan 26 11:45:29 japp2.prd.ams.surfconext.nl #011at org.springframework.security.saml2.provider.service.servlet.filter.Saml2WebSsoAuthenticationRequestFilter.doFilterInternal(Saml2WebSsoAuthenticationRequestFilter.java:190) Jan 26 11:45:29 japp2.prd.ams.surfconext.nl #011at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:117) Jan 26 11:45:29 japp2.prd.ams.surfconext.nl #011at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:346) Jan 26 11:45:29 japp2.prd.ams.surfconext.nl #011at org.springframework.security.web.authentication.logout.LogoutFilter.doFilter(LogoutFilter.java:103) Jan 26 11:45:29 japp2.prd.ams.surfconext.nl #011at org.springframework.security.web.authentication.logout.LogoutFilter.doFilter(LogoutFilter.java:89) Jan 26 11:45:29 japp2.prd.ams.surfconext.nl #011at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:346) Jan 26 11:45:29 japp2.prd.ams.surfconext.nl #011at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:111) Jan 26 11:45:29 japp2.prd.ams.surfconext.nl #011at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:346) Jan 26 11:45:29 japp2.prd.ams.surfconext.nl #011at org.springframework.web.filter.CorsFilter.doFilterInternal(CorsFilter.java:91) Jan 26 11:45:29 japp2.prd.ams.surfconext.nl #011at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:117) Jan 26 11:45:29 japp2.prd.ams.surfconext.nl #011at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:346) Jan 26 11:45:29 japp2.prd.ams.surfconext.nl #011at org.springframework.security.web.header.HeaderWriterFilter.doHeadersAfter(HeaderWriterFilter.java:90) Jan 26 11:45:29 japp2.prd.ams.surfconext.nl #011at org.springframework.security.web.header.HeaderWriterFilter.doFilterInternal(HeaderWriterFilter.java:75) Jan 26 11:45:29 japp2.prd.ams.surfconext.nl #011at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:117) Jan 26 11:45:29 japp2.prd.ams.surfconext.nl #011at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:346) Jan 26 11:45:29 japp2.prd.ams.surfconext.nl #011at org.springframework.security.web.context.SecurityContextPersistenceFilter.doFilter(SecurityContextPersistenceFilter.java:112) Jan 26 11:45:29 japp2.prd.ams.surfconext.nl #011at org.springframework.security.web.context.SecurityContextPersistenceFilter.doFilter(SecurityContextPersistenceFilter.java:82) Jan 26 11:45:29 japp2.prd.ams.surfconext.nl #011at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:346) Jan 26 11:45:29 japp2.prd.ams.surfconext.nl #011at org.springframework.security.web.context.request.async.WebAsyncManagerIntegrationFilter.doFilterInternal(WebAsyncManagerIntegrationFilter.java:55) Jan 26 11:45:29 japp2.prd.ams.surfconext.nl #011at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:117) Jan 26 11:45:29 japp2.prd.ams.surfconext.nl #011at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:346) Jan 26 11:45:29 japp2.prd.ams.surfconext.nl #011at org.springframework.security.web.session.DisableEncodeUrlFilter.doFilterInternal(DisableEncodeUrlFilter.java:42) Jan 26 11:45:29 japp2.prd.ams.surfconext.nl #011at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:117) Jan 26 11:45:29 japp2.prd.ams.surfconext.nl #011at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:346) Jan 26 11:45:29 japp2.prd.ams.surfconext.nl #011at org.springframework.security.web.FilterChainProxy.doFilterInternal(FilterChainProxy.java:221) Jan 26 11:45:29 japp2.prd.ams.surfconext.nl #011at org.springframework.security.web.FilterChainProxy.doFilter(FilterChainProxy.java:186) Jan 26 11:45:29 japp2.prd.ams.surfconext.nl #011at org.springframework.web.filter.DelegatingFilterProxy.invokeDelegate(DelegatingFilterProxy.java:354) Jan 26 11:45:29 japp2.prd.ams.surfconext.nl #011at org.springframework.web.filter.DelegatingFilterProxy.doFilter(DelegatingFilterProxy.java:267) Jan 26 11:45:29 japp2.prd.ams.surfconext.nl #011at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:189) Jan 26 11:45:29 japp2.prd.ams.surfconext.nl #011at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:162) Jan 26 11:45:29 japp2.prd.ams.surfconext.nl #011at org.springframework.web.filter.RequestContextFilter.doFilterInternal(RequestContextFilter.java:100) Jan 26 11:45:29 japp2.prd.ams.surfconext.nl #011at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:117) Jan 26 11:45:29 japp2.prd.ams.surfconext.nl #011at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:189) Jan 26 11:45:29 japp2.prd.ams.surfconext.nl #011at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:162) Jan 26 11:45:29 japp2.prd.ams.surfconext.nl #011at org.springframework.web.filter.FormContentFilter.doFilterInternal(FormContentFilter.java:93) Jan 26 11:45:29 japp2.prd.ams.surfconext.nl #011at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:117) Jan 26 11:45:29 japp2.prd.ams.surfconext.nl #011at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:189) Jan 26 11:45:29 japp2.prd.ams.surfconext.nl #011at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:162) Jan 26 11:45:29 japp2.prd.ams.surfconext.nl #011at org.springframework.session.web.http.SessionRepositoryFilter.doFilterInternal(SessionRepositoryFilter.java:142) Jan 26 11:45:29 japp2.prd.ams.surfconext.nl #011at org.springframework.session.web.http.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:82) Jan 26 11:45:29 japp2.prd.ams.surfconext.nl #011at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:189) Jan 26 11:45:29 japp2.prd.ams.surfconext.nl #011at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:162) Jan 26 11:45:29 japp2.prd.ams.surfconext.nl #011at org.springframework.web.filter.CharacterEncodingFilter.doFilterInternal(CharacterEncodingFilter.java:201) Jan 26 11:45:29 japp2.prd.ams.surfconext.nl #011at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:117) Jan 26 11:45:29 japp2.prd.ams.surfconext.nl #011at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:189) Jan 26 11:45:29 japp2.prd.ams.surfconext.nl #011at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:162) Jan 26 11:45:29 japp2.prd.ams.surfconext.nl #011at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:197) Jan 26 11:45:29 japp2.prd.ams.surfconext.nl #011at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:97) Jan 26 11:45:29 japp2.prd.ams.surfconext.nl #011at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:541) Jan 26 11:45:29 japp2.prd.ams.surfconext.nl #011at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:135) Jan 26 11:45:29 japp2.prd.ams.surfconext.nl #011at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:92) Jan 26 11:45:29 japp2.prd.ams.surfconext.nl #011at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:78) Jan 26 11:45:29 japp2.prd.ams.surfconext.nl #011at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:360) Jan 26 11:45:29 japp2.prd.ams.surfconext.nl #011at org.apache.coyote.http11.Http11Processor.service(Http11Processor.java:399) Jan 26 11:45:29 japp2.prd.ams.surfconext.nl #011at org.apache.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:65) Jan 26 11:45:29 japp2.prd.ams.surfconext.nl #011at org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:893) Jan 26 11:45:29 japp2.prd.ams.surfconext.nl #011at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1789) Jan 26 11:45:29 japp2.prd.ams.surfconext.nl #011at org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:49) Jan 26 11:45:29 japp2.prd.ams.surfconext.nl #011at org.apache.tomcat.util.threads.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1191) Jan 26 11:45:29 japp2.prd.ams.surfconext.nl #011at org.apache.tomcat.util.threads.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:659) Jan 26 11:45:29 japp2.prd.ams.surfconext.nl #011at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61) Jan 26 11:45:29 japp2.prd.ams.surfconext.nl #011at java.base/java.lang.Thread.run(Thread.java:829) (Bart Geesink - Jan 26, 2023)