Source: AL0111SqlInterpolationInCommandTextAnalyzer.csDocumentation Index
Fetch the complete documentation index at: https://ancplua.mintlify.app/llms.txt
Use this file to discover all available pages before exploring further.
Description
Assigning an interpolated string ($"..." or $"""...""") to a property named CommandText is a SQL injection vector. Values should be passed via parameterized queries (@param, $1) instead of being interpolated directly into the command string.
Bad Code
Good Code
Properties
- Category: Reliability
- Severity: Warning
- Enabled by default: True
- Code fix available: False
