-
Notifications
You must be signed in to change notification settings - Fork 0
/
gosec-report
108 lines (108 loc) · 3.16 KB
/
gosec-report
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
{
"Golang errors": {},
"Issues": [
{
"severity": "MEDIUM",
"confidence": "MEDIUM",
"cwe": {
"id": "88",
"url": "https://cwe.mitre.org/data/definitions/88.html"
},
"rule_id": "G107",
"details": "Potential HTTP request made with variable url",
"file": "D:\\Code\\Other\\Golang-Proxy-Youtube\\internal\\client\\client.go",
"code": "120: \t}\n121: \tresponse, err := http.Get(url)\n122: \tif err != nil {\n",
"line": "121",
"column": "19",
"nosec": false,
"suppressions": null
},
{
"severity": "MEDIUM",
"confidence": "HIGH",
"cwe": {
"id": "276",
"url": "https://cwe.mitre.org/data/definitions/276.html"
},
"rule_id": "G301",
"details": "Expect directory permissions to be 0750 or less",
"file": "D:\\Code\\Other\\Golang-Proxy-Youtube\\src\\client\\main.go",
"code": "22: \t//Папка\n23: \tif err := os.MkdirAll(*outputDir, os.ModePerm); err != nil {\n24: \t\tlog.Fatalf(\"Ошибка в создании директории: %v\", err)\n",
"line": "23",
"column": "12",
"nosec": false,
"suppressions": null
},
{
"severity": "MEDIUM",
"confidence": "HIGH",
"cwe": {
"id": "276",
"url": "https://cwe.mitre.org/data/definitions/276.html"
},
"rule_id": "G306",
"details": "Expect WriteFile permissions to be 0600 or less",
"file": "D:\\Code\\Other\\Golang-Proxy-Youtube\\internal\\client\\client.go",
"code": "137: \tfilename := filepath.Join(outputDir, fmt.Sprintf(\"%s.jpg\", videoID))\n138: \treturn os.WriteFile(filename, imageData, 0644)\n139: }\n",
"line": "138",
"column": "9",
"nosec": false,
"suppressions": null
},
{
"severity": "MEDIUM",
"confidence": "HIGH",
"cwe": {
"id": "276",
"url": "https://cwe.mitre.org/data/definitions/276.html"
},
"rule_id": "G306",
"details": "Expect WriteFile permissions to be 0600 or less",
"file": "D:\\Code\\Other\\Golang-Proxy-Youtube\\internal\\client\\client.go",
"code": "114: \t\tfilename := filepath.Join(outputDir, fmt.Sprintf(\"%s.jpg\", videoID))\n115: \t\treturn os.WriteFile(filename, cachedData, 0644)\n116: \t}\n",
"line": "115",
"column": "10",
"nosec": false,
"suppressions": null
},
{
"severity": "LOW",
"confidence": "HIGH",
"cwe": {
"id": "703",
"url": "https://cwe.mitre.org/data/definitions/703.html"
},
"rule_id": "G104",
"details": "Errors unhandled.",
"file": "D:\\Code\\Other\\Golang-Proxy-Youtube\\internal\\client\\client.go",
"code": "45: \tc.conn.Close()\n46: \tc.cache.Close()\n47: }\n",
"line": "46",
"column": "2",
"nosec": false,
"suppressions": null
},
{
"severity": "LOW",
"confidence": "HIGH",
"cwe": {
"id": "703",
"url": "https://cwe.mitre.org/data/definitions/703.html"
},
"rule_id": "G104",
"details": "Errors unhandled.",
"file": "D:\\Code\\Other\\Golang-Proxy-Youtube\\internal\\client\\client.go",
"code": "44: func (c *Client) Close() {\n45: \tc.conn.Close()\n46: \tc.cache.Close()\n",
"line": "45",
"column": "2",
"nosec": false,
"suppressions": null
}
],
"Stats": {
"files": 9,
"lines": 695,
"nosec": 0,
"found": 6
},
"GosecVersion": "dev"
}