Skip to content

Commit 1bf8fa6

Browse files
committed
Python: Adopt Query.qll suffix for dataflow config defs
This commit in itself makes everything break, but should make it easy to follow the overall changes being made.
1 parent d31ef37 commit 1bf8fa6

17 files changed

+17
-107
lines changed

python/ql/lib/semmle/python/security/dataflow/CleartextLogging.qll renamed to python/ql/lib/semmle/python/security/dataflow/CleartextLoggingQuery.qll

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -14,10 +14,7 @@ private import semmle.python.dataflow.new.RemoteFlowSources
1414
private import semmle.python.dataflow.new.BarrierGuards
1515
private import semmle.python.dataflow.new.SensitiveDataSources
1616

17-
/**
18-
* Provides a taint-tracking configuration for detecting "Clear-text logging of sensitive information".
19-
*/
20-
module CleartextLogging {
17+
2118
import CleartextLoggingCustomizations::CleartextLogging
2219

2320
/**
@@ -36,4 +33,3 @@ module CleartextLogging {
3633
node instanceof Sanitizer
3734
}
3835
}
39-
}

python/ql/lib/semmle/python/security/dataflow/CleartextStorage.qll renamed to python/ql/lib/semmle/python/security/dataflow/CleartextStorageQuery.qll

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -14,10 +14,6 @@ private import semmle.python.dataflow.new.RemoteFlowSources
1414
private import semmle.python.dataflow.new.BarrierGuards
1515
private import semmle.python.dataflow.new.SensitiveDataSources
1616

17-
/**
18-
* Provides a taint-tracking configuration for detecting "Clear-text storage of sensitive information".
19-
*/
20-
module CleartextStorage {
2117
import CleartextStorageCustomizations::CleartextStorage
2218

2319
/**
@@ -36,4 +32,3 @@ module CleartextStorage {
3632
node instanceof Sanitizer
3733
}
3834
}
39-
}

python/ql/lib/semmle/python/security/dataflow/CodeInjection.qll renamed to python/ql/lib/semmle/python/security/dataflow/CodeInjectionQuery.qll

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -10,10 +10,6 @@ private import python
1010
import semmle.python.dataflow.new.DataFlow
1111
import semmle.python.dataflow.new.TaintTracking
1212

13-
/**
14-
* Provides a taint-tracking configuration for detecting "code injection" vulnerabilities.
15-
*/
16-
module CodeInjection {
1713
import CodeInjectionCustomizations::CodeInjection
1814

1915
/**
@@ -32,7 +28,6 @@ module CodeInjection {
3228
guard instanceof SanitizerGuard
3329
}
3430
}
35-
}
3631

3732
/**
3833
* DEPRECATED: Don't extend this class for customization, since this will lead to bad

python/ql/lib/semmle/python/security/dataflow/CommandInjection.qll renamed to python/ql/lib/semmle/python/security/dataflow/CommandInjectionQuery.qll

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -10,10 +10,6 @@ private import python
1010
import semmle.python.dataflow.new.DataFlow
1111
import semmle.python.dataflow.new.TaintTracking
1212

13-
/**
14-
* Provides a taint-tracking configuration for detecting "command injection" vulnerabilities.
15-
*/
16-
module CommandInjection {
1713
import CommandInjectionCustomizations::CommandInjection
1814

1915
/**
@@ -32,7 +28,6 @@ module CommandInjection {
3228
guard instanceof SanitizerGuard
3329
}
3430
}
35-
}
3631

3732
/**
3833
* DEPRECATED: Don't extend this class for customization, since this will lead to bad

python/ql/lib/semmle/python/security/dataflow/LdapInjection.qll renamed to python/ql/lib/semmle/python/security/dataflow/LdapInjectionQuery.qll

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -12,14 +12,6 @@ import semmle.python.dataflow.new.DataFlow
1212
import semmle.python.dataflow.new.TaintTracking
1313
import semmle.python.dataflow.new.RemoteFlowSources
1414

15-
/**
16-
* Provides aint-tracking configurations for detecting LDAP injection vulnerabilities.class
17-
*
18-
* Two configurations are provided. One is for detecting LDAP injection
19-
* via the distinguished name (DN). The other is for detecting LDAP injection
20-
* via the filter. These require different escapings.
21-
*/
22-
module LdapInjection {
2315
import LdapInjectionCustomizations::LdapInjection
2416

2517
/**
@@ -57,4 +49,3 @@ module LdapInjection {
5749
guard instanceof FilterSanitizerGuard
5850
}
5951
}
60-
}

python/ql/lib/semmle/python/security/dataflow/LogInjection.qll renamed to python/ql/lib/semmle/python/security/dataflow/LogInjectionQuery.qll

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -10,10 +10,6 @@ import python
1010
import semmle.python.dataflow.new.DataFlow
1111
import semmle.python.dataflow.new.TaintTracking
1212

13-
/**
14-
* Provides a taint-tracking configuration for tracking untrusted user input used in log entries.
15-
*/
16-
module LogInjection {
1713
import LogInjectionCustomizations::LogInjection
1814

1915
/**
@@ -32,4 +28,3 @@ module LogInjection {
3228
guard instanceof SanitizerGuard
3329
}
3430
}
35-
}

python/ql/lib/semmle/python/security/dataflow/PathInjection.qll renamed to python/ql/lib/semmle/python/security/dataflow/PathInjectionQuery.qll

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -11,10 +11,6 @@ private import semmle.python.Concepts
1111
import semmle.python.dataflow.new.DataFlow
1212
import semmle.python.dataflow.new.TaintTracking
1313

14-
/**
15-
* Provides a taint-tracking configuration for detecting "path injection" vulnerabilities.
16-
*/
17-
module PathInjection {
1814
import PathInjectionCustomizations::PathInjection
1915

2016
/**
@@ -79,7 +75,7 @@ module PathInjection {
7975
class NormalizedUnchecked extends DataFlow::FlowState {
8076
NormalizedUnchecked() { this = "NormalizedUnchecked" }
8177
}
82-
}
78+
8379

8480
// ---------------------------------------------------------------------------
8581
// Old, deprecated code

python/ql/lib/semmle/python/security/dataflow/PolynomialReDoS.qll renamed to python/ql/lib/semmle/python/security/dataflow/PolynomialReDoSQuery.qll

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -10,10 +10,6 @@ private import python
1010
import semmle.python.dataflow.new.DataFlow
1111
import semmle.python.dataflow.new.TaintTracking
1212

13-
/**
14-
* Provides a taint-tracking configuration for detecting "polynomial regular expression denial of service (ReDoS)" vulnerabilities.
15-
*/
16-
module PolynomialReDoS {
1713
import PolynomialReDoSCustomizations::PolynomialReDoS
1814

1915
/**
@@ -32,4 +28,3 @@ module PolynomialReDoS {
3228
guard instanceof SanitizerGuard
3329
}
3430
}
35-
}

python/ql/lib/semmle/python/security/dataflow/ReflectedXSS.qll renamed to python/ql/lib/semmle/python/security/dataflow/ReflectedXSSQuery.qll

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -10,10 +10,6 @@ private import python
1010
import semmle.python.dataflow.new.DataFlow
1111
import semmle.python.dataflow.new.TaintTracking
1212

13-
/**
14-
* Provides a taint-tracking configuration for detecting "reflected server-side cross-site scripting" vulnerabilities.
15-
*/
16-
module ReflectedXss {
1713
import ReflectedXSSCustomizations::ReflectedXss
1814

1915
/**
@@ -32,7 +28,6 @@ module ReflectedXss {
3228
guard instanceof SanitizerGuard
3329
}
3430
}
35-
}
3631

3732
/** DEPRECATED: Alias for ReflectedXss */
3833
deprecated module ReflectedXSS = ReflectedXss;

python/ql/lib/semmle/python/security/dataflow/RegexInjection.qll renamed to python/ql/lib/semmle/python/security/dataflow/RegexInjectionQuery.qll

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -11,11 +11,6 @@ private import python
1111
import semmle.python.dataflow.new.DataFlow
1212
import semmle.python.dataflow.new.TaintTracking
1313

14-
/**
15-
* Provides a taint-tracking configuration for detecting regular expression injection
16-
* vulnerabilities.
17-
*/
18-
module RegexInjection {
1914
import RegexInjectionCustomizations::RegexInjection
2015

2116
/**
@@ -34,4 +29,3 @@ module RegexInjection {
3429
guard instanceof SanitizerGuard
3530
}
3631
}
37-
}

0 commit comments

Comments
 (0)