A few months ago I created a small web application in ASP.NET MVC, I got it to work with Azure AD Authentication, now I need to strip the application of the Azure part and have it run without the user needing to login, I have commented or removed all the stuff that is added according to this link:
https://learn.microsoft.com/en-us/azure/active-directory/develop/vs-active-directory-dotnet-what-happened
But the application stills fails with
You do not have permission to view this directory or page
when loading my Home/Index.cshtml page
Thanks!
Related
I have a ASP.net MVC project hosted in Azure and with Azure AD authentication
Everything works fine when I publish my project, but after a while when trying to login again, I get the famous login loop.
If I restart the app service, everything works fine for a while again...
I have read many posts and blogs regarding this subject and I think I have tried evertything.
Reply url and keys are correct both in Azure and web.config
Applicaton is forced to https
I have tryed the katana cookiesaver fix.
Reply url other than root
Other suggestions?
I have an existing MVC application that authenticates users using their Google, Facebook or Microsoft (live) accounts. The application is derived from the basic MVC template, and the 'Individual Accounts' option was chosen. This all works fine.
We have had a request/requirement that we also support Microsoft Work Accounts, authenticated against Azure AD. We have developed a second test MVC application, using the 'Organisational Accounts' from the template and can successfully get the user details, including extended details such as Manager and Office from AD.
However we are struggling to understand how to combine the two options, and still get the extended details. We've added a OpenIdConnect option in the Startup.Auth file, pointing to AAD and they works, getting hold of the users main login only. We are struggling to then use that email to obtain the user's full information
I'm new on ASPNet MVC 5, I'm confused about IISExpress. I am developing intranet site and I use windows authentication. After publish and run site on IIS I saw that authentication pop-up which not came on IISExpress. Why there is something like this? After searched about preventing that pop-up I saw that I have to add site to trusted website, however, I didn't do this for IISExpress, did IISExpress do it for me automatically? In addition to this I have a problem about EWS Managed API on IIS
IIS Express is a process that runs in the context of the currently logged on user, meaning you. Your account usually has enough (or too much) permissions to access files and other resources.
The 'big' IIS uses different user accounts to run your application, these accounts have limited permissions and may not have access to files and resources. If IIS can't access a file with its normal process account, it needs a different account to access that file and asks for one in a popup.
I'm using Facebook Application Template, The template is creating canvas application, and i want a regular one with just Facebook authentication,
if i'm canceling the "App of Facebook" i get an error "Sorry, the application you were using is misconfigured. Please try again later.".
How can i get the Facebook application work with mvc 4.5 template but as regular app and not canvas.
The Facebook Application Template is designed as a Canvas application, which is not what you're looking for.
Fortunately, the ASP.NET team built a number of alternative authentication providers into the default ASP.NET Internet Application template.
Fire up VS, and create a new MVC 4 Internet Application project. Open AuthConfig.cs, uncomment the 3 Facebook lines, and paste in your application details (get these from the Facebook developers center). Now, your application will support both local authentication (username/password) and Facebook Authentication!
For a full tutorial: http://www.asp.net/mvc/overview/getting-started/using-oauth-providers-with-mvc
Currently, the ASP.NET Facebook Template is only for Canvas Applications. We are planning to support web applications either with the same template or a new template at a later time. For now, you can see a sample ASP.NET web app here: https://github.com/facebook-csharp-sdk/facebook-aspnet-sample. It is a bit dated (MVC3), but it should help you get started.
My ASP.Net MVC3 web site that logs into Facebook is no longer working after moving to an Azure based cloud project. I am using the Azure SDK 1.6 and fail during the the OAuth steps.
I had a working site that ran locally at http://localhost:1200 which matched the Application Url setting that was registered for the application on Facebook. Now when I try to start the project in debug mode, it goes through the Azure emulator which maps the web site (role) to http://127.0.0.1:82/. I've tried updating the Facebook app url to the same address but it fails.
I've been investigating this and I've noticed that the Azure emulator automatically creates on the fly a new IIS web site and employs a load balancer for its created virtual IPs for the individual projects within the cloud solution. Is there a way to get a project to debug successfully and still talk to Facebook when running the Azure emulator within Visual Studio?
Any insight is greatly appreciated.
I would not use localhost for Facebook applications.
What I did, I had registered my real domain in Facebook (such as myapp.com)
Then I created a record in my hosts file (Windows\system32\drivers\etc\hosts)
127.0.0.1 dev.myapp.com
which is sub-domain of my production domain, so it's allowed by FB;
And then I used dev.myapp.com as callback address for Facebook; I also setup Visual Studio to run http://dev.myapp.com:anyport on start application debugging.