Aug 12 2020 05:26 AM
We have an existing Azure dotnet app that simply uses traditional asp.net forms authentication. The app service itself is set to anonymous access. We would like to add it into Teams as an alternative access point for users but after trying we've hit a problem that the custom authentication page doesn't seem to be able to set the cookie on a successful submit and the user stays on the login page rather than being redirected. Does the app have to be modified in some way for this to work?
Aug 13 2020 02:07 AM
@Ryan Stone , Have you implemented Teams authentication in your .net forms app?
You need to use the tabs SDK method microsoftTeams.authentication.authenticate()
. Please look at here for more detail https://docs.microsoft.com/en-us/microsoftteams/platform/concepts/authentication/auth-flow-tab. There's a C# example here: Microsoft Teams tab authentication sample (C#).
Aug 13 2020 04:59 AM
@Trinetra-MSFT thank you for the response. Why would this be needed though if the app is not using Azure AD or an identify provider like that, and is not making any external API calls? It's completely self-contained app with anonymous access and traditional built-in forms authentication. Is all this still required?
Aug 13 2020 05:32 AM
Solution@Ryan Stone I think that this documentation will help you https://docs.microsoft.com/en-us/microsoftteams/platform/resources/samesite-cookie-update.
I think that the problem is related the chromium engine used by Teams and the fact that you are app is embedded in an iframe
Aug 13 2020 05:39 AM
@Alexis CONIA thank you! That makes complete sense.
Aug 13 2020 05:32 AM
Solution@Ryan Stone I think that this documentation will help you https://docs.microsoft.com/en-us/microsoftteams/platform/resources/samesite-cookie-update.
I think that the problem is related the chromium engine used by Teams and the fact that you are app is embedded in an iframe