Forum Discussion
sys-halt_219917
Nimbostratus
Sep 01, 2015Block a specific URL that only ends with a specific keyword
Hello,
is it possible to block a specific URL (https based) that ENDS only with a specific keyword?
for example if I have a domain example.com and I want to only block:
https://example....
Stanislas_Piro2
Cumulonimbus
Sep 01, 2015Try that:
In the URL : https://example.com/Logon/login?service=
- HTTP::host is example.com
- HTTP::path is /Logon/login
- HTTP::query is service=
- HTTP::uri is /Logon/login?service=
.
when HTTP_REQUEST {
switch -glob [string tolower [HTTP::path]] {
"*/logon" -
"*/logon/login" {
if {[HTTP::query] equals ""} {
HTTP::respond 404 content {
Access denied
Access denied
} noserver
return
}
}
}
Help guide the future of your DevCentral Community!
What tools do you use to collaborate? (1min - anonymous)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
