From 9b7a1107045338de76443fa7f9f51a904b671b2a Mon Sep 17 00:00:00 2001 From: Steve Riesenberg Date: Tue, 12 Sep 2023 15:59:32 -0500 Subject: [PATCH 1/2] Fix OAuth2AuthenticationExceptionMixinTests on JDK 17 Closes gh-11893 --- .../jackson2/OAuth2AuthenticationExceptionMixin.java | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/oauth2/oauth2-client/src/main/java/org/springframework/security/oauth2/client/jackson2/OAuth2AuthenticationExceptionMixin.java b/oauth2/oauth2-client/src/main/java/org/springframework/security/oauth2/client/jackson2/OAuth2AuthenticationExceptionMixin.java index 9fa810c1ac3..cf2e4818b93 100644 --- a/oauth2/oauth2-client/src/main/java/org/springframework/security/oauth2/client/jackson2/OAuth2AuthenticationExceptionMixin.java +++ b/oauth2/oauth2-client/src/main/java/org/springframework/security/oauth2/client/jackson2/OAuth2AuthenticationExceptionMixin.java @@ -1,5 +1,5 @@ /* - * Copyright 2002-2020 the original author or authors. + * Copyright 2002-2023 the original author or authors. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -30,16 +30,23 @@ * {@link OAuth2AuthenticationException}. * * @author Dennis Neufeld + * @author Steve Riesenberg * @since 5.3.4 * @see OAuth2AuthenticationException * @see OAuth2ClientJackson2Module */ @JsonTypeInfo(use = JsonTypeInfo.Id.CLASS) -@JsonAutoDetect(fieldVisibility = JsonAutoDetect.Visibility.ANY, getterVisibility = JsonAutoDetect.Visibility.NONE, +@JsonAutoDetect(fieldVisibility = JsonAutoDetect.Visibility.NONE, getterVisibility = JsonAutoDetect.Visibility.NONE, isGetterVisibility = JsonAutoDetect.Visibility.NONE) @JsonIgnoreProperties(ignoreUnknown = true, value = { "cause", "stackTrace", "suppressedExceptions" }) abstract class OAuth2AuthenticationExceptionMixin { + @JsonProperty("error") + abstract OAuth2Error getError(); + + @JsonProperty("detailMessage") + abstract String getMessage(); + @JsonCreator OAuth2AuthenticationExceptionMixin(@JsonProperty("error") OAuth2Error error, @JsonProperty("detailMessage") String message) { From a580856bb2ec0d244de772be21c13c17ddb09b01 Mon Sep 17 00:00:00 2001 From: Steve Riesenberg Date: Tue, 12 Sep 2023 13:59:03 -0500 Subject: [PATCH 2/2] Update jacoco tool version to 0.8.9 Closes gh-13798 --- .../main/groovy/io/spring/gradle/convention/JacocoPlugin.groovy | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/buildSrc/src/main/groovy/io/spring/gradle/convention/JacocoPlugin.groovy b/buildSrc/src/main/groovy/io/spring/gradle/convention/JacocoPlugin.groovy index 8f558eabbe3..7a8def2b6d7 100644 --- a/buildSrc/src/main/groovy/io/spring/gradle/convention/JacocoPlugin.groovy +++ b/buildSrc/src/main/groovy/io/spring/gradle/convention/JacocoPlugin.groovy @@ -34,7 +34,7 @@ class JacocoPlugin implements Plugin { project.tasks.check.dependsOn project.tasks.jacocoTestReport project.jacoco { - toolVersion = '0.8.7' + toolVersion = '0.8.9' } } }