title: No authenticationScheme was specified, and there was no DefaultChallengeScheme found - ASP.NET core 2.1
body: <p>I'm working with ASP.NET Core 2.1 WebApi project, in that we've used token based authentication</p>
  
  <pre><code>public class UserIdentityFilter : IAuthorizationFilter
  {    
      public void OnAuthorization(AuthorizationFilterContext context)
      {
          StringValues authorizationHeaders;
          if (!context.HttpContext.Request.Headers.TryGetValue("Authorization", out authorizationHeaders))
              return;
          ...
          ...
      }   
  }
  </code></pre>
  
  <p>And having middleware for error handling:</p>
  
  <pre><code>public async Task Invoke(HttpContext context, ILogger logger, IAppConfiguration appConfiguration)
  {            
      try
      {
          await _next(context);
      }
      catch (Exception ex)
      {               
          await HandleExceptionAsync(context, ex, logger, appConfiguration);
      }
  }  
  </code></pre>
  
  <p>It's working fine if I pass header for authorize method, however missing header for the same gives an error <code>No authenticationScheme was specified, and there was no DefaultChallengeScheme found.</code></p>
  
  <p>Here I have two questions: </p>
  
  <p>1) It is okay to send 500 with this exception to user end, when header not specified? </p>
  
  <p>2) How to handle this scenario and passing meaningful message "header is missing " or something?  </p>