T-SQL code security

T-SQL static code analysis

Find security flaws in T-SQL stored procedures, functions and jobs: SQL and command injection, insecure GRANT usage, default accounts, hardcoded passwords and keys, weak cryptography and backdoors. T-SQL findings land in the same platform and report as the rest of your applications.

Fix advice
Every finding with severity, fix recommendation and code location
43
languages in one platform, T-SQL and PL/SQL included
On-premise
or air-gapped: database code and findings stay on internal servers

In short

DerScanner is a static application security testing (SAST) tool that scans T-SQL code. Its T-SQL rules are published in the DerScanner vulnerability database, and most of them map to CWE, OWASP Top 10 and PCI DSS 4.0.

The rules cover SQL injection, command injection through jobs, insecure GRANT usage, default and special accounts, hardcoded and empty passwords and keys, weak cryptography, and query errors such as incorrect NULL comparison and TOP without ORDER BY. Each finding comes with a severity, a description, a fix recommendation and the code location.

DerScanner runs on-premise, in air-gapped networks or in the cloud. For T-SQL it provides security analysis (SAST); PL/SQL has its own rules in the same platform.

What the T-SQL rules check

The T-SQL rules follow how database code is attacked: dynamic SQL built from input, rights granted too widely, and secrets kept in procedures. Each rule links to its description, CWE identifiers and fix recommendation.

Injection

SQL injection through dynamic SQL, code injection, command injection through jobs, and insecure functions.

Rights and accounts

GRANT statements that give too much, default accounts and special accounts left in the code.

Secrets and cryptography

Passwords and keys written into procedures, empty keys, and weak encryption, hashing and random numbers.

Backdoors and undocumented features

Hidden functionality, time bombs and unexpected network activity in database code.

Query errors and reliability

Incorrect comparison with NULL, TOP without ORDER BY, date conversion, empty error handling, denial of service and information leaks.

See all T-SQL rules in the vulnerability database

Where T-SQL code runs

T-SQL is the procedural SQL dialect used by SQL Server. Stored procedures, functions, triggers and jobs written in it often hold business logic that application code calls directly.

Database code sits next to the data and runs with database rights, so dynamic SQL, wide grants and stored secrets lead the rule list.

PL/SQL static analysis for Oracle code

One scan with the rest of your code

T-SQL is one of 43 languages in DerScanner. Database code and the applications that call it can be scanned in the same platform, with one severity scale and one report format.

Scans run from the web interface, the CLI or a CI/CD integration, and the reports cover standards such as OWASP Top 10, PCI DSS and CWE.

Rare and legacy language support in DerScanner

Questions buyers ask about T-SQL static code analysis

Try DerScanner on your own code, free

Scan your own T-SQL code and see what DerScanner finds in it.

Request a free pilot. We give you access and help with the first scan. It works in the cloud and on-premise.

Want to describe your project first? Take the 2-minute PoC survey

Get Started

Make Your Applications
Secure Today

Sign up for a personalized demo to see
how DerScanner can meet your Application Security needs

dashboard