You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
if (metaDataFields.get("refreshTokenValidity") != null && grants.stream().noneMatch(grant -> grant.equals("refresh_token"))) {
59
62
thrownewValidationException(schema, "refreshTokenValidity specified, but no refresh_token grant. Either remove refreshTokenValidity or add refresh_token grant type", "refreshTokenValidity");
60
63
}
64
+
if (isPublicClient && StringUtils.hasText(secret)) {
65
+
thrownewValidationException(schema, "Public clients are not allowed a secret", "isPublicClient");
66
+
}
67
+
if (!isPublicClient && !StringUtils.hasText(secret)) {
68
+
thrownewValidationException(schema, "Non-public clients are required a secret", "secret");
69
+
}
70
+
if (grants.size() == 1 && grants.get(0).equals("urn:ietf:params:oauth:grant-type:device_code") && StringUtils.hasText(secret)) {
71
+
thrownewValidationException(schema, "Device Code RP is not allowed a secret", "redirectUris");
0 commit comments