File tree Expand file tree Collapse file tree 1 file changed +7
-3
lines changed
cpp/ql/lib/semmle/code/cpp/models/implementations Expand file tree Collapse file tree 1 file changed +7
-3
lines changed Original file line number Diff line number Diff line change 1
1
/**
2
- * Provides an implementation class modeling the POSIX function `getenv`.
2
+ * Provides an implementation class modeling the POSIX function `getenv` and
3
+ * various similar functions.
3
4
*/
4
5
5
6
import cpp
6
7
import semmle.code.cpp.models.interfaces.FlowSource
7
8
8
9
/**
9
- * The POSIX function `getenv`.
10
+ * The POSIX function `getenv`, the GNU function `secure_getenv`, and the
11
+ * Windows function `_wgetenv`.
10
12
*/
11
13
class Getenv extends LocalFlowSourceFunction {
12
- Getenv ( ) { this .hasGlobalOrStdOrBslName ( "getenv" ) }
14
+ Getenv ( ) {
15
+ this .hasGlobalOrStdOrBslName ( "getenv" ) or this .hasGlobalName ( [ "secure_getenv" , "_wgetenv" ] )
16
+ }
13
17
14
18
override predicate hasLocalFlowSource ( FunctionOutput output , string description ) {
15
19
(
You can’t perform that action at this time.
0 commit comments