0
votes

I have identityserver4-based identity server I have .net core api, which is successfully authorized using access_token from IS but, non-core webapi returns unauthorized requests for controllers marked with Authorize attribute

API startup class: public class Startup { public void Configuration(IAppBuilder app) {

        app.UseIdentityServerBearerTokenAuthentication(new IdentityServerBearerTokenAuthenticationOptions
        {
            Authority = "http://localhost:5000",
            ValidationMode = ValidationMode.Both,
           RequiredScopes = new[] { "ofd" },

        });


    }
}

what did I miss?

1

1 Answers

0
votes
<add key="owin:AutomaticStartup" value="true"/> 

was missed in web.config/appSettings, and owin middleware did not start