Forum Discussion
Universal persistence using IPV6 with iRule..
Do you have a persistence profile on the virtual? Might be best to have a default of source_addr persistence as a profile on the virtual, that way you can reduce your iRule to this (my attempt, you'll need to test)
when HTTP_REQUEST {
if { [HTTP::header exists X-Forwarded-For] } {
persist uie [getfield [HTTP::header X-Forwarded-For] "," 1]
}
}
Hi Jason,
We can't use a default source_addr profile because the inbound traffic goes through a CDN, which they append the client IP and their proxy IP to the XFF header. We use the irule to look into this and persist the connection for the client to a server in the backend. This works fine with IPV4, however there are instances where some of our user's ISP is giving them an IPV6 address. How can this iRule or any other method be used to read the IPV6 along with the IPV4 (this irule) and persist the client
based on that?
Thanks!
- ant77Mar 12, 2021Cirrostratus
Hello F5/Jason,
Please help...can you let me know if this can be done or not?
Thanks!
- JRahmMar 12, 2021Admin
it should be possible, but I really need to see samples of the contents of your XFF headers in ipv4 and ipv6 to see if you are indexing and splitting correctly for both protocols. I can track down bugs and experience in the meantime. Sorry, I don't have much operational ipv6 experience
- ant77Mar 15, 2021Cirrostratus
Thank you Jason, appreciate your help. Once I get more info and a sample, I will post it.
Recent Discussions
Related Content
* Getting Started on DevCentral
* Community Guidelines
* Community Terms of Use / EULA
* Community Ranking Explained
* Community Resources
* Contact the DevCentral Team
* Update MFA on account.f5.com