DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUGĀ· RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT <http://issues.apache.org/bugzilla/show_bug.cgi?id=41738>. ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED ANDĀ· INSERTED IN THE BUG DATABASE.
http://issues.apache.org/bugzilla/show_bug.cgi?id=41738 Summary: URLRewritingModifier isn't properly escaping bad regex characters Product: JMeter Version: 2.2 Platform: Other OS/Version: other Status: NEW Severity: normal Priority: P2 Component: HTTP AssignedTo: [email protected] ReportedBy: [EMAIL PROTECTED] Parameters with brackets: [ and ] are not being escaped properly before the regular expression is being build. We have parameters that are being posted that have these characters: (example: member[33]) This causes pattern match to fail because the matching is evaluating the brackets as part of the regular expression. I was able to fix the problem by adding the necessary escaping. I modified the regex init so that the argument name gets escaped properly before initialization: String argName = escapeParameterName(getArgumentName()); initRegex(argName); and added the escape function: private String escapeParameterName(String value) { value = value.replaceAll("\\[", "\\\\["); value = value.replaceAll("\\]", "\\\\]"); return value; } -- Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are the assignee for the bug, or are watching the assignee. --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
