Forum Discussion
kridsana
Sep 09, 2022Cirrocumulus
Block direct IP access from internet
Hi We have multi-domain (ie. a1.test.com, a2.test.com, etc) which is in one Virtual server. (*.test.com) Can we block direct ip access from internet? we want customer to connect using only web...
CA_Valli
Sep 09, 2022MVP
Hello, iRule syntax needs some fixes, switch instruction with glob-style matching does not support wildcards nor else statements
Try this instead, it's simplified
when HTTP_REQUEST {
if { not ([string tolower [HTTP::host]] ends_with ".test.com")}{ reject }
}
Recent Discussions
Related Content
DevCentral Quicklinks
* 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
Discover DevCentral Connects