Skip to content

Commit cca8821

Browse files
committed
rename
1 parent e556844 commit cca8821

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

oauth2-authorization-server/src/main/java/org/springframework/security/oauth2/server/authorization/authentication/JwtClientAssertionDecoderFactory.java

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -88,12 +88,12 @@ public final class JwtClientAssertionDecoderFactory implements JwtDecoderFactory
8888
mappings.put(MacAlgorithm.HS512, "HmacSHA512");
8989
JCA_ALGORITHM_MAPPINGS = Collections.unmodifiableMap(mappings);
9090
}
91-
private static final RestTemplate DEFAULT_REST_TEMPLATE = new RestTemplate();
91+
private static final RestTemplate rest = new RestTemplate();
9292
static {
9393
SimpleClientHttpRequestFactory requestFactory = new SimpleClientHttpRequestFactory();
9494
requestFactory.setConnectTimeout(15_000);
9595
requestFactory.setReadTimeout(15_000);
96-
DEFAULT_REST_TEMPLATE.setRequestFactory(requestFactory);
96+
rest.setRequestFactory(requestFactory);
9797
}
9898
private final Map<String, JwtDecoder> jwtDecoders = new ConcurrentHashMap<>();
9999
private Function<RegisteredClient, OAuth2TokenValidator<Jwt>> jwtValidatorFactory = DEFAULT_JWT_VALIDATOR_FACTORY;
@@ -132,7 +132,7 @@ private static NimbusJwtDecoder buildDecoder(RegisteredClient registeredClient)
132132
JWT_CLIENT_AUTHENTICATION_ERROR_URI);
133133
throw new OAuth2AuthenticationException(oauth2Error);
134134
}
135-
return NimbusJwtDecoder.withJwkSetUri(jwkSetUrl).jwsAlgorithm((SignatureAlgorithm) jwsAlgorithm).restOperations(DEFAULT_REST_TEMPLATE).build();
135+
return NimbusJwtDecoder.withJwkSetUri(jwkSetUrl).jwsAlgorithm((SignatureAlgorithm) jwsAlgorithm).restOperations(rest).build();
136136
}
137137
if (jwsAlgorithm instanceof MacAlgorithm) {
138138
String clientSecret = registeredClient.getClientSecret();

0 commit comments

Comments
 (0)