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.