Use entity name as CIMD client name

OAuth client_name should be the short brand
label, not the composed English hero heading.

Signed-off-by: Émile Ré <emile@probo.com>
This commit is contained in:
Émile Ré
2026-07-22 10:25:30 +02:00
parent cb4fb1f3f4
commit f1136cb748
2 changed files with 2 additions and 2 deletions

View File

@@ -85,7 +85,7 @@ func BuildClientMetadataDocument(
doc := oauth2.ClientMetadataDocument{
ClientID: clientID,
ClientName: "Compliance at " + portal.EntityName + ".",
ClientName: portal.EntityName,
ClientURI: portalRootURL,
RedirectURIs: []string{redirectURI},
TokenEndpointAuthMethod: "none",

View File

@@ -76,7 +76,7 @@ func TestBuildClientMetadataDocument(t *testing.T) {
)
require.NoError(t, err)
assert.Equal(t, "https://acme.example.com/.well-known/oauth-client-metadata", doc.ClientID)
assert.Equal(t, "Compliance at Acme.", doc.ClientName)
assert.Equal(t, "Acme", doc.ClientName)
assert.Equal(t, []string{"https://acme.example.com/callback"}, doc.RedirectURIs)
assert.Equal(t, "https://acme.example.com", doc.ClientURI)
assert.Equal(t, VisitorOAuthScope, doc.Scope)