I recently moved an older ASP.NET MVC 5 application to Azure AppService.
The application consists of two services:
Service A
acts asOAuthAuthorizationServer
and is configured to also issueOAuthBearerTokens
- The bearer token is then used for authentication with
service B
.
This worked fine now for several years and also works when I run everything locally.
However when I run it in Azure I do receive a token from service A but service B does not accept it as I get redirected to the login page of that service.
What did I do so far:
- Played around in different configurations
- Updated the libraries
Microsoft.Owin.Security.OAuth
and others to the latest version - Configured App Service Authentication by using OpenID (after that nothing work anymore)
- Checked setting in azure but found nothing
- Checked for serverlogs in azure and via ftp but could not find any
I'd like to either find a way to debug the issue by getting some logs up and running to see why the token is rejected or if someone has an idea what could cause the issue.
Please help, I'm pretty lost at the moment ...
Edit: The implementation basically follows http://bitoftech.net/2014/06/01/token-based-authentication-asp-net-web-api-2-owin-asp-net-identity/
The two services are two separate App Services.