Several months ago I created an ASP.NET MVC project and I created it with the default authentification option: "Individual User Account", not on purpose.
My project runs well now but I don't need any authentification methods and so I don't need the Identity and OWIN packages.
Is there a clean way to delete all of those? Those packages are not needed by any other features right?
Thx!
To disable OWIN startup discovery add the appSetting owin:AutomaticAppStartup with a value of "false" in the web. config file.
OWIN includes middleware components for authentication, including support for log-ins using external identity providers (like Microsoft Accounts, Facebook, Google, Twitter), and log-ins using organizational accounts from on-premises Active Directory or Azure Active Directory.
It is simple just some uninstalling an removing some files. First uninstall following package in package manage console:
PM> uninstall-Package Microsoft.Owin.Security.Facebook
PM> uninstall-Package Microsoft.Owin.Security.Google
PM> uninstall-Package Microsoft.Owin.Security.MicrosoftAccount
PM> uninstall-Package Microsoft.Owin.Security.Twitter
PM> uninstall-Package Microsoft.Owin.Host.SystemWeb
PM> uninstall-Package Microsoft.AspNet.Identity.EntityFramework
PM> uninstall-Package Microsoft.AspNet.Identity.Owin
If everything goes right your project must clean up with following packeges:
Microsoft.AspNet.Identity.Core
Microsoft.AspNet.Identity.EntityFramework
Microsoft.AspNet.Identity.Owin
Microsoft.Owin
Microsoft.Owin.Host.SystemWeb
Microsoft.Owin.Security
Microsoft.Owin.Security.Cookies
Microsoft.Owin.Security.Facebook
Microsoft.Owin.Security.Google
Microsoft.Owin.Security.MicrosoftAccount
Microsoft.Owin.Security.OAuth
Microsoft.Owin.Security.Twitter
Owin
So if anyone still exist simply uninstall them also.
Now you could remove following files from your project:
App_Start\IdentityConfig.cs
App_Start\Startup.Auth.cs
Models\IdentityModels.cs
Startup.cs
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With