Forum Discussion
iRules containing an escaped newline character can cause TMM to crash.
Recommendation resolution
Examine the iRules listed below for suspended commands, and remove all instances of escaped newline characters which precede a suspended command later in the iRule.
Can someone point out where my escaped newline character might be?
when HTTP_REQUEST {
set URI to lower case
set tmpUri [string tolower [HTTP::uri]]
URI decode the URI
set uri [URI::decode $tmpUri]
repeat decoding until the decoded version equals the previous value.
while { $uri ne $tmpUri } {
set tmpUri $uri
set uri [URI::decode $tmpUri]
}
switch -glob [string tolower [HTTP::uri]] {
"*<*" -
"*>*" -
"*select *" -
"*insert *" -
"*update *" -
"*delete *" -
"*create *" -
"*drop *" -
"*.\[tempdb\].*" -
"*.\[master\].*" -
"*.\[model\].*" -
"*.\[msdb\]." -
"*.\[dbo\].*" -
"*tempdb.*" -
"*master.*" -
"*model.*" -
"*msDB.*" -
"*.dbo.*" -
"*\r\n*" -
"*!*" -
"*%*" {
log local0. "Reject uri: [HTTP::uri]"
Send a TCP reset
reject
}
default {
Do nothing here to use the VIP's default pool
}
}
}
- The_BhattmanNimbostratusHi Nick,
- hooleylistCirrostratusI'd guess that's actually a false positive from iHealth on the "*\r\n*" switch case. I don't think there is actually a problem with that iRule in relation to CR135937.
log local0. "my log statement split \ over two lines with a backslash escaping the new line character!"
- jimmythegeek_10Historic F5 AccountHi, folks.
- hooleylistCirrostratusThanks for that.
- jimmythegeek_10Historic F5 AccountGot a brief update: just found out that a library routine I was using strips comments from irules before processing them. This is a problem because for this issue, comments are significant. This will take a little more time to fix, sorry for the FP and the false negatives.
Recent Discussions
Related Content
* 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