Skip to content

Update all built-in AuthenticationSchemeOptions to initialize Events #62595

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

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
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 @@ -10,6 +10,14 @@ namespace Microsoft.AspNetCore.Authentication.Certificate;
/// </summary>
public class CertificateAuthenticationOptions : AuthenticationSchemeOptions
{
/// <summary>
/// Initializes a new instance of <see cref="CertificateAuthenticationOptions"/>.
/// </summary>
public CertificateAuthenticationOptions()
{
Events = new CertificateAuthenticationEvents();
}

/// <summary>
/// Value indicating the types of certificates accepted by the authentication middleware.
/// </summary>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ public JwtBearerOptions()
SecurityTokenValidators = new List<ISecurityTokenValidator> { _defaultHandler };
#pragma warning restore CS0618 // Type or member is obsolete
TokenHandlers = new List<TokenHandler> { _defaultTokenHandler };
Events = new JwtBearerEvents();
}

/// <summary>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,14 @@ namespace Microsoft.AspNetCore.Authentication.Negotiate;
/// </summary>
public class NegotiateOptions : AuthenticationSchemeOptions
{
/// <summary>
/// Initializes a new instance of <see cref="NegotiateOptions"/>.
/// </summary>
public NegotiateOptions()
{
Events = new NegotiateEvents();
}

/// <summary>
/// The object provided by the application to process events raised by the negotiate authentication handler.
/// The application may use the existing NegotiateEvents instance and assign delegates only to the events it
Expand Down
Loading