-
Notifications
You must be signed in to change notification settings - Fork 1
Description
Issue Summary:
The sanitizeQueryString function is not utilizing its passed target argument. Instead, it defaults to using cgi.query_string for sanitization, rendering the target argument ineffective and limiting the function's usability to only cgi.query_string. The problematic lines are located at line 98 and line 168.
Steps to Reproduce:
- Call the sanitizeQueryString function with a custom string as the target argument.
sanitizeQueryString("key1=value1&key2=value2");
- Observe the sanitization process and output.
Expected Behavior:
The function should use the target argument for sanitization, allowing it to sanitize any provided query string, not just cgi.query_string.
Actual Behavior:
The function ignores the target argument and sanitizes cgi.query_string instead, making the function dependent on the global cgi.query_string.
Impact:
- The function cannot be used for custom query strings outside of cgi.query_string.
- It limits the reusability and flexibility of the function.
- Introduces potential issues when sanitizing non-global query strings.
Suggested Fix:
Update the sanitizeQueryString logic to use the passed target argument. If target is not provided, then default to cgi.query_string.
Environment:
File: RollbarService.cfc
Affected Lines: 98, 168
Let me know if you have any questions. Ty!