Quantcast
Channel: Security
Viewing all articles
Browse latest Browse all 4737

MVC5/Web API 2 ExternalLogin with returnURL other than /

$
0
0

Hi Everyone,

I've been banging my head on this all night long and I'm sure there's some undocumented property that I need to set somewhere to get this to work.

Essentially, I have a mobile application that makes a call to /Api/Account/ExternalLogins to get the external logins configured for my site. This API method accepts 2 parameters:

  1. returnUrl
  2. state

Since this is a mobile application and not a web site, I want the returnUrl to be a blank page (i.e. something like "/Mobile/") and not the root of my site. However, when I navigate the WebBrowser control in my mobile to the /Api/Account/ExternalLogin?... URL returned from the call to /Api/Account/ExternalLogins mentioned above, I get a 400 BAD REQUEST. The action method at /Api/Account/ExternalLogin is never invoked so there's something in the pipeline intercepting and determining that this request is bad - but there is no detailed documentation on how any of this new stuff works...

Does anyone know the secret sauce to make this work? Alternatively, does anyone know how to turn on tracing for the new Owin/Katana bits?

I should note that if my returnUrl is "/" everything works fine.

Thanks in advance for any assistance you can provide!

Ryan


Viewing all articles
Browse latest Browse all 4737

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>