This topic describes how to resolve logon status loss that occurs after you add your services to Web Application Firewall (WAF).
Problem description
Some websites experience logon status loss or other logon-related issues after they are added to WAF. The main causes are:
- Session synchronization is not configured for a domain name that uses multiple origin servers (ECS). This issue is common in architectures where a Server Load Balancer (SLB) instance is deployed behind WAF.
- The originating IP address is not retrieved from the x-forwarded-for header for verification.
Solutions
- Configure session synchronization for the servers.
For more information, see [ASP.NET] Solution for sharing sessions among multiple sites.
- If an SLB instance is deployed behind WAF, use Layer 7 HTTP for forwarding, enable session persistence, and configure session persistence to use cookies.
- Obtain the visitor's originating IP address from the x-forwarded-for header for verification.
For more information, see Obtain the originating IP addresses of visitors.
该文章对您有帮助吗?