Handled scopes & added request token with authorization code tests.
Change-Id: I775141b8b94bf2d1c86ad873807fcb1b12f3914f
diff --git a/full/src/main/resources/db/insert/V3.5__insert_oauth2_clients.sql b/full/src/main/resources/db/insert/V3.5__insert_oauth2_clients.sql
index f9cd171..b42ae28 100644
--- a/full/src/main/resources/db/insert/V3.5__insert_oauth2_clients.sql
+++ b/full/src/main/resources/db/insert/V3.5__insert_oauth2_clients.sql
@@ -10,7 +10,7 @@
"This is a test native confidential client.");
-- plain secret value is "secret"
-INSERT INTO oauth2_client(id,name,secret,type,native, url,url_hashcode,
+INSERT INTO oauth2_client(id,name,secret,type,native,url,url_hashcode,
redirect_uri,registered_by, description)
VALUES ("9aHsGW6QflV13ixNpez","test non native confidential client",
"$2a$08$vi1FbuN3p6GcI1tSxMAoeuIYL8Yw3j6A8wJthaN8ZboVnrQaTwLPq",
@@ -18,10 +18,10 @@
"https://third.party.com/confidential/redirect", "system",
"This is a test nonnative confidential client.");
-INSERT INTO oauth2_client(id,name,secret,type,url,url_hashcode,
+INSERT INTO oauth2_client(id,name,secret,type,native,url,url_hashcode,
redirect_uri, registered_by, description)
VALUES ("8bIDtZnH6NvRkW2Fq","third party client",null,
- "PUBLIC","http://third.party.client.com", -2137275617,
+ "PUBLIC", 0,"http://third.party.client.com", -2137275617,
"https://third.party.client.com/redirect","system",
"This is a test nonnative public client.");
diff --git a/full/src/main/resources/kustvakt.conf b/full/src/main/resources/kustvakt.conf
index 99e3b94..75a3483 100644
--- a/full/src/main/resources/kustvakt.conf
+++ b/full/src/main/resources/kustvakt.conf
@@ -47,6 +47,11 @@
### (see de.ids_mannheim.korap.constant.AuthenticationMethod for possible
### oauth.password.authentication values)
oauth.password.authentication = TEST
+oauth2.native.client.host = korap.ids-mannheim.de
+oauth2.max.attempts = 3
+# -- scopes separated by space
+oauth2.default.scopes = read_username read_email
+oauth2.client.credentials.scopes = read_client_info
# JWT
security.jwt.issuer=korap.ids-mannheim.de