Files
codeql/rust/ql/test/library-tests/frameworks/postgres/Postgres.ql
2025-01-20 12:06:09 +00:00

20 lines
538 B
Plaintext

import rust
import codeql.rust.security.SqlInjectionExtensions
import utils.test.InlineExpectationsTest
module PostgresTest implements TestSig {
string getARelevantTag() { result = "sql-sink" }
predicate hasActualResult(Location location, string element, string tag, string value) {
exists(SqlInjection::Sink sink |
location = sink.getLocation() and
location.getFile().getBaseName() != "" and
element = sink.toString() and
tag = "sql-sink" and
value = ""
)
}
}
import MakeTest<PostgresTest>