Update resource server samples

Closes gh-28
This commit is contained in:
Steve Riesenberg
2021-08-17 13:54:19 -05:00
committed by Steve Riesenberg
parent bf1ca80a0a
commit 6548ff0876
7 changed files with 215 additions and 15 deletions

View File

@@ -24,6 +24,7 @@ import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.boot.test.autoconfigure.web.reactive.AutoConfigureWebTestClient;
import org.springframework.boot.test.context.SpringBootTest;
import org.springframework.http.HttpHeaders;
import org.springframework.test.context.ActiveProfiles;
import org.springframework.test.web.reactive.server.WebTestClient;
import static org.hamcrest.Matchers.containsString;
@@ -36,6 +37,7 @@ import static org.hamcrest.Matchers.containsString;
*/
@SpringBootTest
@AutoConfigureWebTestClient
@ActiveProfiles("test")
public class ServerOAuth2ResourceServerApplicationITests {
Consumer<HttpHeaders> noScopesToken = (http) -> http.setBearerAuth(

View File

@@ -0,0 +1,6 @@
spring:
security:
oauth2:
resourceserver:
jwt:
jwk-set-uri: ${mockwebserver.url}/.well-known/jwks.json

View File

@@ -3,4 +3,4 @@ spring:
oauth2:
resourceserver:
jwt:
jwk-set-uri: ${mockwebserver.url}/.well-known/jwks.json
jwk-set-uri: http://localhost:9000/oauth2/jwks