Forum Discussion
Kai_Wilke
Nov 30, 2016MVP
Hi N. Tariq,
you may try the iRule below...
when HTTP_REQUEST {
if { ( [string tolower "[HTTP::host][HTTP::path]"] starts_with "internal.company.com.au/path/" } then {
Allow the request...
} else {
Redirect the request...
HTTP::redirect "https://internal.company.com.au/path/"
}
}
Note: The iRule checks if the requested HTTP host and path starts_with "internal.company.com.au/path/". If this check is true, the iRule allows the ongoing request. If the HTTP host and/or path is different, then it would send a redirect to https://internal.company.com.au/path/.
Cheers, Kai