ITFOXTEC SAML2 CORE example will not compile

Viewed 28

I am trying to build your sample. I’ve removed all the projects down to the Test Web App Core and have added the latest SAML 2 and SAML 2 MVC packages from NuGet. I am getting a compiler error (see below). Services.BindConfig does not exist.

Any help would be appreciated.

......

namespace TestWebAppCore { public class Startup { public static IWebHostEnvironment AppEnvironment { get; private set; }

    public Startup(IWebHostEnvironment env, IConfiguration configuration)
    {
        AppEnvironment = env;
        Configuration = configuration;
    }

    public IConfiguration Configuration { get; }

    public void ConfigureServices(IServiceCollection services)
    {
        **services.BindConfig**<Saml2Configuration>(Configuration, "Saml2", (serviceProvider, saml2Configuration) =>
        {
            

I've downloaded the ITFOXTEC SAML2 example project from github and am trying to get it to work

EDIT: I do have the appropriate package & includes.

[![enter image description here][1]][1]


  [1]: https://i.stack.imgur.com/T4zKu.png
1 Answers

The problem occur because you are using the wrong SAML 2 MVC package, you need to use the ITfoxtec.Identity.Saml2.MvcCore package. And add a using statement for the namespace ITfoxtec.Identity.Saml2.MvcCore.

Related