File tree Expand file tree Collapse file tree 1 file changed +27
-0
lines changed
config/src/main/java/org/springframework/security/config/web/server Expand file tree Collapse file tree 1 file changed +27
-0
lines changed Original file line number Diff line number Diff line change @@ -1121,6 +1121,23 @@ private ReactiveOAuth2AuthorizedClientService getAuthorizedClientService() {
1121
1121
private OAuth2ClientSpec () {}
1122
1122
}
1123
1123
1124
+ /**
1125
+ * Configures OAuth 2.0 Resource Server support.
1126
+ *
1127
+ * <pre class="code">
1128
+ * @Bean
1129
+ * public SecurityWebFilterChain springSecurityFilterChain(ServerHttpSecurity http) {
1130
+ * http
1131
+ * // ...
1132
+ * .oauth2ResourceServer()
1133
+ * .jwt()
1134
+ * .publicKey(publicKey());
1135
+ * return http.build();
1136
+ * }
1137
+ * </pre>
1138
+ *
1139
+ * @return the {@link OAuth2ResourceServerSpec} to customize
1140
+ */
1124
1141
public OAuth2ResourceServerSpec oauth2ResourceServer () {
1125
1142
if (this .resourceServer == null ) {
1126
1143
this .resourceServer = new OAuth2ResourceServerSpec ();
@@ -1199,13 +1216,23 @@ public OAuth2ResourceServerSpec authenticationManagerResolver(
1199
1216
return this ;
1200
1217
}
1201
1218
1219
+ /**
1220
+ * Enables JWT Resource Server support.
1221
+ *
1222
+ * @return the {@link JwtSpec} for additional configuration
1223
+ */
1202
1224
public JwtSpec jwt () {
1203
1225
if (this .jwt == null ) {
1204
1226
this .jwt = new JwtSpec ();
1205
1227
}
1206
1228
return this .jwt ;
1207
1229
}
1208
1230
1231
+ /**
1232
+ * Enables Opaque Token Resource Server support.
1233
+ *
1234
+ * @return the {@link OpaqueTokenSpec} for additional configuration
1235
+ */
1209
1236
public OpaqueTokenSpec opaqueToken () {
1210
1237
if (this .opaqueToken == null ) {
1211
1238
this .opaqueToken = new OpaqueTokenSpec ();
You can’t perform that action at this time.
0 commit comments