I an new to .NET MAUI and i am developing an App. But i don’t know where to start in implementing Authentification.
I have a ASP.NET Core WebApp running Identity already.
So What is the best approach to add Authentification in .NET MAUI development?
I have not tried anything
If you want to use your own web service for authentication, you can use WebAuthenticator to achieve it.
For more information, you can refer to: Web authenticator | Microsoft
Actually best thing is to implement custom authentication service so there won't be any limitation in future.
However, MAUI got "Microsoft.Identity.Web" package to help you out.
Microsoft has provided better guide here
https://learn.microsoft.com/en-us/azure/developer/mobile-apps/azure-mobile-apps/quickstarts/maui/authentication?pivots=vs2022-windows
Related
Can anyone help me to suggest a good architecture or Project setup for .net Core Web API Project?
How to handle dependency injection?
How to handle routing?
How to handle authentication?
How to do CRUD operations with the MS SQL server?
What are the best practices that should follow?
Sample project in git most preferred.
This question is really too general to answer in a prescriptive way, but Microsoft recommends using the Razor Pages approach for new ASP.NET Core web apps. This tutorial gives you a Razor quick-start, and touches on many of the concepts you asked about: https://learn.microsoft.com/en-us/aspnet/core/tutorials/razor-pages/razor-pages-start?view=aspnetcore-3.1&tabs=visual-studio
.NET Core also has a standardized dependency injection model: https://learn.microsoft.com/en-us/aspnet/core/fundamentals/dependency-injection?view=aspnetcore-3.1
As for authn/authz, there are some decisions for you to make about whether you trust other identity providers or manage users yourself, but this will give you a start. The related sections will get you the rest of the way toward almost any auth approach: https://learn.microsoft.com/en-us/aspnet/core/security/authentication/?view=aspnetcore-3.1
It's really strange question, but...
So, does any pure internal IdentityServer4 analogues in ASP.NET Core exist?
I have some Web Services via WebAPI. These services are strongly independent, but I want to restrict an access for part of it (I want to use JWTs).
I want to have one certification authority for all my apis, which could use ASP.NET Core Identity, of course, and grants of denys an access for specific api.
I don't want to use IdentityServer4 right now - maybe it's possible to solve this problem through an internal resourses of ASP.NET Core.
Thnxs.
Yes, ASP.NET Core provides out of the box tools for authentications and JWTs.
You will need to configure your Startup class and add the approperiate services/middlware.
Here's an article to get you started:
https://developer.okta.com/blog/2018/03/23/token-authentication-aspnetcore-complete-guide
If I'm not mistaken, IdentityServer actually wraps around these tools under the hood.
Im looking to create an Angular 4 app or possibly an Ionic app. The problem i face is im a bit unsure how to implement the authentication. i currenctly have an asp.net webforms site that uses the asp.net membership db. i would like to make use of this, but cant seem to find any relevant information on it. if anybody can shed any light on this or point me in the right direction it would be much appreciated. thanks in advance
You can add Web API to your .NET solution, which then utilizes the same business logic (including Authentication logic) you are using with your web forms. These APIs can then be consumed by your Angular/Ionic app via http and/or rxjs.
As we all know that Asp.net WEB API is not a good option to use when working with front end of a web application. And Bot Framework template is based on WEB API I'm developing a bot but I want to use mvc or .net core instead of web api.
can we do so ?
if yes what changes I have to make for that in other templates LIKE MVC or .NET Core?
Your question a little bit confusing.
ASP .NET Web API based on MVC. The connector client already support .NET Standard as far I know. .NET Core port is in progress but here is basic port from the main repo. Most of the stuff inside the bot builder uses simple API because, this a connector to your 3rd parties ( slack , skype etc ).
I need to use google accounts in my ASP.NET application. Did somebody do it? I have many questions about it
StackOverflow does it. Use the OAuth/OpenID libraries for .NET - DotNotOpenAuth.