Forum Discussion
Darrell_Kesti_5
Aug 27, 2008Historic F5 Account
Stream iRule
Hello. I am working on an iRule to solve a specific problem with a Sharepoint java script. Basically, I am doing SSL Client side termination on the Big-IP LTM 9.4.5 box. However, a few scripts loca...
Darrell_Kesti_5
Sep 03, 2008Historic F5 Account
Thanks for the information. I am getting very close. The word documents and other files are now properly being handled and the content is being written to https://. However, there is one concern. I just found out that the sharepoint portal also uses some external links to other sites that are called from the client machine, so we are replacing the http:// links in these sites to be https://, and it is breaking some of the reporting metrics because of this. Here is a variant of the rule I created. I only want to change the http content to https if it is part of the intranet.mydomain.com site, which is what the VIP is front ending, and not for any other links that may stream by in the page content.
Here is the rule I am thinking will do this. Does this look correct to anyone, or do you have any ideas? Do I need any wild carding as the paths will be http://intranet.mydomain.com/etc/etc
when HTTP_RESPONSE {
disable stream replacement by default
STREAM::disable
enable for text docs only
if {[HTTP::header value Content-Type] contains "text"}{
Replace any http:// instance with https:// only if the original string is http://intranet.mydomain.com.
STREAM::expression {@http://intranet.mydomain.com@https://intranet.mydomain.com@}
STREAM::enable
}
}
when STREAM_MATCHED {
This will log when the stream is matched in /var/log/ltm. This should help with any future troubleshooting as well.
log local0. "[IP::client_addr]:[TCP::local_port]: matched: [STREAM::match], replaced with: [string map {http:// https://}
[STREAM::match]]"
STREAM::replace "[string map {http:// https://} [STREAM::match]]"
}
Thank you for looking at this.
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
