Authentication not working in MVC3 - asp.net-mvc-3

I am working on a Facebook canvas application. I created a sample project using the latest ASP.net MVC3 RC2, and use the exactly same settings as provided in the sample (MVC2). But it's not working. After a user clicks Allow to grant the permission, there are an unending redirects between the site and Facebook. Does anybody have experience on this problem? Any workaround for this issue?

I had the same issue in web forms application. But the error resolved after setting Site URL under Website tab (in facebook app registration settings) to Canvas URL (under facebook integration settings).

The error is solved by the Facebook C# SDK...

Related

ADFS 4 -'X-Frame-Options' to 'deny'

I have an aspx page embedded in Dynamics CRM. The aspx page uses openId and an adfs application group to authenticate and has been working up until security update KB4493473 (it is an assumption that the update is causing the issue). Prior to the update, when the user loaded the CRM form, the iframe would seamlessly load without issue or authentication prompts.
Since the update, the console gives this message: 'https://sts...... &x-client-SKU=ID_NET451&x-client-ver=5.2.1.0' in a frame because it set 'X-Frame-Options' to 'deny'.
I have not found any way to have adfs NOT send that x-frame header, is there any workaround here?
We had a similar problem since some week on a project I work on (iFrame integration not working any more because of ADFS, apparently since May Windows cumulative update has been installed)
Luckily, a colleague found a workaround with this ADFS PowerShell command :
Set-AdfsResponseHeaders -RemoveHeaders "X-Frame-Options"
This command is documented for ADFS 2019 (but works on ADFS 4 too) : https://learn.microsoft.com/fr-fr/windows-server/identity/ad-fs/operations/customize-http-security-headers-ad-fs
Hope this will help.
Regards,

Okta social authentication with angular and spring

I have downloaded that example:
https://github.com/mraible/okta-spring-boot-angular-example
it works fine but I have no clue how to to authenticate with facebook or microsoft account? Is there any working example with that identity providers or can someone tell me what to do?
I have found example at okta website how to configure that in dashboard and at microsoft developer account but I don't know how to redirect from my webpage to site where I can sign in using microsoft account not okta account.
Thanks in advance
Once you configure IDP using this. At the end, they give you options for integration. For example, if you are looking to integrate Facebook, at the end of the guide they give you an html button you integrate with your apps or if you are using Okta's sign-in widget. It shows how to do so.

iOS Android login form

I want to make a hybrid app for iOS and Android by wrapping the MVC4 mobile website into WebView/UiWebView. However i want the login screen to be a native view.
How can I submit the username and password to my MVC4 controller where i can check them in the database and after authenticating to redirect the user on another page? Notice that i have implemented a login form on the MVC web site also.
Should i use a ajax call from the mobile app? Can you provide some code example/tutorial/video?
That might be a problem because MVC is going to make some session cookies with tokens in it. So even if you were to get logged in using some kind of ajax call or setting headers and data and posting to the login process you still need to make sure that those tokens and cookies get set. And are useable by the Webviews.
I am not saying it can't be done just that it might be difficult.

Authentication Google Pages in .NET MVC3 App to get page source

I am writing an MVC3 app that is trying to get the page source of a google page (specifically the Android Marketplace for our company) that is behind the authentication wall. I am just wondering how I can authenticate properly so that my app can see pages that are authenticated.
I tried following the steps at this site (post by WeCi2i): http://bytes.com/topic/c-sharp/answers/870187-login-youtube-using-c, but without success.
Any advice would be appreciated.
Thanks
Microsoft included by default DotNetOpenAuth in MVC 4, but you can use it also in MVC 3
http://dotnetopenauth.net/
http://www.tkglaser.net/2012/02/single-sign-on-using-google-in-asp-mvc.html

how to get authorization code to my wp app for google authentication?

In my WP7.5 app, I have redirect the user to google web page where is asked to giving the app permissions to access to his account, user click yes, but it redirects to a page where there is the code and user is supossed to copy/paste that to my app.
The Response is
Please copy this code, switch to your application and paste it there:
4/3oHAHtqSk1CqA3S8HlEsuQRaE08e.4nCBpXhR-R8WgrKXntQAax02U4CwcgI - Auth code
I want to, when user press ok, return to my app with that code, is there any way to do that?
-SheikAbdullah
If you're using the Browser control, here's a great CodeProject article on how to do it:
Google OAuth2 on Windows Phone

Resources