Skip to content

Commit dd87b1a

Browse files
committed
Convert os.stdin model to MaD
1 parent bf824ca commit dd87b1a

File tree

2 files changed

+1
-8
lines changed

2 files changed

+1
-8
lines changed

go/ql/lib/ext/os.model.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -53,6 +53,7 @@ extensions:
5353
- ["os", "", False, "Open", "", "", "ReturnValue[0]", "file", "manual"]
5454
- ["os", "", False, "OpenFile", "", "", "ReturnValue[0]", "file", "manual"]
5555
- ["os", "", False, "ReadFile", "", "", "ReturnValue[0]", "file", "manual"]
56+
- ["os", "", False, "Stdin", "", "", "", "stdin", "manual"]
5657
- ["os", "", False, "UserCacheDir", "", "", "ReturnValue[0]", "environment", "manual"]
5758
- ["os", "", False, "UserConfigDir", "", "", "ReturnValue[0]", "environment", "manual"]
5859
- ["os", "", False, "UserHomeDir", "", "", "ReturnValue[0]", "environment", "manual"]

go/ql/lib/semmle/go/frameworks/stdlib/Os.qll

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -43,12 +43,4 @@ module Os {
4343
input = inp and output = outp
4444
}
4545
}
46-
47-
private class Stdin extends SourceNode {
48-
Stdin() {
49-
exists(Variable osStdin | osStdin.hasQualifiedName("os", "Stdin") | this = osStdin.getARead())
50-
}
51-
52-
override string getThreatModel() { result = "stdin" }
53-
}
5446
}

0 commit comments

Comments
 (0)