Owin Katana with MVC - asp.net

As mention below statement from Article link how we can implement in MVC?
Katana allows you to build web based applications, such as MVC or Web API (2) where you can decide which web features to include in the project.
Article link

Katana is no longer being developed. According to their roadmap,
The next major version of Katana is part of the ASP.NET vNext project on GitHub
"ASP.NET vNext" is the early name for what is now ASP.NET Core. The architecture of ASP.NET Core continues (and improves on) the modular architecture that Katana used. You can build an ASP.NET Core MVC project using only the packages you need.
For further reading, check out my answers to Is Owin/Katana supposed to replace Web API? and Does ASP.NET Core still use OWIN?

Related

which version of mvc is using in asp.net core 2.0? is is MVC 6 or use different name?

which version of mvc is using in asp.net core 2.0? is is MVC 6 or use different name ?
What is .net 5?
what is .net standard ?
these questions are from an interview.plz help
The .NET Standard is a formal specification of .NET APIs that are intended to be available on all .NET implementations.https://learn.microsoft.com/en-us/dotnet/standard/net-standard .ASP.NET5.0 Is Called ASP.NET Core 1.0 and In the ASP.NET Core 1.0 release, Web API is merged with ASP.NET MVC, termed as MVC 6
They're totally unrelated. "MVC 6" was sort of like a codename for Core when it was still in early stages. ASP.NET MVC and ASP.NET Web Api are totally separate from ASP.NET Core. Now, it's just "Core". There is no "MVC" or "Web Api", because Core controllers do both functions. ASP.NET MVC and ASP.NET Web Api live on and although they will probably eventually be deprecated, they could presumably (though not likely at all) get new releases. At the very least, they'll be patched for the foreseeable future.
ASP.NET Core is a complete rewrite from the ground up. It was originally created simply to be a cross-platform alternative to ASP.NET, and I think the original plan was to keep both ASP.NET and ASP.NET Core as potential development options. However, as ASP.NET Core became more competent, it has pretty fully eclipsed ASP.NET; we now have a cross-platform framework that can run on Windows, Mac and Linux and can do virtually anything the Windows-only framework can. Therefore, why keep the Windows-only framework?
Asp.net Core 2.0 is MVC 6 and The framework is 4.6.1
To start with development you need to have VS-2017 and for 1.X you can start with VS-2015.
Please refer the below link for clear presentation of .NetCore 2.0 so that you can get good knowledge to kick start your development.
Official Asp.Net Core Documentation Url

Asp.net web form migration to dot net core

I have an application in asp.net 2.0 web forms.
I want to migrate it to Asp.net core web forms.
Is it feasible?
I did not see any link on internet for migration of web forms.
Please provide any link or insight for this.
ASP.NET Core doesn't have a web forms part. It's an old model and won't be includeded in the ASP.NET Core according to Microsoft. The new and recommended model is MVC. There is no interoperability between them, because they have a differt architechture and behavior.
You have two opportunities. First: you don't migrate, everything will work as it has been. Second: you re-implement your solution with ASP.NET Core and with MVC architecture.
Have you seen DotVVM?
It is not Web Forms on .NET Core, but:
many concepts in DotVVM are similar to ASP.NET Web Forms (postbacks, server controls, master pages, even the names of the controls and page lifecycle events)
it is easy to learn for ASP.NET Web Forms developers
no cryptic viewstate hidden field
the controls don't produce ugly HTML
the MVVM pattern is used
no need to know or write JavaScript - C#, HTML and CSS is enough to start coding
DotVVM supports both .NET Core and full .NET Framework
can be added to existing ASP.NET Web Forms or MVC applications on .NET Framework
DotVVM is open source
Visual Studio extension with IntelliSense and project templates
Disclaimer: taken from https://github.com/aspnet/Home/issues/1961#issuecomment-323698018
There are some useful resources I'd like to share with the StackOverflow community just in case you are having troubles to decide what to do:
modernization of your existing Web Forms app
migration to MVC or Core
or whether to start a new project on Web Forms, MVC and Core.
Here you go:
Modernizing ASP.NET Web Forms Applications by Tomáš Herceg (Microsoft MVP ) - https://tomasherceg.com/blog/post/modernizing-asp-net-web-forms-applications-part-1
Migrating Old ASP.NET Applications to .NET Core by Edi Wang (Microsoft MVP) - https://edi.wang/post/2018/10/31/migrating-old-aspnet-applications-to-net-core
Choose between ASP.NET and ASP.NET Core (Microsoft docs) - https://learn.microsoft.com/en-us/aspnet/core/fundamentals/choose-aspnet-framework?view=aspnetcore-3.1 - https://learn.microsoft.com/en-us/aspnet/core/migration/proper-to-2x/?view=aspnetcore-3.1
Migrate from ASP.NET to ASP.NET Core (Microsoft docs) - https://learn.microsoft.com/en-us/aspnet/core/migration/proper-to-2x/?view=aspnetcore-3.1
https://www.telerik.com/blogs/review-of-telerik-toolsets-for-aspnet-web-forms-core

Ws-Federation authentication with ASP.NET Core

I am migrating an ASP.NET application to be on ASP.NET Core, but have met a problem of Ws-Federation authentication: there is no [Ws-Federation] (https://www.nuget.org/packages?q=Microsoft.Owin.Security.WsFederation) OWIN middleware available in ASP.NET Core platform.
But I noticed all authentication middleware for ASP.NET Core are now under Microsoft.AspNetCore.Authentication namespace, so I searched all packages from nuget.org and found most of the authentication packages are there, but unfortunately only the Microsoft.AspNetCore.Authentication.WsFederation is missing.
So, I would like to know, if the package is missing because it is not implemented yet or any other reason? Alternatively, is there existing ASP.NET Core based authentication middleware for Ws-Federation?
It's not implemented yet, mainly because .NET Core doesn't have the encrypted XML and XML dsig classes needed.
See https://github.com/AzureAD/azure-activedirectory-identitymodel-extensions-for-dotnet/issues/500
I've ported the Katana middleware over to ASP.NET Core. It has a hard dependency on the full .NET Framework since that is the only place the required libraries exist right now.
https://github.com/chrisdrobison/aspnetcore-wsfed
It appears .NET Core 2.1 WS Federation package is now available. Microsoft.AspNetCore.Authentication.WsFederation.
More information found at the following link:
https://learn.microsoft.com/en-us/aspnet/core/security/authentication/ws-federation?view=aspnetcore-2.1

HelpPage for ASP.NET vNext MVC 6 Web Api

I am currently checking out asp.net vnext MVC6 in Visual Studio 2015 Preview. I'm pretty new to asp.net in general, but within my company we are going to move towards creating a web api using asp.net for accessing data on our server (currently we only support wcf communication with our own silverlight application). This is the reason I am checking out the new functionalities of MVC 6 to judge whether we should wait before starting our development and use MVC 6 when it is finally released or start development now and create a Web API 2 project.
Anyway, I am looking into auto documenting the web api, which is already integrated into the Visual Studio template for a WebApi 2 project by use of Microsoft.AspNet.WebApi.HelpPage.
Now for my question, is something like this available for MVC 6 aswell? I can import the same package in my project.json in my ASP.NET vNext / MVC6 (whatever you want to call it) project but i can't do app.UseHelpPage(); in my Startup.cs file.
I suspect this is not (yet) integrated in the current release yet. If not, is there anything known about integration of this feature once ASP.NET vNext eventually hits the shelves?
Probably this feature is not available in MVC 6 yet, but you could try Swagger.
Swagger basically is a framework for describing, consuming, and visualizing RESTful APIs.
The nice thing about Swashbuckle that it has no dependency on ASP.NET MVC, so there is no need to include any MVC Nuget packages in order to enable API documentation, as well Swashbuckle contains an embedded version of swagger-ui which will automatically serve up once Swashbuckle is installed.
Source: http://bitoftech.net/2014/08/25/asp-net-web-api-documentation-using-swagger/

What is ASP.NET vNext?

Can anybody tell me what is ASP.NET vNext?
Every new version on .Net is something like .NET 1.0, .NET 2.0, .NET 3.0, .NET 3.5, .NET 4.0 then why this version is not something like ASP.NET 6.0?
vNext is just the name given to product in the pre-release mode, like c# vNext which will apparently be released as C# 6.0, maybe ASP.NET vNext will have a numbering when it releases.
What is ASP.NET vNext?
Microsoft ASP.NET vNext is a smaller and efficient framework as a result of rebuilding the libraries from ground up.
What's new in vNext
Cloud-optimized versions of MVC, Web API, Web Pages, SignalR, and Entity Framework.
MVC, Web API, and Web Pages will be merged into one framework, called MVC 6.
MVC 6 has no dependency on System.Web. The result is a leaner framework, with faster startup time and lower memory consumption.
vNext is host agnostic. You can host your app in IIS, or self-host in a custom process.
Dependency injection is built into the framework. Use your preferred IoC container to register dependencies.
vNext uses the Roslyn compiler to compile code dynamically. You will be able to edit a code file, refresh the browser, and see the changes without rebuilding the project.
vNext is open source and cross platform.
More information:
Overview on asp.net
Getting started with ASP.NET vNext
Blogpost by Scott Hanselman
Blogpost by David Fowler
Contributing to ASP.NET vNext
Sample ASP.NET vNext applications
ASP.NET vNext is the next version of ASP.NET, but it hasn't shipped yet, so it is not an official version. "vNext" is just a working title.
ASP.NET vNext was the code-name for the next generation of ASP.NET, whose official name is ASP.NET 5. As of now ASP.NET 5 is not yet finished and documentation about can be found at http://asp.net/vnext.
ASP.NET 5 is not just an evolution of the previous version(s), it is rebuilt from the ground. Existing ASP.NET applications will run on ASP.NET 5 without modifications, but to take advantage of the new features, such applications will have to be ported to the new version.
Here's a little excerpt of what http://asp.net has to say about ASP.NET 5:
ASP.NET 5 is a lean .NET stack for building modern web apps. We built it from the ground up to provide an optimized development framework for apps that are either deployed to the cloud or run on-premises. It consists of modular components with minimal overhead, so you retain flexibility while constructing your solutions.
ASP.NET 5 includes the following features:
New flexible and cross-platform runtime
New modular HTTP request pipeline
Cloud-ready environment configuration
Unified programming model that combines MVC, Web API, and Web Pages
Ability to see changes without re-building the project
Side-by-side versioning of the .NET Framework
Ability to self-host or host on IIS
New tools in Visual Studio 2015
Open source in GitHub
The changes we made for ASP.NET 5 were based on customer requests and feedback. These changes simplify development, hosting, and maintenance, and are targeted to modern web apps.
Your legacy apps will run on the new version of the ASP.NET without any modifications. However, to take advantage of the new features in ASP.NET 5, you will need to port your existing code to the new framework. You will find many similarities between ASP.NET 5 and earlier versions of ASP.NET, so porting code involves fixing particular issues rather than re-writing the app.

Resources