OpenIDConnectEvents not fireing (specificaly OnUserInformationReceived, OnTicketReceived)

I am having an issue with the OpenIDConnect events not firing.
I am using the Microsoft.AspNetCore.Authentication.OpenIdConnect nuget package and everything is configured properly.

User is logged in and I am able to verify they are authenticated and claims are returned, but the specific events never get triggered (or at least they do not get hit with a breakpoint for debugging purposes)

I have a very similar configuration set up with Dell’s SSO product and the events fire as expected so I am at a loss for what the issue is.

snippet of the code:

            o.GetClaimsFromUserInfoEndpoint = true;
            o.Configuration = new OpenIdConnectConfiguration
                AuthorizationEndpoint = Configuration["AppSettings:Auth0AuthorizationEndpoint"],      
                UserInfoEndpoint = Configuration["AppSettings:Auth0UserInfoEndpoint"],                   
            o.Events = new OpenIdConnectEvents()
               OnUserInformationReceived = context =>
                    var identity = (ClaimsIdentity)context.Principal.Identity;

                    foreach (var a in context.User)
                       //code has been removed
                    return Task.CompletedTask;
                OnTicketReceived = context =>
                      //code has been removed
                        return Task.FromResult(0);

I have since added the additional configuration options for the authorization and userinfo endpoints with the assumption that I would need that to kick off the event for OnUserInformation received.

However, when adding those options I get an additional error after authentication:
InvalidOperationException: An invalid request URI was provided. The request URI must either be an absolute URI or BaseAddress must be set.

So i am officially at a total loss as to how to get this event to fire.

Hey there @joanna.romeo, welcome to the Auth0 Community!

I apologize for the delay in response and am currently trying to track down what may be going on here. Thanks!

After looking into this a bit, I would recommend double checking the request URI to make sure it is the full URL that you anticipate leveraging as set in your auth0 dashboard. Can you direct message me your tenant name and a HAR file capture of the workflow so I can continue taking a look at what may be occurring?

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.