Hi Andrea, Thanks for the response. I have created a ticket as suggested.
I will get the server admin to revert to the previous Java version that worked. Cheers, Graham From: Andrea Aime <andrea.a...@geosolutionsgroup.com> Sent: Thursday, 18 November 2021 8:29 PM To: Humphries, Graham <graham.humphr...@stategrowth.tas.gov.au> Cc: geoserver-users@lists.sourceforge.net Subject: Re: [Geoserver-users] Geoserver throws CloneNotSupportedException when using Basic Authentication Looks like you're getting a MessageDigest implementation that's not cloneable... possibly due to the upgrade. The code in there cannot handle that case, has been lìke that since 2013 without issues, but I guess something changed in recent Java 11. We haven't see it happening yet, even with Java 11, I guess it's either a new behavior in the latest Java 11 releases, or you're facing some "classpath russian roulette" (multiple libs offering the same capabilities, being picked up in a different order on different systems). I suggest you open a ticket at https://osgeo-org.atlassian.net/browse/GEOS/summary<https://aus01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fosgeo-org.atlassian.net%2Fbrowse%2FGEOS%2Fsummary&data=04%7C01%7Cgraham.humphries%40stategrowth.tas.gov.au%7C7cb59cd072fa4894e27508d9aa75d5e3%7C64ebab8accf44b5ca2d32b4e972d96b2%7C0%7C0%7C637728245353218152%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000&sdata=ETYagj9mRD3WCa1gLgZVWgKiqeICbBGs3%2FfvWxJVxO8%3D&reserved=0> and in the meantime switch to a Java version that's working for you Cheers Andrea On Thu, Nov 18, 2021 at 12:21 AM Humphries, Graham <graham.humphr...@stategrowth.tas.gov.au<mailto:graham.humphr...@stategrowth.tas.gov.au>> wrote: I have recently upgraded my Tomcat version to: Apache Tomcat/9.0.53 and Java to 11.0.12+7-LTS. Geoserver is version 2.20.0. Since then Geoserver throws CloneNotSupportedException when using Basic Authentication passed in the request header. Does anyone know what causes this and what the solution is? The following is the error in the response: <!doctype html><html lang="en"><head><title>HTTP Status 500 - Internal Server Error</title><style type="text/css">body {font-family:Tahoma,Arial,sans-serif;} h1, h2, h3, b {color:white;background-color:#525D76;} h1 {font-size:22px;} h2 {font-size:16px;} h3 {font-size:14px;} p {font-size:12px;} a {color:black;} .line {height:1px;background-color:#525D76;border:none;}</style></head><body><h1>HTTP Status 500 - Internal Server Error</h1><hr class="line" /><p><b>Type</b> Exception Report</p><p><b>Message</b> java.lang.CloneNotSupportedException</p><p><b>Description</b> The server encountered an unexpected condition that prevented it from fulfilling the request.</p><p><b>Exception</b></p><pre>java.lang.RuntimeException: java.lang.CloneNotSupportedException org.geoserver.security.filter.GeoServerBasicAuthenticationFilter.getCacheKey(GeoServerBasicAuthenticationFilter.java:122) org.geoserver.security.filter.GeoServerSecurityFilter.authenticateFromCache(GeoServerSecurityFilter.java:76) org.geoserver.security.filter.GeoServerCompositeFilter$NestedFilterChain.doFilter(GeoServerCompositeFilter.java:47) org.geoserver.security.filter.GeoServerCompositeFilter.doFilter(GeoServerCompositeFilter.java:91) org.geoserver.security.filter.GeoServerBasicAuthenticationFilter.doFilter(GeoServerBasicAuthenticationFilter.java:81) org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:334) org.geoserver.security.filter.GeoServerCompositeFilter$NestedFilterChain.doFilter(GeoServerCompositeFilter.java:70) org.springframework.security.web.context.SecurityContextPersistenceFilter.doFilter(SecurityContextPersistenceFilter.java:105) org.geoserver.security.filter.GeoServerSecurityContextPersistenceFilter$1.doFilter(GeoServerSecurityContextPersistenceFilter.java:52) org.geoserver.security.filter.GeoServerCompositeFilter$NestedFilterChain.doFilter(GeoServerCompositeFilter.java:74) org.geoserver.security.filter.GeoServerCompositeFilter.doFilter(GeoServerCompositeFilter.java:91) org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:334) org.springframework.security.web.FilterChainProxy.doFilterInternal(FilterChainProxy.java:215) org.springframework.security.web.FilterChainProxy.doFilter(FilterChainProxy.java:178) org.geoserver.security.GeoServerSecurityFilterChainProxy.doFilter(GeoServerSecurityFilterChainProxy.java:142) org.springframework.web.filter.DelegatingFilterProxy.invokeDelegate(DelegatingFilterProxy.java:358) org.springframework.web.filter.DelegatingFilterProxy.doFilter(DelegatingFilterProxy.java:271) org.geoserver.filters.LoggingFilter.doFilter(LoggingFilter.java:101) org.geoserver.filters.XFrameOptionsFilter.doFilter(XFrameOptionsFilter.java:77) org.geoserver.filters.GZIPFilter.doFilter(GZIPFilter.java:47) org.geoserver.filters.SessionDebugFilter.doFilter(SessionDebugFilter.java:46) org.geoserver.filters.FlushSafeFilter.doFilter(FlushSafeFilter.java:42) org.springframework.web.filter.CharacterEncodingFilter.doFilterInternal(CharacterEncodingFilter.java:201) org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:119) </pre><p><b>Root Cause</b></p><pre>java.lang.CloneNotSupportedException java.base/java.security.MessageDigest$Delegate.clone(MessageDigest.java:610) org.geoserver.security.filter.GeoServerBasicAuthenticationFilter.getCacheKey(GeoServerBasicAuthenticationFilter.java:119) org.geoserver.security.filter.GeoServerSecurityFilter.authenticateFromCache(GeoServerSecurityFilter.java:76) org.geoserver.security.filter.GeoServerCompositeFilter$NestedFilterChain.doFilter(GeoServerCompositeFilter.java:47) org.geoserver.security.filter.GeoServerCompositeFilter.doFilter(GeoServerCompositeFilter.java:91) org.geoserver.security.filter.GeoServerBasicAuthenticationFilter.doFilter(GeoServerBasicAuthenticationFilter.java:81) org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:334) org.geoserver.security.filter.GeoServerCompositeFilter$NestedFilterChain.doFilter(GeoServerCompositeFilter.java:70) org.springframework.security.web.context.SecurityContextPersistenceFilter.doFilter(SecurityContextPersistenceFilter.java:105) org.geoserver.security.filter.GeoServerSecurityContextPersistenceFilter$1.doFilter(GeoServerSecurityContextPersistenceFilter.java:52) org.geoserver.security.filter.GeoServerCompositeFilter$NestedFilterChain.doFilter(GeoServerCompositeFilter.java:74) org.geoserver.security.filter.GeoServerCompositeFilter.doFilter(GeoServerCompositeFilter.java:91) org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:334) org.springframework.security.web.FilterChainProxy.doFilterInternal(FilterChainProxy.java:215) org.springframework.security.web.FilterChainProxy.doFilter(FilterChainProxy.java:178) org.geoserver.security.GeoServerSecurityFilterChainProxy.doFilter(GeoServerSecurityFilterChainProxy.java:142) org.springframework.web.filter.DelegatingFilterProxy.invokeDelegate(DelegatingFilterProxy.java:358) org.springframework.web.filter.DelegatingFilterProxy.doFilter(DelegatingFilterProxy.java:271) org.geoserver.filters.LoggingFilter.doFilter(LoggingFilter.java:101) org.geoserver.filters.XFrameOptionsFilter.doFilter(XFrameOptionsFilter.java:77) org.geoserver.filters.GZIPFilter.doFilter(GZIPFilter.java:47) org.geoserver.filters.SessionDebugFilter.doFilter(SessionDebugFilter.java:46) org.geoserver.filters.FlushSafeFilter.doFilter(FlushSafeFilter.java:42) org.springframework.web.filter.CharacterEncodingFilter.doFilterInternal(CharacterEncodingFilter.java:201) org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:119) ________________________________ CONFIDENTIALITY NOTICE AND DISCLAIMER The information in this transmission may be confidential and/or protected by legal professional privilege, and is intended only for the person or persons to whom it is addressed. If you are not such a person, you are warned that any disclosure, copying or dissemination of the information is unauthorised. If you have received the transmission in error, please immediately contact this office by telephone, fax or email, to inform us of the error and to enable arrangements to be made for the destruction of the transmission, or its return at our cost. No liability is accepted for any unauthorised use of the information contained in this transmission. _______________________________________________ Geoserver-users mailing list Please make sure you read the following two resources before posting to this list: - Earning your support instead of buying it, but Ian Turton: http://www.ianturton.com/talks/foss4g.html#/<https://aus01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.ianturton.com%2Ftalks%2Ffoss4g.html%23%2F&data=04%7C01%7Cgraham.humphries%40stategrowth.tas.gov.au%7C7cb59cd072fa4894e27508d9aa75d5e3%7C64ebab8accf44b5ca2d32b4e972d96b2%7C0%7C0%7C637728245353228143%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000&sdata=ZkyE7paM4gxcAztDpxPtsdHzHeZxukr%2FHtWi3JoJ3ww%3D&reserved=0> - The GeoServer user list posting guidelines: http://geoserver.org/comm/userlist-guidelines.html<https://aus01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fgeoserver.org%2Fcomm%2Fuserlist-guidelines.html&data=04%7C01%7Cgraham.humphries%40stategrowth.tas.gov.au%7C7cb59cd072fa4894e27508d9aa75d5e3%7C64ebab8accf44b5ca2d32b4e972d96b2%7C0%7C0%7C637728245353228143%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000&sdata=Kn5Cop3n2EtRLKnBju6071mfL4GzaW0h9jxmfU4BKqg%3D&reserved=0> If you want to request a feature or an improvement, also see this: https://github.com/geoserver/geoserver/wiki/Successfully-requesting-and-integrating-new-features-and-improvements-in-GeoServer<https://aus01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fgeoserver%2Fgeoserver%2Fwiki%2FSuccessfully-requesting-and-integrating-new-features-and-improvements-in-GeoServer&data=04%7C01%7Cgraham.humphries%40stategrowth.tas.gov.au%7C7cb59cd072fa4894e27508d9aa75d5e3%7C64ebab8accf44b5ca2d32b4e972d96b2%7C0%7C0%7C637728245353238135%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000&sdata=h%2BhrGltNVvxcYtteIQNkRSDUkHXNq1q9SjmOLAcGIJk%3D&reserved=0> Geoserver-users@lists.sourceforge.net<mailto:Geoserver-users@lists.sourceforge.net> https://lists.sourceforge.net/lists/listinfo/geoserver-users<https://aus01.safelinks.protection.outlook.com/?url=https%3A%2F%2Flists.sourceforge.net%2Flists%2Flistinfo%2Fgeoserver-users&data=04%7C01%7Cgraham.humphries%40stategrowth.tas.gov.au%7C7cb59cd072fa4894e27508d9aa75d5e3%7C64ebab8accf44b5ca2d32b4e972d96b2%7C0%7C0%7C637728245353248131%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000&sdata=mlABgt2W6rAFClR28PLlTp3lsAQBLFKlXGB8poVxios%3D&reserved=0> -- Regards, Andrea Aime == GeoServer Professional Services from the experts! Visit http://bit.ly/gs-services-us<https://aus01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fbit.ly%2Fgs-services-us&data=04%7C01%7Cgraham.humphries%40stategrowth.tas.gov.au%7C7cb59cd072fa4894e27508d9aa75d5e3%7C64ebab8accf44b5ca2d32b4e972d96b2%7C0%7C0%7C637728245353248131%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000&sdata=R2V5iWbDAGavv3k%2BZmbLl59KSl%2FVJWXBuCIuk%2FZqh%2BY%3D&reserved=0> for more information. == Ing. Andrea Aime @geowolf Technical Lead GeoSolutions Group phone: +39 0584 962313 fax: +39 0584 1660272 mob: +39 333 8128928 https://www.geosolutionsgroup.com/<https://aus01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.geosolutionsgroup.com%2F&data=04%7C01%7Cgraham.humphries%40stategrowth.tas.gov.au%7C7cb59cd072fa4894e27508d9aa75d5e3%7C64ebab8accf44b5ca2d32b4e972d96b2%7C0%7C0%7C637728245353258125%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000&sdata=f7xpBbjPloDtO4aDOuI7MAtZPa7MvoO7UEkuySnha0I%3D&reserved=0> http://twitter.com/geosolutions_it<https://aus01.safelinks.protection.outlook.com/?url=http%3A%2F%2Ftwitter.com%2Fgeosolutions_it&data=04%7C01%7Cgraham.humphries%40stategrowth.tas.gov.au%7C7cb59cd072fa4894e27508d9aa75d5e3%7C64ebab8accf44b5ca2d32b4e972d96b2%7C0%7C0%7C637728245353268118%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000&sdata=YaqkZSv9JT%2Fuc7WTcrY3W96BsH90DKpKuyDduxiQa4w%3D&reserved=0> ------------------------------------------------------- Con riferimento alla normativa sul trattamento dei dati personali (Reg. UE 2016/679 - Regolamento generale sulla protezione dei dati "GDPR"), si precisa che ogni circostanza inerente alla presente email (il suo contenuto, gli eventuali allegati, etc.) è un dato la cui conoscenza è riservata al/i solo/i destinatario/i indicati dallo scrivente. Se il messaggio Le è giunto per errore, è tenuta/o a cancellarlo, ogni altra operazione è illecita. Le sarei comunque grato se potesse darmene notizia. This email is intended only for the person or entity to which it is addressed and may contain information that is privileged, confidential or otherwise protected from disclosure. We remind that - as provided by European Regulation 2016/679 "GDPR" - copying, dissemination or use of this e-mail or the information herein by anyone other than the intended recipient is prohibited. If you have received this email by mistake, please notify us immediately by telephone or e-mail ________________________________ CONFIDENTIALITY NOTICE AND DISCLAIMER The information in this transmission may be confidential and/or protected by legal professional privilege, and is intended only for the person or persons to whom it is addressed. If you are not such a person, you are warned that any disclosure, copying or dissemination of the information is unauthorised. If you have received the transmission in error, please immediately contact this office by telephone, fax or email, to inform us of the error and to enable arrangements to be made for the destruction of the transmission, or its return at our cost. No liability is accepted for any unauthorised use of the information contained in this transmission.
_______________________________________________ Geoserver-users mailing list Please make sure you read the following two resources before posting to this list: - Earning your support instead of buying it, but Ian Turton: http://www.ianturton.com/talks/foss4g.html#/ - The GeoServer user list posting guidelines: http://geoserver.org/comm/userlist-guidelines.html If you want to request a feature or an improvement, also see this: https://github.com/geoserver/geoserver/wiki/Successfully-requesting-and-integrating-new-features-and-improvements-in-GeoServer Geoserver-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/geoserver-users