chore(sso): logs related to grant types (#4806)

This commit is contained in:
Chuck Driesler
2025-05-23 15:49:27 +01:00
committed by GitHub
parent e612886fd8
commit 22c596e985
@@ -38,27 +38,30 @@ import {
getEmailFromOidcProfile,
isValidSsoSession
} from '@/modules/workspaces/domain/sso/logic'
import type { Logger } from '@/observability/logging'
import { logger, type Logger } from '@/observability/logging'
// this probably should go a lean validation endpoint too
const validateOidcProviderAttributes = ({
// client,
issuer
}: OidcProviderAttributes): void => {
if (!issuer.grantTypesSupported.includes('authorization_code'))
// Validate issuer
if (!issuer.grantTypesSupported.includes('authorization_code')) {
logger.info(
{
supportedGrantTypes: issuer.grantTypesSupported
},
'OIDC provider does not support required grant types.'
)
throw new OidcProviderMissingGrantTypeError()
/*
validate issuer:
authorization_signing_alg_values_supported
claims_supported: ['email', 'name', 'given_name', 'family_name']
scopes_supported: ['openid', 'profile', 'email']
grant_types_supported: ['authorization_code']
response_types_supported: //TODO figure out which
}
// authorization_signing_alg_values_supported
// claims_supported: ['email', 'name', 'given_name', 'family_name']
// scopes_supported: ['openid', 'profile', 'email']
// response_types_supported: //TODO figure out which
validate client:
grant_types: ['authorization_code'],
*/
// Validate client
// grant_types: ['authorization_code']
}
/**