Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Rename OpenIddictConfiguration.JwksUri to JsonWebKeySetUri for consistency with the recent changes #2193

Merged
merged 1 commit into from
Oct 2, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -72,9 +72,9 @@ public sealed class OpenIddictConfiguration
public JsonWebKeySet? JsonWebKeySet { get; set; }

/// <summary>
/// Gets or sets the URI of the JSON Web Key Set endpoint.
/// Gets or sets the URI of the JSON Web Key Set.
/// </summary>
public Uri? JwksUri { get; set; }
public Uri? JsonWebKeySetUri { get; set; }

/// <summary>
/// Gets or sets the URI of the mTLS-enabled device authorization endpoint.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -426,7 +426,7 @@ public ValueTask HandleAsync(HandleConfigurationResponseContext context)
{
context.Configuration.AuthorizationEndpoint =
new Uri("https://www.sandbox.paypal.com/signin/authorize", UriKind.Absolute);
context.Configuration.JwksUri =
context.Configuration.JsonWebKeySetUri =
new Uri("https://api-m.sandbox.paypal.com/v1/oauth2/certs", UriKind.Absolute);
context.Configuration.RevocationEndpoint =
new Uri("https://api-m.sandbox.paypal.com/v1/oauth2/revoke", UriKind.Absolute);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -345,7 +345,7 @@ public ValueTask HandleAsync(HandleConfigurationResponseContext context)
return default;
}

context.Configuration.JwksUri = uri;
context.Configuration.JsonWebKeySetUri = uri;

return default;
}
Expand Down
4 changes: 2 additions & 2 deletions src/OpenIddict.Client/OpenIddictClientRetriever.cs
Original file line number Diff line number Diff line change
Expand Up @@ -54,12 +54,12 @@ async Task<OpenIddictConfiguration> IConfigurationRetriever<OpenIddictConfigurat
var configuration = await _service.GetConfigurationAsync(_registration, uri, cancel) ??
throw new InvalidOperationException(SR.GetResourceString(SR.ID0145));

if (configuration.JwksUri is null)
if (configuration.JsonWebKeySetUri is null)
{
throw new InvalidOperationException(SR.GetResourceString(SR.ID0146));
}

configuration.JsonWebKeySet = await _service.GetSecurityKeysAsync(_registration, configuration.JwksUri, cancel) ??
configuration.JsonWebKeySet = await _service.GetSecurityKeysAsync(_registration, configuration.JsonWebKeySetUri, cancel) ??
throw new InvalidOperationException(SR.GetResourceString(SR.ID0147));

// Copy the signing keys found in the JSON Web Key Set to the SigningKeys collection.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -257,7 +257,7 @@ public ValueTask HandleAsync(HandleConfigurationResponseContext context)
return default;
}

context.Configuration.JwksUri = uri;
context.Configuration.JsonWebKeySetUri = uri;

return default;
}
Expand Down
4 changes: 2 additions & 2 deletions src/OpenIddict.Validation/OpenIddictValidationRetriever.cs
Original file line number Diff line number Diff line change
Expand Up @@ -48,12 +48,12 @@ async Task<OpenIddictConfiguration> IConfigurationRetriever<OpenIddictConfigurat
var configuration = await _service.GetConfigurationAsync(uri, cancel) ??
throw new InvalidOperationException(SR.GetResourceString(SR.ID0145));

if (configuration.JwksUri is null)
if (configuration.JsonWebKeySetUri is null)
{
throw new InvalidOperationException(SR.GetResourceString(SR.ID0146));
}

configuration.JsonWebKeySet = await _service.GetSecurityKeysAsync(configuration.JwksUri, cancel) ??
configuration.JsonWebKeySet = await _service.GetSecurityKeysAsync(configuration.JsonWebKeySetUri, cancel) ??
throw new InvalidOperationException(SR.GetResourceString(SR.ID0147));

// Copy the signing keys found in the JSON Web Key Set to the SigningKeys collection.
Expand Down