Skip to content

Commit 8d90b25

Browse files
committed
Bearer and Basic authourization credential markup
1 parent 3091803 commit 8d90b25

35 files changed

+1391
-809
lines changed

.ci/benchmark.txt

Lines changed: 25 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,15 @@
1-
META MD5 57812ea47254ea45536ed6cb1e1d666a
2-
DATA MD5 ba31dd1d0389d14325975aedf69077ac
3-
DATA: 16701789 interested lines. MARKUP: 60630 items
1+
META MD5 42f77d135b8784c2cf3e5878cabfe088
2+
DATA MD5 d1b4a31164dd508138dc4881c335e089
3+
DATA: 16703140 interested lines. MARKUP: 61262 items
44
FileType FileNumber ValidLines Positives Negatives Templates
55
--------------- ------------ ------------ ----------- ----------- -----------
66
676 69398 134 416 72
77
.04 2 149 4
88
.1 2 641 2 8
99
.admx 1 26 1
10-
.adoc 1 158 13 5 1
10+
.adoc 1 158 18 5 1
1111
.api 2 118 4
12-
.asciidoc 102 15403 80 336 17
12+
.asciidoc 102 15403 81 336 17
1313
.axaml 5 286 5
1414
.backup 1 62 2 1
1515
.bash 2 2158 2 1
@@ -37,7 +37,7 @@ FileType FileNumber ValidLines Positives Negatives Templat
3737
.creds 1 10 1 1
3838
.crlf 1 27 1
3939
.crt 2 4979 126
40-
.cs 268 82752 278 863 95
40+
.cs 268 82752 279 863 95
4141
.cshtml 5 180 12
4242
.csp 3 379 9
4343
.csproj 1 14 1
@@ -66,17 +66,17 @@ FileType FileNumber ValidLines Positives Negatives Templat
6666
.gd 1 37 1
6767
.gml 3 3075 16
6868
.gni 3 5017 19
69-
.go 1275 717403 1421 4124 729
69+
.go 1277 718576 1450 4124 729
7070
.golden 5 1168 1 13 29
7171
.gradle 50 4295 8 90 99
7272
.graphql 8 454 2 13
7373
.graphqls 1 30 1
74-
.groovy 22 5113 24 214 1
74+
.groovy 22 5113 25 214 1
7575
.gtpl 1 15 2
7676
.h 10 2269 38
7777
.haml 9 191 17
7878
.hbs 2 54 3
79-
.hs 14 4140 29 61 4
79+
.hs 14 4140 30 61 4
8080
.html 60 19400 85 107 17
8181
.idl 3 1625 37 5
8282
.iml 6 699 30
@@ -86,11 +86,11 @@ FileType FileNumber ValidLines Positives Negatives Templat
8686
.ipynb 1 134 7
8787
.j 1 241 4
8888
.j2 32 6043 8 169 10
89-
.java 669 143891 484 1338 161
89+
.java 672 144069 489 1338 161
9090
.jenkinsfile 1 58 2 6
9191
.jinja2 1 64 2
92-
.js 655 531277 572 2419 283
93-
.json 886 13114472 1305 9998 125
92+
.js 655 531277 582 2419 283
93+
.json 886 13114472 1323 9998 125
9494
.jsp 13 3202 1 37
9595
.jsx 7 857 19
9696
.jwt 1 1 2
@@ -118,7 +118,7 @@ FileType FileNumber ValidLines Positives Negatives Templat
118118
.markdown 38 5862 69 4
119119
.markerb 3 12 3
120120
.marko 1 21 2
121-
.md 760 180503 888 2311 578
121+
.md 760 180503 982 2311 578
122122
.mdx 3 549 7
123123
.mjml 1 18 1
124124
.mjs 22 4424 101 369
@@ -141,7 +141,7 @@ FileType FileNumber ValidLines Positives Negatives Templat
141141
.patch 4 109405 4 27
142142
.pbxproj 1 941 1
143143
.pem 59 1297 58 3
144-
.php 390 80502 147 1392 70
144+
.php 390 80502 149 1392 70
145145
.pl 16 14727 7 33
146146
.pm 4 1817 8
147147
.po 3 2994 15
@@ -159,14 +159,14 @@ FileType FileNumber ValidLines Positives Negatives Templat
159159
.pug 2 193 2
160160
.purs 1 69 4
161161
.pxd 1 150 2 4
162-
.py 901 294351 739 3223 699
162+
.py 901 294351 746 3229 699
163163
.pyi 4 1361 9
164164
.pyp 1 167 1
165165
.python 1 213
166166
.pyx 2 1094 23
167167
.r 4 62 5 2
168168
.rake 2 51 2
169-
.rb 852 130684 415 2397 570
169+
.rb 852 130684 420 2397 570
170170
.re 1 31 1
171171
.red 1 159 1
172172
.release 1 13 4
@@ -188,7 +188,7 @@ FileType FileNumber ValidLines Positives Negatives Templat
188188
.scala 53 5626 38 99
189189
.scss 16 8553 32 1
190190
.secrets 1 11 1
191-
.sh 152 24184 70 462 21
191+
.sh 152 24184 71 462 21
192192
.slim 1 153 1 2
193193
.smali 1 775 18
194194
.snap 3 1708 9 29 2
@@ -216,10 +216,10 @@ FileType FileNumber ValidLines Positives Negatives Templat
216216
.toml 86 2471 65 106 145
217217
.tpl 1 43 1
218218
.travis 1 34 2 3 1
219-
.ts 609 109982 220 1777 193
219+
.ts 609 109982 226 1777 193
220220
.tsx 54 7914 1 114 5
221221
.ttar 1 452 1
222-
.txt 322 81679 5241 3791 41
222+
.txt 322 81679 5242 4340 41
223223
.utf8 1 77 1
224224
.vsixmanifest 1 36 1
225225
.vsmdi 1 6 2
@@ -229,10 +229,10 @@ FileType FileNumber ValidLines Positives Negatives Templat
229229
.xib 11 503 164
230230
.xsl 1 311 1
231231
.yaml 168 24422 195 337 40
232-
.yml 555 54516 1264 900 326
232+
.yml 555 54516 1865 900 326
233233
.zsh 6 872 12
234234
.zsh-theme 1 97 1
235-
TOTAL: 11473 16701789 15272 45022 4740
235+
TOTAL: 11478 16703140 16060 45577 4740
236236
credsweeper result_cnt : 0, lost_cnt : 0, true_cnt : 0, false_cnt : 0
237237
Rules Positives Negatives Templates Reported TP FP TN FN FPR FNR ACC PRC RCL F1
238238
------------------------------ ----------- ----------- ----------- ---------- ---- ---- ----- ----- -------- -------- -------- ----- -------- ----
@@ -246,6 +246,8 @@ Auth 1094 2760 77
246246
Azure Access Token 21 0 0 0 0 0 21 1.000000 0.000000 0.000000
247247
BASE64 Private Key 22 4 0 0 0 4 22 0.000000 1.000000 0.153846 0.000000
248248
BASE64 encoded PEM Private Key 12 0 0 0 0 0 12 1.000000 0.000000 0.000000
249+
Basic Authorization 625 554 0 0 0 554 625 0.000000 1.000000 0.469890 0.000000
250+
Bearer Authorization 163 0 0 0 0 0 163 1.000000 0.000000 0.000000
249251
Bitbucket Client ID 36 66 0 0 0 66 36 0.000000 1.000000 0.647059 0.000000
250252
Bitbucket Client Secret 38 104 1 0 0 105 38 0.000000 1.000000 0.734266 0.000000
251253
CMD ConvertTo-SecureString 13 4 0 0 0 4 13 0.000000 1.000000 0.235294 0.000000
@@ -271,7 +273,7 @@ Jira 2FA 36 1 1
271273
Key 4195 15817 477 0 0 16294 4195 0.000000 1.000000 0.795256 0.000000
272274
Nonce 115 50 0 0 0 50 115 0.000000 1.000000 0.303030 0.000000
273275
Other 9 7439 5 0 0 7444 9 0.000000 1.000000 0.998792 0.000000
274-
PEM Private Key 1142 75 0 0 0 75 1142 0.000000 1.000000 0.061627 0.000000
276+
PEM Private Key 1142 76 0 0 0 76 1142 0.000000 1.000000 0.062397 0.000000
275277
Password 2509 7560 2398 0 0 9958 2509 0.000000 1.000000 0.798749 0.000000
276278
SQL Password 44 13 1 0 0 14 44 0.000000 1.000000 0.241379 0.000000
277279
Salesforce Credentials 6 0 0 0 0 0 6 1.000000 0.000000 0.000000
@@ -285,4 +287,4 @@ Token 947 4186 454
285287
Twilio Credentials 30 39 0 0 0 39 30 0.000000 1.000000 0.565217 0.000000
286288
URL Credentials 229 177 184 0 0 361 229 0.000000 1.000000 0.611864 0.000000
287289
UUID 1866 265 0 0 0 265 1866 0.000000 1.000000 0.124355 0.000000
288-
15272 45022 4740 0 0 0 45022 15272 0.000000 1.000000 0.746708 0.000000
290+
16060 45577 4740 0 0 0 45577 16060 0.000000 1.000000 0.739442 0.000000

benchmark/scanner/scanner.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -55,6 +55,8 @@ def _meta_checksum(meta_location) -> str:
5555
checksum = hashlib.md5(b'').digest()
5656
for root, dirs, files in os.walk(meta_location):
5757
for file in files:
58+
if not file.endswith(".csv"):
59+
continue
5860
with open(os.path.join(root, file), "rb") as f:
5961
cvs_checksum = hashlib.md5(f.read()).digest()
6062
checksum = bytes(a ^ b for a, b in zip(checksum, cvs_checksum))

0 commit comments

Comments
 (0)