An Azure service that provides a platform-managed, scalable, and highly available application delivery controller as a service.
Yep - that has been my experience as well. When Cloudflare proxies traffic, it terminates the client connection and establishes a new connection to the Application Gateway, so the source IP seen by the gateway is the Cloudflare edge IP rather than the original end-user IP.
Although Cloudflare forwards the original client IP in HTTP headers such as CF-Connecting-IP (and optionally X-Forwarded-For), Application Gateway WAF logging and WAF rate-limiting use the network source IP, not these forwarded headers. As a result, the clientIP field in WAF logs continues to show the Cloudflare edge address.
You might want to consider implementing IP-based rate limiting at Cloudflare instead of Azure Application Gateway. If rate limiting must occur in Azure, then an alternative would involve using Azure Front Door Premium with WAF, which provides support for client IP handling in proxied scenarios, or redesigning the architecture so that Application Gateway receives client connections directly rather than through another reverse proxy.
If the above response helps answer your question, remember to "Accept Answer" so that others in the community facing similar issues can easily find the solution. Your contribution is highly appreciated.
hth
Marcin