Skip to content

Commit 1bf85d1

Browse files
committed
Add missing ClientAuthenticationMethods to jackson2 converter
Closes spring-projectsgh-16825 Signed-off-by: Risto Virtanen <[email protected]>
1 parent 1f3dd53 commit 1bf85d1

File tree

1 file changed

+13
-1
lines changed
  • oauth2/oauth2-client/src/main/java/org/springframework/security/oauth2/client/jackson2

1 file changed

+13
-1
lines changed

oauth2/oauth2-client/src/main/java/org/springframework/security/oauth2/client/jackson2/StdConverters.java

+13-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2002-2022 the original author or authors.
2+
* Copyright 2002-2025 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -56,9 +56,21 @@ public ClientAuthenticationMethod convert(JsonNode jsonNode) {
5656
if (ClientAuthenticationMethod.CLIENT_SECRET_POST.getValue().equalsIgnoreCase(value)) {
5757
return ClientAuthenticationMethod.CLIENT_SECRET_POST;
5858
}
59+
if (ClientAuthenticationMethod.CLIENT_SECRET_JWT.getValue().equalsIgnoreCase(value)) {
60+
return ClientAuthenticationMethod.CLIENT_SECRET_JWT;
61+
}
62+
if (ClientAuthenticationMethod.PRIVATE_KEY_JWT.getValue().equalsIgnoreCase(value)) {
63+
return ClientAuthenticationMethod.PRIVATE_KEY_JWT;
64+
}
5965
if (ClientAuthenticationMethod.NONE.getValue().equalsIgnoreCase(value)) {
6066
return ClientAuthenticationMethod.NONE;
6167
}
68+
if (ClientAuthenticationMethod.TLS_CLIENT_AUTH.getValue().equalsIgnoreCase(value)) {
69+
return ClientAuthenticationMethod.TLS_CLIENT_AUTH;
70+
}
71+
if (ClientAuthenticationMethod.SELF_SIGNED_TLS_CLIENT_AUTH.getValue().equalsIgnoreCase(value)) {
72+
return ClientAuthenticationMethod.SELF_SIGNED_TLS_CLIENT_AUTH;
73+
}
6274
return null;
6375
}
6476

0 commit comments

Comments
 (0)