I am working on a test Azure Function v2 back end project. The goal is that the function method authorization attributes use the jwt token that I pass from our front end project that use MSAL to authenticate on our v2 app registered on portal azure. My front end project is written in Angular 7 and use this npm package for MSAL https://www.npmjs.com/package/@azure/msal-angular. I would use the same registered app for front end and back end project. What can I do in the startup to set jwt authentication and bind it to the function authorization attributes ?
This is a proof of concept project so we would replace our App Service Web API with an Azure Function. The front end and back end project use the same app registered on portal azure. We would still use the same registered app and front end would call the azure function instead of the App Service. I tried to use a binding example from this link https://www.ben-morris.com/custom-token-authentication-in-azure-functions-using-bindings , but they use a Certificate. I would like to use the App Id and Tenant Id instead of passing a Certificate.