-
-
Notifications
You must be signed in to change notification settings - Fork 1.2k
/
cwe.go
129 lines (123 loc) · 2.13 KB
/
cwe.go
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
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
package cwe
// CweTopTwentyfives has CWE-ID in CWE Top 25
var CweTopTwentyfives = map[string]map[string]string{
"2019": cweTopTwentyfive2019,
"2020": cweTopTwentyfive2020,
"2021": cweTopTwentyfive2021,
"2022": cweTopTwentyfive2022,
}
var cweTopTwentyfive2019 = map[string]string{
"119": "1",
"79": "2",
"20": "3",
"200": "4",
"125": "5",
"89": "6",
"416": "7",
"190": "8",
"352": "9",
"22": "10",
"78": "11",
"787": "12",
"287": "13",
"476": "14",
"732": "16",
"434": "16",
"611": "17",
"94": "18",
"798": "19",
"400": "20",
"772": "21",
"426": "22",
"502": "23",
"269": "24",
"295": "25",
}
var cweTopTwentyfive2020 = map[string]string{
"79": "1",
"787": "2",
"20": "3",
"125": "4",
"119": "5",
"89": "6",
"200": "7",
"416": "8",
"352": "9",
"78": "10",
"190": "11",
"22": "12",
"476": "13",
"287": "14",
"434": "16",
"732": "16",
"94": "17",
"522": "18",
"611": "19",
"798": "20",
"502": "21",
"269": "22",
"400": "23",
"306": "24",
"862": "25",
}
var cweTopTwentyfive2021 = map[string]string{
"787": "1",
"79": "2",
"125": "3",
"20": "4",
"78": "5",
"89": "6",
"416": "7",
"22": "8",
"352": "9",
"434": "10",
"306": "11",
"190": "12",
"502": "13",
"287": "14",
"476": "16",
"798": "16",
"119": "17",
"862": "18",
"276": "19",
"200": "20",
"522": "21",
"732": "22",
"611": "23",
"918": "24",
"77": "25",
}
var cweTopTwentyfive2022 = map[string]string{
"787": "1",
"79": "2",
"89": "3",
"20": "4",
"125": "5",
"78": "6",
"416": "7",
"22": "8",
"352": "9",
"434": "10",
"476": "11",
"502": "12",
"190": "13",
"287": "14",
"798": "16",
"862": "16",
"77": "17",
"306": "18",
"119": "19",
"276": "20",
"918": "21",
"362": "22",
"400": "23",
"611": "24",
"94": "25",
}
// CweTopTwentyfiveURLs has CWE Top25 links
var CweTopTwentyfiveURLs = map[string]string{
"2019": "https://cwe.mitre.org/top25/archive/2019/2019_cwe_top25.html",
"2020": "https://cwe.mitre.org/top25/archive/2020/2020_cwe_top25.html",
"2021": "https://cwe.mitre.org/top25/archive/2021/2021_cwe_top25.html",
"2022": "https://cwe.mitre.org/top25/archive/2022/2022_cwe_top25.html",
}