Welcome to the Microsoft Q&A Platform. Thank you for reaching out & I hope you are doing well.
I am afraid I did not get the requirement.
From your verbatim,
- You are planning to use 2 reverse proxies (client owned third party and then AFD)
- The AppService has custom domains, say, clientA.contoso.com
- The third party reverse proxy has example.clientB.com as the domain
Analysis,
- If you plan to use AFD, you have to add the custom domain to the AFD
- So AFD's domain would also become clientA.contoso.com (same as AppService's custom domain)
- While the above step is not necessary, it is highly recommended
- See why here : Host name Preservation and it's Potential problems
-
- The 3rd party reverse proxy uses a domain, say "abc.com"
- This would try to access the AFD via clientA.contoso.com
- The host header would be "clientA.contoso.com"
Now,
- This is what would an ideal setup look like
- If my understanding is correct, you want the App Service to be only accessible via the 3rd party reverse proxy' domain - i.e., "abc.com"
- Let me know if my understanding is incorrect
Next steps,
- Azure Front Door includes headers for an incoming request unless they're removed because of restrictions.
- So whatever headers sent by the 3rd party reverse proxy is preserved and sent to the backend (App Service)
- You should be able to use the header value in your App Service.
- NOTE : AFAIK, the 3rd party reverse proxy would use the host header as "clientA.contoso.com" only
- So, you can use this header to identify where the request came from in your App Service.
Hope this clarifies
Cheers,
Kapil