MCPcopy Create free account
hub / github.com/ajitpratap0/GoSQLX / scanInsertStatement

Method scanInsertStatement

pkg/sql/security/scanner.go:683–690  ·  view source on GitHub ↗

scanInsertStatement analyzes INSERT for injection patterns.

(stmt *ast.InsertStatement, result *ScanResult)

Source from the content-addressed store, hash-verified

681
682// scanInsertStatement analyzes INSERT for injection patterns.
683func (s *Scanner) scanInsertStatement(stmt *ast.InsertStatement, result *ScanResult) {
684 // Check values for suspicious patterns (multi-row support)
685 for _, row := range stmt.Values {
686 for _, val := range row {
687 s.scanExpressionForDangerousFunctions(val, result)
688 }
689 }
690}
691
692// scanUpdateStatement analyzes UPDATE for injection patterns.
693func (s *Scanner) scanUpdateStatement(stmt *ast.UpdateStatement, result *ScanResult) {

Callers 1

scanStatementMethod · 0.95

Tested by

no test coverage detected