Forum Discussion
Angelo
Nimbostratus
Jan 21, 2013multiple sites on HTTP and HTTPS
Hi
I got a request to add multiple web-site on my F5 but i have IP limitations. I have rule for one site to work on http and https but how will i add multiple web-sites to this rule...
when CLIENT_ACCEPTED {
switch [TCP::local_port] {
80 {
SSL::disable clientside
SSL::disable serverside
pool pool_dev3RB_http
}
443 {
pool pool_dev3RB_https
}
default {
reject
}
}
}
3 Replies
- What_Lies_Bene1
Cirrostratus
Do the multiple sites each use a different SSL certificate? - Angelo
Nimbostratus
No they all use the same cert - What_Lies_Bene1
Cirrostratus
OK great.So, I think all you'll want to do is remove the pool commands from the CLIENT_ACCEPTED event and then lookup the requested hostname in the HTTP_REQUEST even and specify the pools there. Something like this;when CLIENT_ACCEPTED { switch [TCP::local_port] { 80 { SSL::disable clientside SSL::disable serverside return } 443 { return } default { reject } } } when HTTP_REQUEST { switch [string tolower [HTTP::host]] { "www.test.com" - "www.example.com" { pool number1 } "www.something.com" { pool number2 } "www.testing.com" { pool number3 } If HTTP host is none of the above, take the default action below default { reject } } }
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