mirror of
https://github.com/gitleaks/gitleaks.git
synced 2026-11-29 12:44:22 +01:00
Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
c5fc080aa0 | ||
|
|
3bace4c735 | ||
|
|
e890a8e809 | ||
|
|
49b0b097e4 | ||
|
|
31a8e9db7a | ||
|
|
b1853bd032 | ||
|
|
cd52267113 | ||
|
|
afc89f91c0 | ||
|
|
5ae1023aa3 | ||
|
|
31650f01e7 | ||
|
|
0d471653b5 | ||
|
|
f615d0397d | ||
|
|
40e9172ab3 | ||
|
|
9033132143 | ||
|
|
1fc27eebda | ||
|
|
f4ddeda433 | ||
|
|
6210a7e832 | ||
|
|
e300b31be5 | ||
|
|
3073e45b0a | ||
|
|
d401bd337a | ||
|
|
1297b41b10 | ||
|
|
d44cb91306 | ||
|
|
efdc7749df | ||
|
|
e78a22e19c | ||
|
|
9cc19ec0f8 | ||
|
|
05c165deb2 | ||
|
|
f6a87ca58c | ||
|
|
73a3cf8afb | ||
|
|
d196b83ca6 | ||
|
|
35f2ea5da2 | ||
|
|
70028079b4 | ||
|
|
c14af5ffdf | ||
|
|
06b1396a2a | ||
|
|
5d3f247d7d | ||
|
|
404dd8e0c0 | ||
|
|
3a1ab48818 | ||
|
|
f5c2b636f3 | ||
|
|
b5ed7ff1b2 | ||
|
|
09007da395 | ||
|
|
d51ce47d86 | ||
|
|
6919447094 | ||
|
|
c3b7932544 | ||
|
|
82e409a434 | ||
|
|
0eb57cbe4d | ||
|
|
3531887941 | ||
|
|
e9ebde73bc | ||
|
|
469cd22f61 | ||
|
|
93e72c215d | ||
|
|
865478bcdc | ||
|
|
d6c0de7c85 | ||
|
|
0266ab8958 | ||
|
|
6b7ab73a52 | ||
|
|
61ee7c58cc | ||
|
|
ad7509e3b4 | ||
|
|
a62cc52aba | ||
|
|
f93e5dc844 | ||
|
|
8481f0e9cd | ||
|
|
82f7d61593 | ||
|
|
a42b32bdf1 | ||
|
|
79638b080c | ||
|
|
3474c58c9e | ||
|
|
d8cd93cabe | ||
|
|
48b79facfa | ||
|
|
e23f7f58f3 | ||
|
|
606bb1a13b | ||
|
|
e784980515 | ||
|
|
c33ee3f252 | ||
|
|
b0a958f55e | ||
|
|
237b03af18 | ||
|
|
f348991d21 | ||
|
|
e0745adbd2 | ||
|
|
1ddc924a67 | ||
|
|
0b07625567 | ||
|
|
0cabbf8ca8 | ||
|
|
ba9e089e35 | ||
|
|
31ff8677dd | ||
|
|
3e5e63956e | ||
|
|
57f9bc83d1 | ||
|
|
6e72472b60 | ||
|
|
9326f35380 | ||
|
|
19555579c8 | ||
|
|
60dd607312 | ||
|
|
c3b799ec63 | ||
|
|
4b6f4d0de5 | ||
|
|
fbfb3f591e | ||
|
|
b91799aa18 | ||
|
|
db1b54bf9f | ||
|
|
e9529744f8 | ||
|
|
d1f642a9df | ||
|
|
9261f1c47f | ||
|
|
991223abab | ||
|
|
801d44a6e4 | ||
|
|
44d7d89e19 | ||
|
|
aae23acff3 | ||
|
|
705595aaf6 | ||
|
|
43ec22429f | ||
|
|
36779df3bb | ||
|
|
3d3d801729 | ||
|
|
0f2ffee6f9 | ||
|
|
f4d37a2c0d | ||
|
|
be5596df1d | ||
|
|
e97f26bb5f | ||
|
|
ae13c96df8 | ||
|
|
d15dfdc387 | ||
|
|
631d8dcf03 | ||
|
|
192b96289f | ||
|
|
b8141713e8 | ||
|
|
3fedf6f8e7 | ||
|
|
6f6ebd454f | ||
|
|
ce42947cae | ||
|
|
84e285e4ce | ||
|
|
928c6a6043 | ||
|
|
106897fdf0 | ||
|
|
98d5648f6e | ||
|
|
9358e84588 | ||
|
|
958c18f0b7 | ||
|
|
089639e9fb | ||
|
|
85afd767f7 | ||
|
|
38006fb93b | ||
|
|
9ae1def963 | ||
|
|
6517900e5a | ||
|
|
5e51da600b | ||
|
|
f0b8d26c99 | ||
|
|
1724591029 | ||
|
|
80d29764a0 | ||
|
|
f498b1d308 | ||
|
|
8eabfd614e | ||
|
|
4acd7a3c8d | ||
|
|
a37822dffd | ||
|
|
1c6b28aa61 | ||
|
|
f15b4e408b | ||
|
|
d5f9d2b5d2 | ||
|
|
67a7069bb8 | ||
|
|
fd5d786538 | ||
|
|
c017b763f3 | ||
|
|
e796458763 | ||
|
|
2a9fbbc64d | ||
|
|
d6081d0cc4 | ||
|
|
e6c3a495ce | ||
|
|
93f292c3df | ||
|
|
780fb4a8f1 | ||
|
|
0d9ab37ba4 | ||
|
|
acffe44440 | ||
|
|
178f78fa14 | ||
|
|
1ab1ae0e70 | ||
|
|
9f8ca91b8b | ||
|
|
eec6c5a391 | ||
|
|
714c0bef1e | ||
|
|
e9b699dda1 | ||
|
|
5afe59d2fa | ||
|
|
8adf27b1ea | ||
|
|
aecd32075e | ||
|
|
290118cbbe | ||
|
|
d2e1e43a25 | ||
|
|
2161ff358b | ||
|
|
f338bc584f | ||
|
|
e6a132bf4f | ||
|
|
8625cc30db | ||
|
|
7cc3d7e467 | ||
|
|
b8ff5eec73 | ||
|
|
36a4871585 | ||
|
|
c85ebbb2ba | ||
|
|
3a3e13c3b5 | ||
|
|
14a00e1ffd | ||
|
|
bd707fa9c4 | ||
|
|
5e6b1840df | ||
|
|
d8e3a694f2 | ||
|
|
05e3462025 | ||
|
|
b83fe80968 | ||
|
|
5db0159c52 | ||
|
|
5f87c4137c | ||
|
|
ea94318ba3 | ||
|
|
3128789777 | ||
|
|
270207e5eb | ||
|
|
efe96640fc | ||
|
|
0137637c2c | ||
|
|
6adc045580 | ||
|
|
45c898c5ea | ||
|
|
95f8bd0daa | ||
|
|
2cc2519302 | ||
|
|
be13bba64c | ||
|
|
7111a698c0 | ||
|
|
8b9092a248 | ||
|
|
0aa05133a9 | ||
|
|
2952df5432 | ||
|
|
541e26b067 | ||
|
|
6018a6bb70 | ||
|
|
ca987b3842 | ||
|
|
67f8d28d7f | ||
|
|
f88abe99d7 | ||
|
|
6ddf27c5c3 | ||
|
|
aadd9387b2 | ||
|
|
0fd68c901d | ||
|
|
17a3943afe | ||
|
|
abc73e2443 | ||
|
|
3c1751e5c4 | ||
|
|
a32ef6afc4 | ||
|
|
127df8a6f0 | ||
|
|
aa91fd3e5e | ||
|
|
c8e97d97f9 | ||
|
|
67e3603ba4 | ||
|
|
f62617d7a6 | ||
|
|
9324184c24 | ||
|
|
a80ce0d251 | ||
|
|
c1c4a93f98 | ||
|
|
e74e6292ee | ||
|
|
25c3e92c2a | ||
|
|
9ab424172d | ||
|
|
28fd47e170 | ||
|
|
8250e40a75 | ||
|
|
f735c9a5c9 | ||
|
|
e7553b0168 | ||
|
|
12d276acd7 | ||
|
|
e6934bf0a5 | ||
|
|
6f5ad9dc0b | ||
|
|
a2019a4782 | ||
|
|
5d7b7718ec | ||
|
|
190877a24b | ||
|
|
144362b972 | ||
|
|
d353ac5108 | ||
|
|
a27a08904a | ||
|
|
5ef4e336ce | ||
|
|
78f2c46517 | ||
|
|
bdcb9e33a8 | ||
|
|
6e4e9df55f | ||
|
|
b3bed5658d | ||
|
|
a10ae91ba7 | ||
|
|
a8dbc7f107 | ||
|
|
4544156b44 | ||
|
|
b52e8c9c7c | ||
|
|
0ce1249b95 | ||
|
|
3932ed6baf | ||
|
|
981b636920 | ||
|
|
c8e15c731a | ||
|
|
901f932a89 | ||
|
|
c0a9580a65 | ||
|
|
8be91eea5d | ||
|
|
1c6f2252b8 | ||
|
|
58d130c5f3 | ||
|
|
091ea81e68 | ||
|
|
f036dce6ab | ||
|
|
2d58f1f94e | ||
|
|
86cfe0848b | ||
|
|
973d74e592 | ||
|
|
3909ebe03b | ||
|
|
65f42020af | ||
|
|
65a91ae976 | ||
|
|
7db08bfd90 | ||
|
|
af26553292 | ||
|
|
d5e431e7d4 | ||
|
|
54ba3ec377 | ||
|
|
656ef1c9a7 | ||
|
|
b8accd7273 | ||
|
|
238c31beaa | ||
|
|
eb31190f31 | ||
|
|
389d45e380 | ||
|
|
81b3a6e279 | ||
|
|
c50906373c | ||
|
|
40545fb680 | ||
|
|
2acc34dfdf | ||
|
|
ede68fd95d | ||
|
|
6c60c3dde3 | ||
|
|
ad505754fc | ||
|
|
21d81879e2 | ||
|
|
b5ca2ba614 | ||
|
|
ef4655fcf1 | ||
|
|
01b553a75d | ||
|
|
fae366a404 | ||
|
|
6129b1a15d | ||
|
|
31d03a1146 | ||
|
|
eabc7b5c12 | ||
|
|
1dc7569f95 | ||
|
|
1797e9c966 | ||
|
|
e2eaceb4cd | ||
|
|
c637b129ec | ||
|
|
8470e43d7f | ||
|
|
94f5950d68 | ||
|
|
fe69a17c9c | ||
|
|
6ca7a11d88 | ||
|
|
cfbb600fcb | ||
|
|
e36b550851 | ||
|
|
2232dc191c | ||
|
|
bdc688dd53 | ||
|
|
e0f6399d5c | ||
|
|
3e88ac6726 | ||
|
|
d0088f6c7c | ||
|
|
0d7c18cb39 | ||
|
|
d0e98416b9 | ||
|
|
b7438011b4 | ||
|
|
4e59d3bf19 | ||
|
|
e4b26aea4a | ||
|
|
473d0d55a7 | ||
|
|
8bd4649b01 | ||
|
|
a69df84325 | ||
|
|
0faebdefea | ||
|
|
a728e3abf3 | ||
|
|
e87c62fe72 | ||
|
|
4801818e3d | ||
|
|
b4a0577786 | ||
|
|
212232f80a | ||
|
|
11dcb44e41 | ||
|
|
af0df6ea2c | ||
|
|
9db91442b3 | ||
|
|
9d76070806 | ||
|
|
2fa580f1bb | ||
|
|
c6f15b768e | ||
|
|
779937ca87 | ||
|
|
731856e974 | ||
|
|
baf54631c7 | ||
|
|
3e760d7fed | ||
|
|
679f00dc9c | ||
|
|
dae5c142d7 | ||
|
|
8e8873286e | ||
|
|
6693cbdde3 | ||
|
|
8b3ce2cb1e | ||
|
|
94cae90d1e | ||
|
|
c4b07f5113 | ||
|
|
01d73028f8 | ||
|
|
862f1203ed | ||
|
|
581e81c16e | ||
|
|
6c166c9530 | ||
|
|
4181ede6cd | ||
|
|
10745be661 | ||
|
|
ee2d73c740 | ||
|
|
e7fbcf5333 | ||
|
|
2810eccc82 | ||
|
|
baff419091 | ||
|
|
d13e0fdfde | ||
|
|
5a300c3c64 | ||
|
|
d8ddb9630a | ||
|
|
1537eeb5fa | ||
|
|
1a492537dd | ||
|
|
bd4107b002 | ||
|
|
7b48cadf6d | ||
|
|
6eab8a7a0a | ||
|
|
c6d14e5b7d | ||
|
|
ce95cafd54 | ||
|
|
4024faceab | ||
|
|
1afa931248 | ||
|
|
2474c39311 | ||
|
|
f6460a7365 | ||
|
|
b47e00858e | ||
|
|
b200a13c8d | ||
|
|
e6fabdbb31 | ||
|
|
cdd654eab7 | ||
|
|
2f07b96333 | ||
|
|
62e74b2b18 | ||
|
|
e75693b131 | ||
|
|
3cd14d4696 | ||
|
|
d29cc9892c | ||
|
|
d996882f4e | ||
|
|
17b6aa856d | ||
|
|
c21a9cf121 | ||
|
|
d3c4342c15 | ||
|
|
b4c2f8e69c | ||
|
|
a0f72a4e35 | ||
|
|
24844002de | ||
|
|
593edeae21 | ||
|
|
6df770d261 | ||
|
|
4f0c9dcede | ||
|
|
52425a8ca9 | ||
|
|
454acebe5a | ||
|
|
6fcf91e934 | ||
|
|
f89b8f2b29 | ||
|
|
648a7ba577 | ||
|
|
7c5594c39d | ||
|
|
274e8212a6 | ||
|
|
36c6ddaf86 | ||
|
|
15ed72bc09 | ||
|
|
ace8de93a9 | ||
|
|
45a4c0a284 | ||
|
|
c5e1e8abc0 | ||
|
|
ef38b69c39 | ||
|
|
ac6bde9996 | ||
|
|
23568cc0ba | ||
|
|
e61c2cfae7 | ||
|
|
38e0b11995 | ||
|
|
31903d1a80 | ||
|
|
3655284b57 | ||
|
|
db79a96118 | ||
|
|
5152e1fc63 | ||
|
|
c04e137b28 | ||
|
|
9b3342fbff | ||
|
|
d9a060a12d | ||
|
|
77f2fdd09a | ||
|
|
dba1ef6104 | ||
|
|
725da55905 | ||
|
|
cfac551ab8 | ||
|
|
c559fdbf04 | ||
|
|
e2ac47cd06 | ||
|
|
8ef16d9efb | ||
|
|
b6f726654e | ||
|
|
8cbb84c50f | ||
|
|
f3eac0c958 | ||
|
|
3211cfbbb1 | ||
|
|
c6934f5eab | ||
|
|
f8c054b879 | ||
|
|
ad2a64c82b | ||
|
|
9e0028fe73 | ||
|
|
dfbd01a980 | ||
|
|
86737955de | ||
|
|
7f0b027486 | ||
|
|
4d04ea079f | ||
|
|
6e1c41b536 | ||
|
|
275232f8c8 | ||
|
|
c8f9560aa3 | ||
|
|
315ee56024 | ||
|
|
e446ba0738 | ||
|
|
2ccd40677d | ||
|
|
41ef2a8cd2 | ||
|
|
d8acd1354f | ||
|
|
e28cfd1ad5 | ||
|
|
e5f5e64cdb | ||
|
|
b55d88dc15 | ||
|
|
f3360cbf66 | ||
|
|
065b621604 | ||
|
|
fd87df475c | ||
|
|
c7b6792956 | ||
|
|
1f2d11003d | ||
|
|
6432f11a6b | ||
|
|
7d53fb5951 | ||
|
|
b9aa3ef97d | ||
|
|
c271497ecb | ||
|
|
e05c4645ac | ||
|
|
63d8e6e21b | ||
|
|
5bd59b0d8c | ||
|
|
464e152783 | ||
|
|
91406b0c4c | ||
|
|
04e81270cb | ||
|
|
69c6695765 | ||
|
|
9e0e050f92 | ||
|
|
b2efcf36c8 | ||
|
|
ba39abfb19 | ||
|
|
f47e1f71ee | ||
|
|
6d980b4eab | ||
|
|
ca18e8e2f6 | ||
|
|
ec436d7b33 | ||
|
|
38a511f6ba | ||
|
|
15ac1ffdd1 | ||
|
|
eb977ba237 | ||
|
|
9a6b1c3bbb | ||
|
|
95443e742c | ||
|
|
0c94db2d6b | ||
|
|
9808551eed | ||
|
|
b6fe5b08d3 | ||
|
|
5309811a09 | ||
|
|
3b6c198715 | ||
|
|
57bfa41b33 | ||
|
|
474266c0b5 | ||
|
|
c891470344 | ||
|
|
e6004da801 | ||
|
|
e18b1a884a | ||
|
|
faeb0914b2 | ||
|
|
d6578df998 | ||
|
|
f010513d17 | ||
|
|
d4be9602e3 | ||
|
|
7676690697 | ||
|
|
f4b9b6d0b3 | ||
|
|
7a3d155675 | ||
|
|
68b6388ef7 | ||
|
|
547e9768ec | ||
|
|
8608cf5b48 | ||
|
|
a08ddedb88 | ||
|
|
398366a615 | ||
|
|
7dfa3f2b48 | ||
|
|
2e7325ce03 | ||
|
|
cb74386ef0 | ||
|
|
87d6c588a6 | ||
|
|
df8a2d35a8 | ||
|
|
c4da547503 | ||
|
|
7bd55e33b5 | ||
|
|
256ace38d7 | ||
|
|
4c20d5d85c | ||
|
|
ac43c67a47 | ||
|
|
d2d68a7e44 | ||
|
|
27aee19a35 | ||
|
|
2a6bd1636f | ||
|
|
7b82e29e7e | ||
|
|
4fd2f06a0d | ||
|
|
8016dffe18 | ||
|
|
10004da36f | ||
|
|
633e06a7c7 | ||
|
|
660350c9b1 | ||
|
|
9122aa6cf4 | ||
|
|
56c89866a2 | ||
|
|
f9be4e543a | ||
|
|
042b82e2af | ||
|
|
9176896742 | ||
|
|
4ea0c66bec | ||
|
|
ae4542abf0 | ||
|
|
ac14d347de | ||
|
|
c2143c5843 | ||
|
|
e79ffc6ae8 | ||
|
|
a56c2341cf | ||
|
|
1c14586cde | ||
|
|
2b995fda44 | ||
|
|
5d68b48af3 | ||
|
|
f90a00b564 | ||
|
|
4bc7c13310 | ||
|
|
771055fd59 | ||
|
|
75c70bf804 | ||
|
|
c5f34a6704 | ||
|
|
463871a307 | ||
|
|
fa1080d066 | ||
|
|
52cfad1d08 | ||
|
|
9e294f5910 | ||
|
|
9f8326de56 | ||
|
|
79c3f99165 | ||
|
|
d4925443c8 | ||
|
|
fa27d32bfe | ||
|
|
230a52e3e3 | ||
|
|
15dedda59a | ||
|
|
3b45fb91e3 | ||
|
|
f378319395 | ||
|
|
98173b3aa6 | ||
|
|
36340c8f2f | ||
|
|
77b6d90a16 | ||
|
|
6b3bd46fa8 | ||
|
|
8485f88158 | ||
|
|
d2baa9e675 | ||
|
|
7fa9c802f5 | ||
|
|
8f1bc74e26 | ||
|
|
8de38be418 | ||
|
|
ec1ebd4686 | ||
|
|
81ddfbed88 | ||
|
|
63814f1eaf | ||
|
|
38a36add57 | ||
|
|
9e39927ac6 | ||
|
|
0ba9dda0f0 | ||
|
|
a24f9a2c92 | ||
|
|
f57158a893 | ||
|
|
1e3bf42464 | ||
|
|
9d6a75fbab | ||
|
|
6fa52ae7cc | ||
|
|
bb9c459a1a | ||
|
|
432c76a9d9 | ||
|
|
1cdf315bfa | ||
|
|
777601a0ea | ||
|
|
35d170018e | ||
|
|
af2e99ef45 | ||
|
|
734befb555 | ||
|
|
64c8d618a2 | ||
|
|
92bb4ea6fc | ||
|
|
98b025da72 | ||
|
|
af7717412f | ||
|
|
68c2a18f6f | ||
|
|
ea49078ffd | ||
|
|
b902d7310a | ||
|
|
3591560b34 | ||
|
|
949029ca89 | ||
|
|
cde0894711 | ||
|
|
342e9f80db | ||
|
|
96b0f4aab7 | ||
|
|
3af6a546ac | ||
|
|
6e086c4297 | ||
|
|
db08fc0564 | ||
|
|
dbb6d4cc5f | ||
|
|
d0f44da4c2 | ||
|
|
cb6b01cc5d | ||
|
|
392d79b9e2 | ||
|
|
f8e609d4bf | ||
|
|
573bf46fd1 | ||
|
|
d65592bbcc | ||
|
|
169a137e7f | ||
|
|
bd61f2d2f7 | ||
|
|
793bbc793f | ||
|
|
4aa7be2dbf | ||
|
|
35531233d9 | ||
|
|
54949bd62a | ||
|
|
e95a8a7158 | ||
|
|
de0a70a835 | ||
|
|
9f8feca926 | ||
|
|
c50187559b | ||
|
|
c2cf6327c2 | ||
|
|
1ea773ddfb | ||
|
|
79a8983bac | ||
|
|
7d5ed837a4 | ||
|
|
60267523e9 | ||
|
|
8153da6e9c | ||
|
|
5f6fb388ec | ||
|
|
ba49396755 | ||
|
|
40240cb5ee | ||
|
|
bba926693e | ||
|
|
9103834503 | ||
|
|
7e3c740592 | ||
|
|
35a59746df | ||
|
|
23b5ce3264 | ||
|
|
03c53d2978 | ||
|
|
695449d73d | ||
|
|
6bad1e7194 | ||
|
|
77dec1461b | ||
|
|
14d77f59d4 | ||
|
|
afb598cf15 | ||
|
|
b4c6fe92e0 | ||
|
|
f50577be1c | ||
|
|
c358ae9310 | ||
|
|
9554258d02 | ||
|
|
95ee2cc30e | ||
|
|
79a35f0c27 | ||
|
|
7a021cda9e | ||
|
|
447f7a04cb | ||
|
|
e5b62cbc7c | ||
|
|
6739a34f74 | ||
|
|
e502bf29de | ||
|
|
51b504bf99 | ||
|
|
107d582e7b | ||
|
|
ea42ed406f | ||
|
|
c869812875 | ||
|
|
4f7ce9c195 | ||
|
|
847687a637 | ||
|
|
94389137e8 | ||
|
|
98e6ba9378 | ||
|
|
e288db29a8 | ||
|
|
98aeee9b1d | ||
|
|
45a2aa8495 | ||
|
|
4b350987a1 | ||
|
|
3b2b754fe5 | ||
|
|
64e7afea98 | ||
|
|
16765c19cf | ||
|
|
87d916fc24 | ||
|
|
21b59fab5d | ||
|
|
9272e1e556 | ||
|
|
0a51dabb17 | ||
|
|
8c1cee4e00 | ||
|
|
4d5315e2ca | ||
|
|
88cc9bb363 | ||
|
|
80e41ee14c | ||
|
|
23489f3f18 | ||
|
|
a998ddc9d4 | ||
|
|
833963c1c1 | ||
|
|
4b11f87f80 |
No files matched your search
@@ -0,0 +1,3 @@
|
|||||||
|
# These are supported funding model platforms
|
||||||
|
|
||||||
|
github: [zricethezav]
|
||||||
@@ -0,0 +1,29 @@
|
|||||||
|
---
|
||||||
|
name: Bug report
|
||||||
|
about: Create a report to help us improve
|
||||||
|
title: ''
|
||||||
|
labels: bug
|
||||||
|
assignees: ''
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
**Describe the bug**
|
||||||
|
A clear and concise description of what the bug is.
|
||||||
|
|
||||||
|
**To Reproduce**
|
||||||
|
Steps to reproduce the behavior:
|
||||||
|
|
||||||
|
**Expected behavior**
|
||||||
|
A clear and concise description of what you expected to happen.
|
||||||
|
|
||||||
|
**Screenshots**
|
||||||
|
If applicable, add screenshots to help explain your problem.
|
||||||
|
|
||||||
|
**Basic Info (please complete the following information):**
|
||||||
|
- OS:
|
||||||
|
- Gitleaks Version:
|
||||||
|
|
||||||
|
**Additional context**
|
||||||
|
Add any other context about the problem here.
|
||||||
|
|
||||||
|
cc @zricethezav
|
||||||
@@ -0,0 +1,22 @@
|
|||||||
|
---
|
||||||
|
name: Feature request
|
||||||
|
about: Suggest an idea for this project
|
||||||
|
title: ''
|
||||||
|
labels: enhancement
|
||||||
|
assignees: ''
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
**Is your feature request related to a problem? Please describe.**
|
||||||
|
A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]
|
||||||
|
|
||||||
|
**Describe the solution you'd like**
|
||||||
|
A clear and concise description of what you want to happen.
|
||||||
|
|
||||||
|
**Describe alternatives you've considered**
|
||||||
|
A clear and concise description of any alternative solutions or features you've considered.
|
||||||
|
|
||||||
|
**Additional context**
|
||||||
|
Add any other context or screenshots about the feature request here.
|
||||||
|
|
||||||
|
cc @zricethezav
|
||||||
@@ -0,0 +1,16 @@
|
|||||||
|
---
|
||||||
|
name: Maintenance request
|
||||||
|
about: Suggest an idea for this project
|
||||||
|
title: ''
|
||||||
|
labels: enhancement
|
||||||
|
assignees: ''
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
**Describe the solution you'd like**
|
||||||
|
A clear and concise description of what you want to happen.
|
||||||
|
|
||||||
|
**Additional context**
|
||||||
|
Add any other context or screenshots about the feature request here.
|
||||||
|
|
||||||
|
cc @zricethezav
|
||||||
@@ -0,0 +1,8 @@
|
|||||||
|
### Description:
|
||||||
|
Explain the purpose of the PR.
|
||||||
|
|
||||||
|
### Checklist:
|
||||||
|
|
||||||
|
* [ ] Does your PR pass tests?
|
||||||
|
* [ ] Have you written new tests for your changes?
|
||||||
|
* [ ] Have you lint your code locally prior to submission?
|
||||||
@@ -0,0 +1,13 @@
|
|||||||
|
name: gitleaks
|
||||||
|
on: [pull_request, push, workflow_dispatch]
|
||||||
|
jobs:
|
||||||
|
scan:
|
||||||
|
name: gitleaks
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v3
|
||||||
|
with:
|
||||||
|
fetch-depth: 0
|
||||||
|
- uses: gitleaks/gitleaks-action@v2
|
||||||
|
env:
|
||||||
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||||
@@ -0,0 +1,57 @@
|
|||||||
|
name: Create and publish a Docker image
|
||||||
|
|
||||||
|
on:
|
||||||
|
release:
|
||||||
|
types: [published]
|
||||||
|
|
||||||
|
env:
|
||||||
|
REGISTRY: ghcr.io
|
||||||
|
IMAGE_NAME: ${{ github.repository }}
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
build-and-push-image:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
permissions:
|
||||||
|
contents: read
|
||||||
|
packages: write
|
||||||
|
|
||||||
|
steps:
|
||||||
|
- name: Checkout repository
|
||||||
|
uses: actions/checkout@v2
|
||||||
|
|
||||||
|
- name: Set up QEMU
|
||||||
|
uses: docker/setup-qemu-action@8b122486cedac8393e77aa9734c3528886e4a1a8
|
||||||
|
|
||||||
|
- name: Set up Docker Buildx
|
||||||
|
id: buildx
|
||||||
|
uses: docker/setup-buildx-action@dc7b9719a96d48369863986a06765841d7ea23f6
|
||||||
|
|
||||||
|
- name: Log in to Docker Hub
|
||||||
|
uses: docker/login-action@49ed152c8eca782a232dede0303416e8f356c37b
|
||||||
|
with:
|
||||||
|
username: ${{ github.actor }}
|
||||||
|
password: ${{ secrets.DOCKER_PASSWORD }}
|
||||||
|
|
||||||
|
- name: Log in to the Container registry
|
||||||
|
uses: docker/login-action@49ed152c8eca782a232dede0303416e8f356c37b
|
||||||
|
with:
|
||||||
|
registry: ${{ env.REGISTRY }}
|
||||||
|
username: ${{ github.actor }}
|
||||||
|
password: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
|
||||||
|
- name: Extract metadata (tags, labels) for Docker
|
||||||
|
id: meta
|
||||||
|
uses: docker/metadata-action@98669ae865ea3cffbcbaa878cf57c20bbf1c6c38
|
||||||
|
with:
|
||||||
|
images: |
|
||||||
|
zricethezav/gitleaks
|
||||||
|
${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}
|
||||||
|
|
||||||
|
- name: Build and push Docker image
|
||||||
|
uses: docker/build-push-action@e551b19e49efd4e98792db7592c17c09b89db8d8
|
||||||
|
with:
|
||||||
|
platforms: linux/amd64,linux/arm64
|
||||||
|
context: .
|
||||||
|
push: true
|
||||||
|
tags: ${{ steps.meta.outputs.tags }}
|
||||||
|
labels: ${{ steps.meta.outputs.labels }}
|
||||||
@@ -0,0 +1,26 @@
|
|||||||
|
name: Test
|
||||||
|
|
||||||
|
on:
|
||||||
|
pull_request:
|
||||||
|
branches:
|
||||||
|
- "*"
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
test:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v2
|
||||||
|
|
||||||
|
- name: Set up Go
|
||||||
|
uses: actions/setup-go@v2
|
||||||
|
with:
|
||||||
|
go-version: 1.18
|
||||||
|
|
||||||
|
- name: Build
|
||||||
|
run: go build -v ./...
|
||||||
|
|
||||||
|
- name: Test
|
||||||
|
run: make test
|
||||||
|
|
||||||
|
- name: Validate Config
|
||||||
|
run: cd cmd/generate/config && go run main.go
|
||||||
+20
@@ -0,0 +1,20 @@
|
|||||||
|
# Binaries for programs and plugins
|
||||||
|
*.exe
|
||||||
|
*.exe~
|
||||||
|
*.dll
|
||||||
|
*.so
|
||||||
|
*.dylib
|
||||||
|
*.DS_STORE
|
||||||
|
*.idea
|
||||||
|
*.got
|
||||||
|
gitleaks
|
||||||
|
build
|
||||||
|
|
||||||
|
# configs
|
||||||
|
.gitleaks.toml
|
||||||
|
cmd/generate/config/gitleaks.toml
|
||||||
|
|
||||||
|
# Test binary
|
||||||
|
*.out
|
||||||
|
|
||||||
|
dist/
|
||||||
+653
@@ -0,0 +1,653 @@
|
|||||||
|
8656cc293af402e7ceb6ced7e46e414eaa10580a
|
||||||
|
45b529c43aeb51d2ff6a3f2d41a02f7f198c9596
|
||||||
|
6a9d4871efd8f3f633be13207e106f1eb737d3c8
|
||||||
|
e10031fcb03002201520cf816ca6181e766d4aef
|
||||||
|
ecfa2585fcc57efc6b7fadc79751edf7ce813314
|
||||||
|
f83d359c45ca2ccd505bd849c78ac406a5352548
|
||||||
|
d05ca0b9c00691d20ac898ccfb5f651f369d0e46
|
||||||
|
7599de90a03099fb94725bed3704888eb3410c9b
|
||||||
|
5497f8b33c6de81a8ae6b5f0fc11f06318d4e412
|
||||||
|
eafd668f0b403b85a7fa10ea965971bf92d516e4
|
||||||
|
d2d135e115c346aa8ac995e82855a9a92a89ae0e
|
||||||
|
b23fd6198cd9c60affa7bb51f14f4679815ed286
|
||||||
|
7c075749875143ad5eb162b8c9dd56cf2460d50e
|
||||||
|
89166396f3d6a3c1a7841e7c354c0e9a0b4ea3f0
|
||||||
|
cce986b1baccd43bd30bd92a6cda0ed6982135f1
|
||||||
|
d7f34ff7ef2e878e797526da2159269a4553c872
|
||||||
|
61f3533994a70eff4183343f9b516fb8ef720c93
|
||||||
|
20eadcbf3c32e60875d31ab9125cb4ab72317bef
|
||||||
|
24e720ae74cd710640f1be726cd1965fadcbb359
|
||||||
|
24e720ae74cd710640f1be726cd1965fadcbb359
|
||||||
|
70d7d00365746c6f9081fcb2a382f4b04e3e36e2
|
||||||
|
920e6e754820b0c29b9ac94de567b09988279599
|
||||||
|
59f5b5a3ec2888d7be7d193ee9784175b98926e1
|
||||||
|
656434da2ec14d1f51edc5fa74dc5d2d08706f67
|
||||||
|
837fa0e0d223e7fa1796d31956e652aee935f013
|
||||||
|
f378fe53d5c1688bf32f2a208d4a047808105bed
|
||||||
|
b2eb017e5806e56a645d8c0b1764b21b23d175a7
|
||||||
|
2ba33e2800af6945b5ce648521646277103a0975
|
||||||
|
845a01eda57d9808314db564f880bad2aa633bea
|
||||||
|
66d1439830a50eecae9e28d9652e247f3ac4984c
|
||||||
|
22cdfe655be3e44d85a7fdb638af5ee26ee2422d
|
||||||
|
0f3f4c27c6704694f8f3264de8c65fe4370d53c2
|
||||||
|
4bf2469fb58ad3e8e497bd42767c13d6ad6cd01d
|
||||||
|
1bcd1da32d94b88094269bfc60c4f59d8bdeac1b
|
||||||
|
50340bfd6c5c8d7c58926d33936bac76ea2df9bc
|
||||||
|
878b808b2d4631f5895783529287faf93b2726a7
|
||||||
|
0456c652586bec4dcc1eee5428987cd6d748e896
|
||||||
|
6d223fcac49bd96ed5e2a303fea6be0a04985014
|
||||||
|
b6bf1f2ebe0d6f10a7ec34188e9636052efafc6c
|
||||||
|
3840f62e06d74ff175ea5a8312ad509bd9769351
|
||||||
|
d8f974bbe4ebe23b8f387f8d47d4fc61c75598c2
|
||||||
|
63883ded02136bbefad8edd5336da69f41e0bcb2
|
||||||
|
84402c1d0abdf8ec80ef23f88b1caf5fdf4b1566
|
||||||
|
8500a762bed92fa8ce40486c78ad404fc227067b
|
||||||
|
f9d3a00843fccd9055761aa835631785ef01cfa3
|
||||||
|
4f6792ab2db5f4ccab1f856d49f42f26efe1e89e
|
||||||
|
56492efd6e62cd8bb68b818a611f1ad8991b4153
|
||||||
|
0e8876db1228a44a44b91aceb3e07fb8f58cb0cd
|
||||||
|
6ded6a326a6992a183d1e9de0f93e4ca27e47621
|
||||||
|
f795edeb5dd8ae1467b11f8df7bc8e363ae7166e
|
||||||
|
6131f865b3306a7c56245f84dd71c2c8046ab361
|
||||||
|
29d12c5fb8fac880459c85bb706a0758e86f300a
|
||||||
|
590b619b6c76d4e4188bdc6859d33b7a22c8a616
|
||||||
|
b4debfecf0c0856b5723985a46716e9e49c54b7b
|
||||||
|
19d26c58a914b557057e5bd9e00a487aa5182fdd
|
||||||
|
68de55079e97cf5ff6dc803411f95359feb29c7b
|
||||||
|
2d15093e1d1ea78e60742fa0521e7aeb8d094dc5
|
||||||
|
2a6d2e5b879453b39d6a0ea0e6f51474e5a2fa9a
|
||||||
|
90a904d1f08c9e19324b04aaa2e5ccedaf4cd933
|
||||||
|
d36b9a3a50d2cc8f197b9a7f071f0fabb2996808
|
||||||
|
923919d7658e394e2448216dd97ecb826490a42d
|
||||||
|
105dee3ba3319c012bf15458be218ca6dbd360f1
|
||||||
|
daf6941c98ddc345836f4df9c03fbf6e8371bba0
|
||||||
|
f0f00ddf38946a666805c22ee4bdbdfeb0fdd186
|
||||||
|
9502ce49a6a07515a1c1826342c1fee5d2afeadf
|
||||||
|
3cc64ba8557f6d054f9c63fe225c6d971314c2d8
|
||||||
|
3fb0787f3468a5cd57b75df04634fa7a3a2d2eb3
|
||||||
|
4983563275c91a5ed9a7558b61011d1e106aa47e
|
||||||
|
2994f3863c011cc6874bb656b87a6b793db28213
|
||||||
|
f9d3a00843fccd9055761aa835631785ef01cfa3
|
||||||
|
66337c40e03e2ed82382eb679be1f06912e5c927
|
||||||
|
665f66e005b30d048bc71224a1364e7bdeb66df5
|
||||||
|
bcc0221ce5dbb136567c55ee42acb3e0d313f08b
|
||||||
|
e67945c4c4a0ca3d435eb8caa4a4b349d53fa4a5
|
||||||
|
6cb1f4876acb9b44b2e2f165b453d42afc8e1219
|
||||||
|
6e7c436c45d49b2676a3704e7df95d4ba530c675
|
||||||
|
1b4d1aa84a0264620e12c404699d59bc776d486e
|
||||||
|
7647cf080c6bf681e5b10d23ebbfacbf2c613ef4
|
||||||
|
b2eee866b7c6c76862a9100a44e496ca98558573
|
||||||
|
96ba18cdaa05323ada9ffbd8261b17c1bd9ff00c
|
||||||
|
dceccb04506f7020fe9b67bcfb2d7afa36b7eecf
|
||||||
|
a1b7928343b0477ea2c6b8b2445b262073c4a49e
|
||||||
|
bf462c7b3d9e85102c652dedff15e586dec6f4c1
|
||||||
|
49c9b547afaf145c63fca614f5a3e762495f09b5
|
||||||
|
a1eaad75316bf370083a6bb76f7f35cdaec0c1e5
|
||||||
|
9fbb3bd773b29ae4df2e09b12b9fcc5448fc8360
|
||||||
|
011844370ce89f1973c9d80809b4eb06411f139f
|
||||||
|
1d3b4f7ccedab21f854d8711654cc613831a1118
|
||||||
|
a69862b4e3406570d74ee4e2d7dd863f16b7fb17
|
||||||
|
11848fd18b1772c0584f1590fd80f6ff36a228ae
|
||||||
|
5741f362f3769f10719ab5406afed302b8df1e95
|
||||||
|
efab13882a0c8ae529f8a39458a158505f63ea80
|
||||||
|
101f20cc18ec9cb72d185e47e2da661efab9109f
|
||||||
|
50ca343374c58f57f83da0ebff8445dd390c1733
|
||||||
|
cfde569ad1c4b3edf517a986c1ac96990c258353
|
||||||
|
24e720ae74cd710640f1be726cd1965fadcbb359
|
||||||
|
a1eaad75316bf370083a6bb76f7f35cdaec0c1e5
|
||||||
|
b2780c8889c3825f4f392e80e02c6029ece40b93
|
||||||
|
9fbb3bd773b29ae4df2e09b12b9fcc5448fc8360
|
||||||
|
d7bd4230e4d5f43bb1d5004edafa9835affdae27
|
||||||
|
1c5081ff4518a9ff9b4bc008e70d3da0679b1315
|
||||||
|
fdc7ec908b9709ce61ab123041958987a44595cd
|
||||||
|
5aee1920b415df35f887ce12eae6f2162f488b80
|
||||||
|
1b4d1aa84a0264620e12c404699d59bc776d486e
|
||||||
|
d39ff83940311147d094380ad4cc136e662bf512
|
||||||
|
276ead08acb0953bcdd990e138d01dfcce6c1b55
|
||||||
|
011844370ce89f1973c9d80809b4eb06411f139f
|
||||||
|
bf0e5b0b8458ca5a91da8def5eff2924dc4172f3
|
||||||
|
efab13882a0c8ae529f8a39458a158505f63ea80
|
||||||
|
149c663a7a3611ba9ed15093f0f52e94001a1ee1
|
||||||
|
0064094c34fdb036d15617cded9dadd812327953
|
||||||
|
4af38de80134934c4ca7514c927405367e3f3fee
|
||||||
|
e11e1c812cfcc969d350822046acfb211c0e9164
|
||||||
|
6f63a86cd8190bbe0176afdcabeabbbe14d7b69c
|
||||||
|
5da2d2c9f8b880a6fd5dfd023125eb39b769e7c0
|
||||||
|
695825fa48e0b7fd3e3bf42495e947ca327866cb
|
||||||
|
0547070c24aea64e4a4d394a9133c6fc5b3182c4
|
||||||
|
b2a1eebde836b7ef2dccb9670c4da065d55b39d7
|
||||||
|
6163425830de08fc8b0834d4fa8ca784d79fef69
|
||||||
|
43442bb0fa5fd5309fdc9c297cf042e2ac24e8b8
|
||||||
|
94870c87d178f4150ed3d3f0d8ab50fd53cf759b
|
||||||
|
56801e445479a9985b2a749054ca0bd59689917f
|
||||||
|
9d3497c1a259ca1a180109726f6a0cda12fe1fe8
|
||||||
|
5129f575eca472a2849c329e4ff6d3a79b0316f1
|
||||||
|
0996aaa1d78bfeba6971ffb070e53d624d3db4a5
|
||||||
|
67432867949cc2a42f65ecb24d8da1c2a09e5ce1
|
||||||
|
6cf692a655e1c846f2501a73c87cddb21906bbfb
|
||||||
|
df8e0c0e697206e4392a3996c64d82daa2adda53
|
||||||
|
450e434158643f8585bf7e4bdf192c3694881a96
|
||||||
|
c1236f3c26106e3f798e3f5178a56d81d4e26b56
|
||||||
|
d32c483608ac98220b898ad1beea1d86cfce7ce7
|
||||||
|
58735a17bff3f6543bb3f7524d0dbb7eec3bfb40
|
||||||
|
bbf918e3b32a8492487566ab48cdab4126ac14cf
|
||||||
|
e6b31b51beb35a2fcc26c0f95f4d58f435b29e3d
|
||||||
|
a1da2890efbf003acfeba2dda8280867d2e2d522
|
||||||
|
1b41a3d3b77da3ec2d0258e9785c5f6abbe177d6
|
||||||
|
a761e4447a8eaefbb1f185f7ab0db2a1a608c7a0
|
||||||
|
577580802e7cc47d663e7987b8ac5c0ac01384c5
|
||||||
|
c1f390ed2913853905a6ab32a7e9a0f156fb6420
|
||||||
|
d1d508bd130081bdfc2094791f9e2be432ed8875
|
||||||
|
a665d7534b36bbdbb0a67351bbc20fba5eb8b34e
|
||||||
|
63628bebc1ab0d6778daf29d2fe70afeeaa5986b
|
||||||
|
2e3020fc4d780c45179f3f6c38855dc7fc03ee8f
|
||||||
|
8285db5920b43d767790b452dd7309a49b55c094
|
||||||
|
bb831e30d8d713d4de52ea65f581f0f360fb25f8
|
||||||
|
ea3bc6103c9e881e2b7c00f076c07dee577abc7d
|
||||||
|
b328312c7328508246a2ce0a9f2aa44ee619c87c
|
||||||
|
c024909e43a01473ac6a090159eb49b7eceed939
|
||||||
|
7da51cf58cd6d4ac241c9a2a5ab8ce3f4d7b4055
|
||||||
|
59a78f51b0adf7cda2ded2c06145459c210b24cc
|
||||||
|
8c23f8e87cbfda15af45512cc8c97d0f24ee1708
|
||||||
|
d955f1f8b9636eb0cedbedd73bb829ac278ee76e
|
||||||
|
e51c04ee8e17cfe4fe6369edad2e975736df0497
|
||||||
|
10919239c91e5c696ff7d4f0d48d0eac6a354f55
|
||||||
|
4ea2354ff7786526e42ecf215276a9c89c1dcef8
|
||||||
|
225ef190a71bdb37e7894e5598f8b43e4b9a2aac
|
||||||
|
ff9a3583784717e2ac340beb9b510abf9bc0dbb3
|
||||||
|
efa49ccd7904af825fb5b790c3bd1ae47da867a4
|
||||||
|
9bfe51eaff52f93b2f86c03fc47bc2fa43ed631c
|
||||||
|
ee65ce6f83d3affee8e7cffef9c9af9147920acb
|
||||||
|
f01a37da32d0a4f3069d138c6a8bc27415ac01c5
|
||||||
|
1da23ea0221b5f79cfe22ed5348e35f2a31c2301
|
||||||
|
b2040bdb3ebbdc1cb05f73174a2206cc4c3e0de4
|
||||||
|
9fe2b908f4402097a10fadb64d766221a0302fc5
|
||||||
|
b55919dbb9a7a20167dc2c7f64dfb1186743d954
|
||||||
|
cf22fba89a4e934a4ce812e7e2ffdd0fc00931b7
|
||||||
|
af54c51cdb8fe4c8c1263ebad110ca941a4162eb
|
||||||
|
26215f2ef006c804d2882f26eb5a4d4e8da63fd9
|
||||||
|
861a048729daf36d1371ce7889e46022f1b52666
|
||||||
|
2c29d89dda12713aa423f69be4b56a32c60afece
|
||||||
|
69101efa97fb6a31489099f97ca4b94b524ba98f
|
||||||
|
60a68a6eb7357986fa4e219051580be615a92af7
|
||||||
|
5744d957a3189c0678271de07327e24368cdc388
|
||||||
|
d85cb8c914348f279ad277a51018a13d894cdd5c
|
||||||
|
4242fc70096c44be514b9cb2901dda7c481d004e
|
||||||
|
aa8fc3c7e943fee0de1d827bda60d29e01d41257
|
||||||
|
974339b23f0d1887e99a109605ade66873e03e76
|
||||||
|
667b02a4625a4e887c446c2dfa1ee8fc6ad48e4f
|
||||||
|
1a179404d34790a33968e75d18000051da788ac1
|
||||||
|
7b8d8229ebfe8975bf588daeef23ab028c171c77
|
||||||
|
9ff2611468cb5d69a9f45d0a377383bc431acbce
|
||||||
|
25a983b662281383b467727fbf25ccb2400a3233
|
||||||
|
a370878c45ae17b90ebe32145e45962077431df8
|
||||||
|
20a03c2c8ba119cb7450f628cd91b48ee3fede9d
|
||||||
|
e8d9bd2ccc9cec6ed46ceca4eda813406c7f5c5a
|
||||||
|
6229236a6826f8e80b21e07b89103256addd5606
|
||||||
|
071f1aa1a3ffd3158e9ab7cfa42d3f5fb4659ff7
|
||||||
|
3cd2e47f545fbd0ec1686ba0fb182f2a23538af3
|
||||||
|
e602e4516cd3fc1de82352c251511f10050cb623
|
||||||
|
b18c27d6d8a9b26a1d038774030428d00eb5c078
|
||||||
|
32d690b1493899bcb00d70a6dfecc79cdcb4346c
|
||||||
|
ba2e3efea88a91ac27e1145fa5ba9d47951429df
|
||||||
|
b9d0cccd3fabc9c967974e9aa573704f72c9367d
|
||||||
|
c0ee8bac542325503962d2d5cbe7734fc3d35ffc
|
||||||
|
942deeb6dde57f32928bba86266c6a2cb180b1ae
|
||||||
|
b6eac06026e6c7622dac0ddfd366a4d31913fac4
|
||||||
|
d1b27799601a9cb6bddd79972abe28546a468331
|
||||||
|
e405b9ea7be88bf56ed3d54dececd0d8fdfeae4b
|
||||||
|
b3a4ce34d34940479f10ad283867f8479d160848
|
||||||
|
b721a924696758e3c59fe2526ea64aee7e5a7142
|
||||||
|
301de6402305c92444f72c4100f1cdc6f5a8a80e
|
||||||
|
5e1c236e8fc251fbfb3516a6c67bbae797064350
|
||||||
|
114148673088beb5f2ded0105e960d123f0557e8
|
||||||
|
82aeea0fc1ed0a5a8d64568fc0c4ae2e7baa2137
|
||||||
|
20c160a4cb7b095e310f3b35ce00ca73dafe4503
|
||||||
|
8f7a779692814e022183d0b03107964c6af5726b
|
||||||
|
e8d9bd2ccc9cec6ed46ceca4eda813406c7f5c5a
|
||||||
|
6229236a6826f8e80b21e07b89103256addd5606
|
||||||
|
071f1aa1a3ffd3158e9ab7cfa42d3f5fb4659ff7
|
||||||
|
3cd2e47f545fbd0ec1686ba0fb182f2a23538af3
|
||||||
|
4f3cef974f7059a4a83680d4802ba845f58b97fc
|
||||||
|
7f850a4383e12b63efeaf9c30d9dd70a9a88b3c9
|
||||||
|
e602e4516cd3fc1de82352c251511f10050cb623
|
||||||
|
f0c9acde0360ab4c551e753c281967d61fc12173
|
||||||
|
2ac249303340fba15cfd8bedb6f5c237a5fe0504
|
||||||
|
a71aa259a475041e809d2a1c8ea08d50dbfa4c35
|
||||||
|
4a4df199566ea8107df3032889cdeafc1073bbb1
|
||||||
|
b5f8a3d03fd20f47ae73f8b5f249e90e8aecd91b
|
||||||
|
7d73f7a38c9e10f9436e8bca5f1507855f5cf041
|
||||||
|
43aa054d56f0007af32b9fa0db452bb960d72de3
|
||||||
|
6ddc1b9b3c1c0d34d1e4a317f5bd7e64b85fbf9b
|
||||||
|
17a9d74a79ed8600e071d4442e6a64ec27ce71ae
|
||||||
|
67f2943bd9e41cefaa576efe55fd8d8e4c8a0c46
|
||||||
|
71639222f100f4e30987278bb2cadfde3bf6b010
|
||||||
|
2c91ec521f6e2f5a7ddf924eb659b7a37d1763e3
|
||||||
|
3f2e3e2c4220bf59edf9fd86a43eda065dce783c
|
||||||
|
1a4db18a1ab480487beae644abfbd3bd42bedc28
|
||||||
|
30421bf31225f5f50e93de2691e9fd29da8d353c
|
||||||
|
aed1a4d2c57b84e116e35ab7485b3f1b8e63fd39
|
||||||
|
2e00e84c3dded9ce67d0023b3b59c97e845df6f2
|
||||||
|
77ccd154edd55720317f4035ef3825be13ad9e0f
|
||||||
|
c5c03a40ca63dbde3aa4f07305fa955153db8562
|
||||||
|
e525af918587300d4ae0487b25ee6d61c16a9980
|
||||||
|
0a7cd16c55f06bfbbc1e61dc81ba8f8edca0b6e4
|
||||||
|
07775c76f1def4d155a50a9a2cdbbb0a584fe351
|
||||||
|
b6a619473a893ac0a4836a469fc1d581d3a84474
|
||||||
|
974339b23f0d1887e99a109605ade66873e03e76
|
||||||
|
667b02a4625a4e887c446c2dfa1ee8fc6ad48e4f
|
||||||
|
645791746e79b2f3118a0eca79dbbae6fa6191a4
|
||||||
|
58deb6da6c2bb3a72b9f7154d8f823a4f32e3316
|
||||||
|
d07a2bc0c5d11ddd2edbd6c4fdf3d00969aaba2c
|
||||||
|
dad04a7300d93f04117f7bb51e04a1b8d0a92f53
|
||||||
|
871e4e678f1075f84ad61572f9c984c09e4bcc91
|
||||||
|
02531cfc5ba230d1fd00d879134eeed4443bdf64
|
||||||
|
461f1937da031b6ec9209cdad5c11075d6cd3a38
|
||||||
|
d88b5012fb32111d20a55f6a41f09f2c33da8a12
|
||||||
|
85c863d075bee457f3b79372023b7c334427a4c2
|
||||||
|
c7961c2fc29b29b486c937e67d46cf97023958b7
|
||||||
|
70b2f472080ae66d648553c0f50148a57b65b831
|
||||||
|
588fcd07a724285a1ff89b25635cef743785f557
|
||||||
|
4b9b603f32afdcc8466e0a32302974f77470ef50
|
||||||
|
2f5acfd0b66e07f6b19573d1a2b0d9ba1430d465
|
||||||
|
aded71fb1d6c65e193d12a6232eb2c5664169110
|
||||||
|
61e37793101b8702664dc774c0579173a2f87fab
|
||||||
|
a7ea49b677045512a85e16c53abf74966e6ab734
|
||||||
|
ea8418534a1cc1dd7fe66de51a17a16a740e8222
|
||||||
|
7c9caf8f669303c5e7129fe166b0c59b7df870a6
|
||||||
|
2683e6e53e9f6574c2a6eca41d5d2dde85d55e0b
|
||||||
|
faa6ded5389576b487f0ad085a76fdd7d2372471
|
||||||
|
3c0ad6d68991961e2a72422fa4f69ed70d4ae6ab
|
||||||
|
a64da44ddc1cba77229ba024cac0948cb96a7676
|
||||||
|
9f59d00d9f3f34d0c368a02d6e1cc2cd3e80f4a9
|
||||||
|
4a76088fd649351a870fc49932485df934e98fcb
|
||||||
|
aab08fb22ee1b493cc18a8d1d091d3e4f4b6dcdb
|
||||||
|
b9905c8f06c561e66f14a5f69a8d06c0ad2e8f54
|
||||||
|
742ff4b9312b36d2674eaf6d855e6555bfdd14fc
|
||||||
|
fc5db16160067fc884f5129b53c2c2c30d97dbdf
|
||||||
|
a2807f038ef6628f886fe9b4618b1fea96224ff3
|
||||||
|
0a9d4c144d150fbb78e66050fd9f73f40539eda2
|
||||||
|
655a9afc9a891327cfebe359c66de3e30d9cf360
|
||||||
|
7bcc1f03f75b4036eab05d8d4c7648ab05cf866a
|
||||||
|
43d9e056eb2f07736497d0a0043259af6a367693
|
||||||
|
f5cfbf6a24b4c4ba8af9ae1f1f4ff46aa6ce4552
|
||||||
|
c711733287d3eccee7dd8151b1efd3f990653ee8
|
||||||
|
8bb3878d47836036a2b723edaaae44e6fc621e80
|
||||||
|
8003f8bf07e2e49216ffefc3280b43c572a952d0
|
||||||
|
c39611d5667d66d8d7a8c3b65a655d35a0c26f49
|
||||||
|
83f5021e7cb6ac9cda65ddc009015405c2ba6b91
|
||||||
|
a4bfae8e4411064653404a61aa384ea2f52d4eb3
|
||||||
|
1e4094e0775d11a1dbea00968b083838a3eaa576
|
||||||
|
c84ae49b820ee56263f6448cc5de6ce9c7da2254
|
||||||
|
0203a9795266e20bf32a6be4c44ff14af42a25f6
|
||||||
|
1ba3cddeea3bd00ff4ce337abbb00e289495d473
|
||||||
|
8193e74ff88bbd1a9ee14ca9b9f51fd590e3351f
|
||||||
|
b2e29836799a526c17ae6b1c742ec03f43e5db88
|
||||||
|
ccdfc4b8222abca3af87de4b794f00988e57d7d5
|
||||||
|
ca1ed10fa8fbc1572986d9d9242fe3eee1ad091d
|
||||||
|
bde716a0c9f93b4098ff16c38238c05980ed0eed
|
||||||
|
979efc701912270022dca394c0aff138967caa1e
|
||||||
|
062e5cb286ab289f439d59feffaa519a4b0eb163
|
||||||
|
6edb43c851e0857b37a91a2c33698527cac67c22
|
||||||
|
6b64819c0842cc55a52da26fc2f5efcee3afd450
|
||||||
|
9ee8084745df9b6d47f63f5c55a94cbb008a0a55
|
||||||
|
b489ce43d5f601dfccc462be1bbc5cda68b10b95
|
||||||
|
8ea067ddccc35e2a3d13886a130faf7278463114
|
||||||
|
b0ef9814fec761540d73f6daa7175516573b7af1
|
||||||
|
db5b9885b92887befb0aead9a276891e933b1dab
|
||||||
|
c0c462ee5c33bdb413c97fb80f3b391d6f65b1f5
|
||||||
|
580876152d87fe08f5074027043ddd2c9bf81beb
|
||||||
|
fd81a63a5ceb38379736897482a5da2577554709
|
||||||
|
a51cd91973af710bc8371aedfcf35e56da1ec5cb
|
||||||
|
56ca00299094832de60609416c67a8d9b1bbb4e5
|
||||||
|
417623c1bc2b9830397d29c134c7eb15a4bbbdbb
|
||||||
|
1509c1bbf381516016d0615968479f2d004b643b
|
||||||
|
10733a018a1ea4439d6830d1ffab4b292d64856a
|
||||||
|
00efd58b1ff1a27c5acb2ac973eba5cf94cbd100
|
||||||
|
8d7823d7fdb12fff24600591d8f392b0fae3d8dd
|
||||||
|
b7a8a16fea706aeef2d60f813b9bb247eab0fc84
|
||||||
|
4ace920dc95a09e9fad4b075e51058ebfd3ea4f5
|
||||||
|
6375695fc0c982071740b0e0a9a5b028426e24da
|
||||||
|
6088d3cda293fb3d723078247beaeb38ebf606de
|
||||||
|
961b363d3560726b20af48b298952831619737ab
|
||||||
|
d7144083a4b438e7e23e7669ab8fd72c3cf4da58
|
||||||
|
b1728d32972d82df1d01fdcc4775eeb4d6573a66
|
||||||
|
94574f004b1f1f4e1eb3de340d6d3c5786fce205
|
||||||
|
e734c0bc62caf294cad80336a04ea201494ee749
|
||||||
|
fd1b6917edd6a3d3f6c0f68b5b6cf39cd37d16af
|
||||||
|
c6b163a6b294dfeeac2617ac29e2d8ecfdfeb991
|
||||||
|
6ac1f70c65fe8eb0dddff52247cd1a363c52bec9
|
||||||
|
c94bb96e9f7ce59bc5fefe170b1971ee5d4ead0d
|
||||||
|
6e11f3cd67bb1274308914937edc0835280b2483
|
||||||
|
63e4d5bd72c4cc101b9e733198d2a748e4cd3ed1
|
||||||
|
077283537e93caf2e6bceae59abf607dbfe484dc
|
||||||
|
38416518c8759cfc7846a5cef4f77566d5d9e7fa
|
||||||
|
12195b88459060af3161694f43af8f99c1cd9afc
|
||||||
|
d2a9457c88976dcb594af8ad46f8841160171d7f
|
||||||
|
aaaf6638b7cacfd02fe56fc608103e91d5f9f849
|
||||||
|
97caf9394a5fbba5eda7dc99e528ca32b4e460de
|
||||||
|
dd59e586376628ebd517f26dafbbdbe8d72eab89
|
||||||
|
d8fea4d24eb4278414f03d525f095384a7debaba
|
||||||
|
f7534ac45eda041e4dfccb428f4d81e6e0f5b379
|
||||||
|
947b54abbf33b9dbdb464f83716ddacd7af533f0
|
||||||
|
d5b8755b6c064bb853aa489b6a4e7012c3012249
|
||||||
|
4346fbe81275438f742aded116d0db71ec78094c
|
||||||
|
cce7528acaade5073d058b8eecbdcc0a9a54f818
|
||||||
|
28bfb8cddf97bf58c7038416a7b4454773d60c5c
|
||||||
|
56eaa2e0d4071b067955269d908ff3b17de68957
|
||||||
|
c4e0734961d29bb0671a8140f4c8b9721cee9420
|
||||||
|
3712af28b18579be77414b98447b56e8db13f085
|
||||||
|
2e5bbd0db301b6b7883318b08d779acd755f476c
|
||||||
|
4d05b316c5e25e624558ceda2c2a0aed9428f6ee
|
||||||
|
20d6656c4f77f294b5e9055da6b6aa169673b040
|
||||||
|
a64da44ddc1cba77229ba024cac0948cb96a7676
|
||||||
|
24ce813193ef19d10359b757642fd2dbfc8c48c6
|
||||||
|
7ddbe3902e0dec4d2298b282813c17dd65e6e2ee
|
||||||
|
42c709f52c7f73c3eaf2e9793d1e5fdb84827869
|
||||||
|
52403bd1c6c5c5f0d84869185bbc6964d1db90bb
|
||||||
|
3c0ad6d68991961e2a72422fa4f69ed70d4ae6ab
|
||||||
|
2bd977df8b6d3decfbe33f0c01ebfd5222787d77
|
||||||
|
f46e60b785d2fa28b98438422cef6e89c369e902
|
||||||
|
713ece1808b7762dd4413c871ef0093eba5886c4
|
||||||
|
a860da86a8578ce07ee245c888e9ce90ea911f54
|
||||||
|
b0be9f0d46f0462b66de13e5705330439af9695e
|
||||||
|
aa7a46b0ed6b6b33973157df3aace8257475ac83
|
||||||
|
a6df7be1f065ea92bca2c2898712649061480a44
|
||||||
|
a2f60eb85700f35125d6f6aa0d74d95191ff8cc0
|
||||||
|
037ade5451edd788e9575b1b7555d2d00667c93b
|
||||||
|
a05abacd2f90d290b1f3f15ca200f6652bb393d3
|
||||||
|
6d4b94dc4a9953ed6a7a1986f06a018ba2991b63
|
||||||
|
e6cf8fab16928785e45b3e649645560c9ef58545
|
||||||
|
3bb46478e4271d6327d0acac496324265b6931a7
|
||||||
|
ca3c93a317678f0525f242eda9bba927a93de9b2
|
||||||
|
c76dd4c447a533b624f8829299112af44f52b2c6
|
||||||
|
84d000e07736e4d9c6da40ad6fd04c27f213b74e
|
||||||
|
1a015ee822d287cf564b016fb5fe57487a799f93
|
||||||
|
8f2704aa0ecac935244e2f396474d37865d191a8
|
||||||
|
d69bcaadaa5dffd0c2dd7fd91c933743d7fbbf53
|
||||||
|
2b2c787636cfffd7760710933784be903d171b63
|
||||||
|
4d8b034206326e307d4f4ae1720563effa2cf754
|
||||||
|
4130f1a97b5be548ebad885c71f5fdfbdbe6086f
|
||||||
|
578d35837d7c3b43abd78b2d2d3699741093216c
|
||||||
|
19c11cbfdbff810d0bef2a019a78bf0e6d6b5c2e
|
||||||
|
400d89b7e350a3596b7fd1d6646201f002d7cbc3
|
||||||
|
ea3f62b1dc17c3ddf3fecce1ed3263f19b5072d0
|
||||||
|
90113a109933dd493232a9f30715aa9d944b39c8
|
||||||
|
417623c1bc2b9830397d29c134c7eb15a4bbbdbb
|
||||||
|
1509c1bbf381516016d0615968479f2d004b643b
|
||||||
|
4a4df199566ea8107df3032889cdeafc1073bbb1
|
||||||
|
8e0e25cd3e89c4d39d7c33c9813d5c578af00e98
|
||||||
|
d03552d3ad07faecf8badaedb57a61099129909e
|
||||||
|
35ae5241adb11a210a19875b96127055ffd02330
|
||||||
|
b3405a751674277f60d20393b20f0b096c28367b
|
||||||
|
22c89c9b0f6c205279dd2574b8d033b7ac385166
|
||||||
|
c4d822855c7891414a0d67ea96da1d5b3233c338
|
||||||
|
80f7da0261c6a02a9c4a9b9993834860078fd03e
|
||||||
|
2ed07e123f712b387c3a1dec40827fb0a9603f42
|
||||||
|
eccbb14b7b9b78f9e41208eb749caf10f188a23d
|
||||||
|
cdc969e4d3920382bc124a67fd621c15f2d79e52
|
||||||
|
f1037fc31ecbd1a5c185e8205695c11c1966acf4
|
||||||
|
1fe522cdd333469d01c780508b9846f3a96fc839
|
||||||
|
50621ac24aca1972e57759147e5f0ae963c17e7f
|
||||||
|
8f7b184405405c430314996ef3bf5212ea0fa612
|
||||||
|
c8804e6fb90dc81b31b28d6299e21a3639a31854
|
||||||
|
3368241b6a21495c72f6075cef64f34ef9230079
|
||||||
|
4e6c57f14b0db349269a4f6707a7fb55f11075fe
|
||||||
|
d9ee1591b23e95d4e63436daa2de7556f6e345b9
|
||||||
|
01318e26512002c782b3362cb436a27787749668
|
||||||
|
068a56d79cd17df8e6914c870dfa6d44697cac07
|
||||||
|
58e8241159616601da4f25cb3a84f20a118c5fa3
|
||||||
|
7ff347dfa505f928698404921a3e9a331f883019
|
||||||
|
a8aa822d8544351204a77874996f21f2d6871f8e
|
||||||
|
f269c779e262017846734f7daec144fc6ddc8cbc
|
||||||
|
fe59b380152ce90ef4bd3be75b9bf9b544f742dd
|
||||||
|
8fc6eaac1711a1210b468e72fafef1762166a380
|
||||||
|
5bd2cd690bb6db367d442c2956a6e15092175eb7
|
||||||
|
a05703536c1d6da3cbea8d40b78a1a862adac799
|
||||||
|
118e798e01c89fcd73688d3fab1552475e92222d
|
||||||
|
02b9d7bf8a19a1ebd6ca219e5cff1537841fd155
|
||||||
|
d1684e43cb5409f86119a6f0ba6b5c695e88981c
|
||||||
|
c8c200ffbc20c95e010d8cfc8980a56e7cdbc929
|
||||||
|
499c4e9e00fb890d6178011d91d22383440e1a2d
|
||||||
|
6938fe0f6d3befd155cb05502377c97419103837
|
||||||
|
32118fa2f419c7638544171df456d4edfc4043b7
|
||||||
|
352801449ee088800a22a1d4ed23d1055f509e34
|
||||||
|
baf009604e6998d28860292413a6d4d3106707e4
|
||||||
|
386be16b8ba1e89ca5702880ce52f7990338a51e
|
||||||
|
4f562b0ab9dc44dececc7d6fd9368987f1bcf37d
|
||||||
|
1d6bea453ff09bcafde8258d6ce2c59fc55f9214
|
||||||
|
0d52d545761b90dde29f71062562441f57ba844c
|
||||||
|
cf448184e0207f654868384a06f8e29dab5981f7
|
||||||
|
fa87b0c81f5581f2f2d17a145a42f07227246bd1
|
||||||
|
7be00244368fa71cdd95278ef3ad7a9aa58598cb
|
||||||
|
fd396dc16bcf077d6d3403269475241d2e1d167f
|
||||||
|
2b73326d9685d16167494d7f498c86dfd9cecbcc
|
||||||
|
8cbb116f18a245610a5a881cb36b0c8853b83b8e
|
||||||
|
6dc11202f78f60f213c62956f7949717f6170307
|
||||||
|
d0178b9dd3358cc48c28b747a2e3085acaf0e2dc
|
||||||
|
dfe7b79a94b2018dcf7fb585b72abb1ab13d9688
|
||||||
|
bac436433c8082bad6a032df72eb20251e76aeb8
|
||||||
|
2af5c3ab3dd62cdb761f1ec19053d38eeaabdb12
|
||||||
|
2a745da619c8d1be153aa2ee474f2d84dc8a483c
|
||||||
|
3920be3be6a7b13ffcefea79b89c9f71b76b2c98
|
||||||
|
137537d31ad13efb9060f1ee1b8cf102ab0cfffd
|
||||||
|
66f41772d15b8b012a2d44c46ef105d27bf688e9
|
||||||
|
72276fe228e1160316b32ae0ef4dfbc93607df29
|
||||||
|
99b162a8aafb351393c0e01ae50606afb1cb3484
|
||||||
|
88f944e0ae4d74e82f31116d26826059409da59e
|
||||||
|
9af4ef0f3fdda5da4d9d19ed5321fe0ee69976be
|
||||||
|
3fed1e5b9f07738525ebf88aa824b5e8bbaf77b7
|
||||||
|
a3f1eeee549c9cba193158abb187b779ed193574
|
||||||
|
f7f4790f977922505c437a657c63afff8e553676
|
||||||
|
12291af54893a94909957b6085def5ee326e1071
|
||||||
|
bb830379073fdbdf065a217016a4d6052fbc2d8b
|
||||||
|
75ae7a68c5652cfd678aaced0ee0517ce6cd550c
|
||||||
|
dc2f18d8e6624ebcfd056079d2b9889f66af144a
|
||||||
|
8e318974552e4a472d6d6a2693ff00be696072f0
|
||||||
|
a4e190c237bf382fa5f2a6286222503f86c0df22
|
||||||
|
98f5f8fce21218bad44b81278d5f0aa9fdbdf9f7
|
||||||
|
c7431e4b69c93c13b33b0b4b7a505c70ee0d4455
|
||||||
|
2ed07e123f712b387c3a1dec40827fb0a9603f42
|
||||||
|
eccbb14b7b9b78f9e41208eb749caf10f188a23d
|
||||||
|
47139ebbd74eb8256a9bc59380c3ebbe4b9161a4
|
||||||
|
69ccbbed36adc15861684226dbc3967f02e45a34
|
||||||
|
53652e045227b8843e27c5385645172f5fe70746
|
||||||
|
e17644e7611d45b8c350faa6df8b089d3e7813a8
|
||||||
|
2dcb9f0bda8dcbbb803694e62914438709ca1fb9
|
||||||
|
7e4189ec7661c52d388b60603302e61a5faca0ab
|
||||||
|
57b55e6ef6db2b8afe70df3ec63ef364a6c3b7bb
|
||||||
|
2b96caa8e67119236fe0c274532f1c779e20cd95
|
||||||
|
e78eec0a8b813abdd3bd99ea0bfa914794db4bd3
|
||||||
|
8b93706efedf8777807024482c0e75ae9b0c5a39
|
||||||
|
d32997a4d9b5be6a820579812d6c15efb9f48bf5
|
||||||
|
dfe7b79a94b2018dcf7fb585b72abb1ab13d9688
|
||||||
|
bac436433c8082bad6a032df72eb20251e76aeb8
|
||||||
|
51ca9077f177ce4a45915661e72aab5da90d9b91
|
||||||
|
dae68c562061e6f2a13cdaab4bed9a62c098e143
|
||||||
|
6ef61bf7206818bee8488706353d51a029506022
|
||||||
|
fb436256a285f3e46320ef8724e4fac3823dd8f4
|
||||||
|
feeb17ca0512d8f01e35cd0e7877eb5a7a352978
|
||||||
|
875f7ae0d93a65ff6b2343285b46e61b721af343
|
||||||
|
ca7a9f1bedebcd0161152ec6748807b5f94f14d3
|
||||||
|
24ce813193ef19d10359b757642fd2dbfc8c48c6
|
||||||
|
7ddbe3902e0dec4d2298b282813c17dd65e6e2ee
|
||||||
|
5cfa78ff554305bdcc7df79caa1b17a8e533983b
|
||||||
|
ed2ef8f0174350d384f01cf3d4cbc77de59fdfa9
|
||||||
|
ee493fe283f50992879fe2301700bb362f3bd02f
|
||||||
|
cb32ee79ddc19464401808dbd5e01603fd97d010
|
||||||
|
b9509806b71a5163395065d644717f9e4f2a6528
|
||||||
|
86643e2ccc44b18bca5d57c0be5a2bdc31445c0c
|
||||||
|
c4e0734961d29bb0671a8140f4c8b9721cee9420
|
||||||
|
3712af28b18579be77414b98447b56e8db13f085
|
||||||
|
23c1da39d4f87a2598f2f13e0c10b9cd1f309918
|
||||||
|
0cb4908c7c3642c782566c179cd33f2a4f788678
|
||||||
|
fc869d9fd0e890e3eda0ccd401493b3cfe36a156
|
||||||
|
7fb02652211168c83050fdc54cef8eb3a740e028
|
||||||
|
20d6656c4f77f294b5e9055da6b6aa169673b040
|
||||||
|
a64da44ddc1cba77229ba024cac0948cb96a7676
|
||||||
|
be6a40b53fc142322395bf59f86f6cd046beaba3
|
||||||
|
6fa2431721911edf5ca1f9d50c24cca162668c05
|
||||||
|
b134af6081ac3966912be824aa89df24b688f90c
|
||||||
|
663c1bdec831757ef5bd18e36584f5f922dafbc5
|
||||||
|
5464c6f30f4b9ab4576f17b9f31bffc41dffc22e
|
||||||
|
cf448184e0207f654868384a06f8e29dab5981f7
|
||||||
|
326e268846fbac8e75f84745de805362c2363185
|
||||||
|
a2fd0543fe9cfb63958ca8802bf1cc21e74350aa
|
||||||
|
02f91ca84bd78ea683b52568b0613c58763f134c
|
||||||
|
fa87b0c81f5581f2f2d17a145a42f07227246bd1
|
||||||
|
4da0eb5b608675460a5599de883b51acb945f4bc
|
||||||
|
762478fb0783755523fd35c3e76f2bf71861e578
|
||||||
|
a291334b7d6147a3ad3d54eb2d11965e56d73521
|
||||||
|
d60f213462c55df8cbe8e36acf08ec874560bb73
|
||||||
|
857622c14a39cfa112482e51af3d2b54b553ac64
|
||||||
|
d7075b0fc87f611de635eab40f724e85ad1a9f72
|
||||||
|
bca94187ec887219a0f92360ff9f8b35dd7fb84d
|
||||||
|
a05703536c1d6da3cbea8d40b78a1a862adac799
|
||||||
|
b633f2e0b6bd3c9095097ade003c47994a61553b
|
||||||
|
5517c6426d05a75a2eb0c2bef2c5e84d81de1729
|
||||||
|
24bb959190903a773f8789e575e2d33c879ae085
|
||||||
|
118e798e01c89fcd73688d3fab1552475e92222d
|
||||||
|
8e318974552e4a472d6d6a2693ff00be696072f0
|
||||||
|
a4e190c237bf382fa5f2a6286222503f86c0df22
|
||||||
|
264c801525c2ec8ada0fe4ca701241a015966a7a
|
||||||
|
49601f0ced99dff60b577873323f459f4f5adb27
|
||||||
|
8890f4a77ac26feebbe85fddebe89efefe95411a
|
||||||
|
585946f9ee9ae1116f7435b8bec4c6782112f840
|
||||||
|
127e1c5d5ac9aef9a51c27ff061009dd5cbee356
|
||||||
|
d052fb727b0520288ec6643b161fafeda93209cd
|
||||||
|
4a4df199566ea8107df3032889cdeafc1073bbb1
|
||||||
|
8e0e25cd3e89c4d39d7c33c9813d5c578af00e98
|
||||||
|
7b8a370f0cb359b983fa2ddadbecf9f61aa33146
|
||||||
|
5f0c9b2d721952690f94a2c7c6b986da8ade7952
|
||||||
|
391ff2ac9046ce0aa9ca620f37ced2fb9f65b493
|
||||||
|
ab619037682a8267079770bd0b18e37fce6724c9
|
||||||
|
f269c779e262017846734f7daec144fc6ddc8cbc
|
||||||
|
c4d822855c7891414a0d67ea96da1d5b3233c338
|
||||||
|
80f7da0261c6a02a9c4a9b9993834860078fd03e
|
||||||
|
82f2efaa2e331876de4a74ff53b6de3a276fd6e3
|
||||||
|
cdc969e4d3920382bc124a67fd621c15f2d79e52
|
||||||
|
b15811121f367d04a3ac7a92a09f67e27b6d552d
|
||||||
|
b41bc60c96536846fb077e4b9fe68787d64ca232
|
||||||
|
58deb6da6c2bb3a72b9f7154d8f823a4f32e3316
|
||||||
|
f1037fc31ecbd1a5c185e8205695c11c1966acf4
|
||||||
|
a167a8f6ea9b45bfd48ce8e2bd969b9f48b98bfd
|
||||||
|
2b73326d9685d16167494d7f498c86dfd9cecbcc
|
||||||
|
8cbb116f18a245610a5a881cb36b0c8853b83b8e
|
||||||
|
d9953bd3fc800b1c8971a8aa2ac2f033ee0aa065
|
||||||
|
c809d74c7a80b407f80a0b8d2c939a4027d56efd
|
||||||
|
beb10f6515e6c9b6d6f9a64499da89418b931fa0
|
||||||
|
82bef182db8f84cbe56a1df4efdd3a8debb8d0cf
|
||||||
|
d43692928372badd32c62d4053dd6ee1344bba40
|
||||||
|
801204bfb07fee0c953ba4535abe88091ec47325
|
||||||
|
de93ee5f732774a604f48432261c5dc05a946fc5
|
||||||
|
7caebe0b7176d25393be019169ca84f2fc24b547
|
||||||
|
17148e490ad59206bd052a9c0b4915bcdfec5166
|
||||||
|
e3c31c6f936fc376d017ec1cc2e355613bd7fc5f
|
||||||
|
63a479d2ed1e6e1878edef12a86182d8916d7e12
|
||||||
|
3b0ee00887e57f9e09ba048fbdc8ef7cf09934af
|
||||||
|
c5a302724bd9d34e20d84cbc353980ce128f9351
|
||||||
|
12f2d5a8cf2c7d77443007b978d8a9868d206e5e
|
||||||
|
7f1dd4b383e39eb1d934f75a86bf05a10cd85baa
|
||||||
|
8de2aaa4bea07d8e42c4afa3a9596f620e530acd
|
||||||
|
9dcf2d2a11a11ea2cd0deeaaefadf0f89e11d775
|
||||||
|
746b0d9ce63289c084e15aec92938fe7982f1ad3
|
||||||
|
a79c0293dc63c6c82dfd15a20ee0005d867b2333
|
||||||
|
4d7163b722e05ac266e79fcb1231e05583595a2c
|
||||||
|
ac9a2a597da5fa378a0b0abb4eb77f7a62ebd41b
|
||||||
|
930bbea0f399256f5128eb81092e43d0f897e034
|
||||||
|
645791746e79b2f3118a0eca79dbbae6fa6191a4
|
||||||
|
fb484633d7aba3da1567d717ff4a4dbc79a4eb9e
|
||||||
|
da6244b48f6f1eccc9c21179f61cfd0a244e923f
|
||||||
|
1549f7ae4dd388f58cd0df457fe0d4cbdf371da0
|
||||||
|
1b087654e2239d22e59ceea5b386b34e766e6843
|
||||||
|
5bc1f3aa8f8beb6593a90fdef01a6171a46410f1
|
||||||
|
6827322d9802937defcc8deb55946d0cd1f81874
|
||||||
|
326d45c8eb39455fd22535e046ce93a4df70b6ab
|
||||||
|
3502dc0d2cdedb25940a10ebb6478286db1ceca8
|
||||||
|
5e8892bf53634101c1efe46c9434ff8cdc0be82d
|
||||||
|
69ccbbed36adc15861684226dbc3967f02e45a34
|
||||||
|
165d19806b39d125d5910b4302c4810a86b9416c
|
||||||
|
37c251f941adb5dd40f75bf554773ba23ddc2694
|
||||||
|
0dce73e53721d64fa64f24ad79fbabc7825c4963
|
||||||
|
1c1e8915b173d438f5fae7371bcc7836611307d2
|
||||||
|
826b49d4adc0a57e7a3c9ef11d97198c3b3e15ad
|
||||||
|
e7058e1aa29e3f7937b9f35bf7580bc22622e4ef
|
||||||
|
ddd295f68851cf9e2c433c6f5b07b024f1c669f7
|
||||||
|
0ff12ea0318d083d3a7cde42ce5ce8f416d2fc84
|
||||||
|
7e2e2f2df8c01330f39e6a61f652062cf8e09dff
|
||||||
|
bd78a1058ac9c9b420009a5163cda729b9ce9cfb
|
||||||
|
3f18b7de0d2a27ba5b8b174cb9c8373cbef6053e
|
||||||
|
13c2e41300898027689e574aaf7fede08d8b88fa
|
||||||
|
14aa1ee8561953307b650caaa57eb89aac740c34
|
||||||
|
a92ff82ec95460aef72fb5268430433986c8fc4e
|
||||||
|
a46a8944af0c3d077e66a748a8ceb4dc65ad97ad
|
||||||
|
87a589c2fc505c301766551163adc374d125375f
|
||||||
|
9df681150de94c9413a937874392e1c61ca7fee6
|
||||||
|
912ca4281a44c51a8dca18808c5efd25233493ed
|
||||||
|
89ac7f7ba77fcd2393ac62201c2ef46bd3f6a8d2
|
||||||
|
34c77170c098e829c7a2d1e00e3bbb3f42b47373
|
||||||
|
cf81c3bd7861ca8e3567f0162434a3d7cfa4c059
|
||||||
|
7fd90165e7478b034ddb45aa3db2eb8a00ce4036
|
||||||
|
3226f192eda643b84805e528eaafd71fc89bf6c0
|
||||||
|
8faa17baa69c5e8aa217e572bfc559490f77a113
|
||||||
|
58e8241159616601da4f25cb3a84f20a118c5fa3
|
||||||
|
ab9d521e1d88d656c3b9226f4065217eed9414d3
|
||||||
|
3e4b4acf9f747c10912c1b5731df0b0be05a4b9d
|
||||||
|
1c3407726079190f7b4513ddff854b4110396f36
|
||||||
|
9186a3747ac9150c1f22e309a758eab1e1d4716c
|
||||||
|
074d0881423783677eafb643e5337e856c06f4ca
|
||||||
|
0da2ca590f32f1f8fb4b8dddaa32e3101731bc17
|
||||||
|
e9aa2c103a71b86cb4c902b4ab226cf48b8cce42
|
||||||
|
9206d28d699b093f1f21ec9850d0b5e1c12965ce
|
||||||
|
45003492570044cd7e119d1c3c06345dbf3f47f6
|
||||||
|
3769c7ea810bcb8238b881eecd204c9f71a59502
|
||||||
|
46c2dc39ef7eaea68030a613558635d4bba07eb9
|
||||||
|
f7534ac45eda041e4dfccb428f4d81e6e0f5b379
|
||||||
|
d27da47f05141f358e5b044c9b604ca14250624e
|
||||||
|
66c53697a1c9e56b3899735b1502ec035862d211
|
||||||
|
a43d58594f59ee1bd83040276e9e2d199656fd04
|
||||||
|
a740b28290bd2a2c978cff4844a708334d9a5f68
|
||||||
|
8d458f5a3980431a0428f30cedc34eedcf272ec6
|
||||||
|
3dccb730ee6c6a73f08bb540fbfd5f83d6e0bd39
|
||||||
|
54f2cd35194aac7320aed073362b54ce3535917f
|
||||||
|
1ebae7b1fa10b1e57168c7650099fe6ca85cc536
|
||||||
|
3c834576aa91c21c407b6ac15d762952eaf5ea6e
|
||||||
|
e207071f71b050cb3c1762b93dd4513da8890ed6
|
||||||
|
c7fe2d0e2a8ad7f625c75b3c8c32137107f676bc
|
||||||
|
82aeea0fc1ed0a5a8d64568fc0c4ae2e7baa2137
|
||||||
|
8f249e8e923cbf7d756e0e9f2fd2a994e5a54dd6
|
||||||
|
20c160a4cb7b095e310f3b35ce00ca73dafe4503
|
||||||
|
152b03e5788842393ff89973c42bb820946cdfb5
|
||||||
|
232dbb548fab2844d4e076bb944ec5f2c05044c7
|
||||||
|
a172ed0972964dea6578bb0ac9a1a69ecdf983f3
|
||||||
|
febc302f3f7495c651495fa2b5175d7ac581508e
|
||||||
|
bdaa926f4c084a4dce01a6ec6c1fdfa0718772ea
|
||||||
|
f14a4b2182660ddfa7c22f4698f0d75a19f3ac84
|
||||||
|
634778d63b41a799978e5a34dbdd9fb1bce0a0d5
|
||||||
|
260e07189e327c1a027d35eebf04e6e2623eaf9d
|
||||||
|
6025e6e883bad414ed34f2f71af70b4d72bf3e36
|
||||||
|
3c0ad6d68991961e2a72422fa4f69ed70d4ae6ab
|
||||||
|
2bd977df8b6d3decfbe33f0c01ebfd5222787d77
|
||||||
|
827b6db70630cdc4c6296440faac9d4ca66725e4
|
||||||
|
f7d6bd4b1796b8f01581d84843ecb6849a93ffa5
|
||||||
|
b5f8a3d03fd20f47ae73f8b5f249e90e8aecd91b
|
||||||
|
4ed9706eb17fd600681eede6b2c6dd8a90dda538
|
||||||
|
b18c27d6d8a9b26a1d038774030428d00eb5c078
|
||||||
|
68eb07c273a29bf6bb4babbdc35fb107d5c553a6
|
||||||
|
939cf7e129f56d802ba0efc2f17fa7318ae801f1
|
||||||
|
4d0cb054b355c4d217d31271b12082f49d8ad6d1
|
||||||
|
83057bc03c4b565d6bd2e5ab33cdb984c3b9cd31
|
||||||
|
2162dcc8661b3e3be39e85e2e0e4f0969f20059d
|
||||||
|
ac80debb5e053a31f3898dce585dc118bc6df8d5
|
||||||
|
65616d2c62e13b0e9bda03e41812a00a49936a2d
|
||||||
|
aedd0cb02d12cea2ebe54a7cfff9c53e4ac73c1f
|
||||||
|
8ecb8d3840f6ee3df830e46d1c8c2a27f084edf5
|
||||||
|
8ecb8d3840f6ee3df830e46d1c8c2a27f084edf5
|
||||||
|
d37b857c055ae661e417f282fa97e3bb80063cb0
|
||||||
|
8b054bebe1c61143e224e68f3986b6fca586a5df
|
||||||
|
eca0b96f28afa764abad40d26f322a5748c7ef08
|
||||||
|
02f4e9b5ac7a9a6923c64ae3deee0c7e27f37781
|
||||||
|
0fd5cc3b6fe4992098139b901baf53182a4578b1
|
||||||
|
32cd7b58640e3fc4322ac09435669b16da2a9852
|
||||||
|
dc75e9e2f7955b744e2747e6ff01fe62ff9c87e0
|
||||||
|
a748e6a8c6793d3a127edd892e5d007c848d9fb6
|
||||||
@@ -0,0 +1,29 @@
|
|||||||
|
project_name: gitleaks
|
||||||
|
|
||||||
|
builds:
|
||||||
|
- main: main.go
|
||||||
|
binary: gitleaks
|
||||||
|
goos:
|
||||||
|
- darwin
|
||||||
|
- linux
|
||||||
|
- windows
|
||||||
|
goarch:
|
||||||
|
- amd64
|
||||||
|
- "386"
|
||||||
|
- arm
|
||||||
|
- arm64
|
||||||
|
goarm:
|
||||||
|
- "6"
|
||||||
|
- "7"
|
||||||
|
ldflags:
|
||||||
|
- -s -w -X=github.com/zricethezav/gitleaks/v8/cmd.Version={{.Version}}
|
||||||
|
archives:
|
||||||
|
- builds: [gitleaks]
|
||||||
|
format_overrides:
|
||||||
|
- goos: windows
|
||||||
|
format: zip
|
||||||
|
replacements:
|
||||||
|
amd64: x64
|
||||||
|
386: x32
|
||||||
|
release:
|
||||||
|
prerelease: true
|
||||||
@@ -0,0 +1,11 @@
|
|||||||
|
- id: gitleaks
|
||||||
|
name: Detect hardcoded secrets
|
||||||
|
description: Detect hardcoded secrets using Gitleaks
|
||||||
|
entry: gitleaks protect --verbose --redact --staged
|
||||||
|
language: golang
|
||||||
|
pass_filenames: false
|
||||||
|
- id: gitleaks-docker
|
||||||
|
name: Detect hardcoded secrets
|
||||||
|
description: Detect hardcoded secrets using Gitleaks
|
||||||
|
entry: zricethezav/gitleaks protect --verbose --redact --staged
|
||||||
|
language: docker_image
|
||||||
-19
@@ -1,19 +0,0 @@
|
|||||||
sudo: required
|
|
||||||
language: go
|
|
||||||
go:
|
|
||||||
- 1.9
|
|
||||||
services:
|
|
||||||
- docker
|
|
||||||
script:
|
|
||||||
- make test
|
|
||||||
after_success:
|
|
||||||
- export REPO=zricethezav/gitleaks
|
|
||||||
- export TAG=`if [ "$TRAVIS_BRANCH" == "master" ]; then echo "latest"; else echo $TRAVIS_BRANCH;
|
|
||||||
fi`
|
|
||||||
- if [ "$TRAVIS_PULL_REQUEST" = "false" ]; then make deploy; fi
|
|
||||||
env:
|
|
||||||
global:
|
|
||||||
- secure: kUjq6Jgnm57V+ikDoYJ4IrFu4bLMHkaBb9uLtbQj0A545zZt4Dbooarnwqbfz2efqqMDZ9TXP6kN6677yWm0DyvFOCYx/Xq2innnVbBJczQciEUb5PI/9fcmLOfTe/QgGNi0GZOCdIOGlki2sbKxob6tTOUsm52ugRSJU92cXkX8w+Gzc6pC6fAb4moLE2QpwK1xWDHm2sHiZYExpBOH8eidSH5VPGVdNE9QmUA/FwwJ9NFGsZ8BgWCJPy7IJreyixsv2nNpiZNHoj0UgKe4wylzceu4sG/yQDIYk3fLVWBXSm/nSA17QYIjVMzQFjSAVC5dRqzq8HzFYiAYLKzkoOtrbBqEGtXzYZMN6yC8zEedk9gX6P6mvGpWYBy280uumcpGl6eoKYj5ke2H6kfcCUhMNTGZP17nmnTa1KFLAz1nxB1jfJwwO6v1l+xdytju5yAhm049Af7VyDM5GmE2x5ha48uKvK7wHtv+IKiZbbcR9ExsXvm21+7NVjQvRPzAw4/Sor9SG/yjoA/Sf7e4evy1w3fALv4WlaSisj5Yalmv7mzeeFZaIB7EIq6OryeRld2Rr1MZwwhZgIs7+SWwpjKfwhkfLVEUvSWCdnS2tnTydK6R6OFxfG5TGfR/WHooXLHEv5gMuKhUu/CqnbLyvI+8IOH2ybz2AtZWjf5n7oY=
|
|
||||||
- secure: cIxKSkBNkPFAn243eHtwHJb8z6Uty1cZ43ZK/UABjwJoSrhu/roK4soqdZLwdVRA/0QswAlp6AC25Zs3ngLKGxxFHoeB8Tx6VLanE1zoi8OT0I2KbT92FdrLV4HlcRshKZtTFoTCfgVKPnWNKC+hil97CQzQPGRpZLBSfNefk5uCMnQiAzaJ5lyWPx+sjLHzpVlGA6aQx9ZeBQqngQJoDHKc0K3hKwug4h9mkkhyaYE3kgxtsdOYlHvOtQgVk+Zih5uW7ABOQCyAOaQVipXBC+uiuNf2DeAuGDaX69DTRKqPzuIasbhwyGqlfsr2JeofEWgZGmTaWGKMi03hnIY+U9+lHjygBW1qqVglODboouUrV3LwER9kqrT+ZFTM5Ca8VB+Gx5khkknbjWd06jpzRQxNXdukYN89kEaAHkBH844G99pMDqcZ32lHK7lpCu8n1H/Liz3ygoV6ScJXnYAP6y9rrd3bb9KEmnKhmFacVLRIAUw1vN/cgspJpl/Mk6s5rvGwsbQih1OxGyooOLxGjEGWqVDFgHFtyiwX9s9kT+hNTwKgbhp7Ragk/QuDYUPZ3Vum7HoiNPS9KpQNstLvDckdtd8h13JIw6nX+xdWbNKjjdYbAZRstJHUROQtNq3XdWNQ9YjqbCoybaxCOwOUTwOiTSWNKXjTFbFI5mR/ZO0=
|
|
||||||
- COMMIT=${TRAVIS_COMMIT::8}
|
|
||||||
- secure: o6uPX071qGRKgOQmitxiDr1j+KRW8W6ru0wmKNBFuUlZvQudwCUZMnVfk6OeofT1IgLCHmLS8ST81cTyeXqOQhYVZrlxTmEUpDHHRTu6dOj3eqRzdJow1LIWNpw5xfOaqXUdQ8+SQ47ZeSFapsmaY9oeRDvSJ8zLS4qUdgUylvZFJWjSrjzi2xemJa1l3MDdZRhEaNkfMliDGCv2vuUFp7tYz0QtyqBkBMORQl53dzgrcQcsRjDSE274WJl9CUg1l0pNMFsAbVCUGwUqCmKace9LXZ9JV00TRdg4EpryDsUCi23q0THnwstvRffwyJrw+xbhY/X3GKC4zOKqiCLJ4MTPQEIKlpVJQ9e9lWJ8FYhpUrl3QaHfEPINJ0taUfGhCyNzi5QBkSWbTcWVmRMmu+QIy7moW9crcz2xmVEUey7AaGwZT2Kk6JGw26w5q9IUy1Z9mwaljmHrUTqZrOX4Hj3UblpkHN+mGkoia/ipta5KhN5lTTIs4N3V+El7O2R2GggBrVHNiSualfydo+RX8k/S6PM1/C88IQO3Y2utoJrr415CznncvhF9Sc6tncZcShcNQj1iEOSsGxY2noW265eHzTMKJ/xuN6Bp9OXVK+8iOcUsz1T7F0UqwY3xnD8F7fBZ7IGG41DsXBDIcPmb+SIYbhv0uJjm3BEuv4TzIU0=
|
|
||||||
-133
@@ -1,133 +0,0 @@
|
|||||||
CHANGELOG
|
|
||||||
=========
|
|
||||||
1.12.1
|
|
||||||
----
|
|
||||||
- Show program usage when no arguments are provided
|
|
||||||
- Exit program after the -h or --help options are used
|
|
||||||
1.12.0
|
|
||||||
----
|
|
||||||
- removing --csv option
|
|
||||||
- --report option now requires .json or .csv in filename
|
|
||||||
- adding total time to audit in logs
|
|
||||||
|
|
||||||
1.11.1
|
|
||||||
----
|
|
||||||
- fix commit whitelist logic
|
|
||||||
|
|
||||||
1.11.0
|
|
||||||
-----
|
|
||||||
- Commit depth option
|
|
||||||
- Commit stats output
|
|
||||||
|
|
||||||
1.10.0
|
|
||||||
-----
|
|
||||||
- Add entropy option
|
|
||||||
|
|
||||||
1.9.0
|
|
||||||
-----
|
|
||||||
- exclude fork option
|
|
||||||
|
|
||||||
1.8.0
|
|
||||||
-----
|
|
||||||
- whitelist repos
|
|
||||||
- sample config option
|
|
||||||
|
|
||||||
1.7.3
|
|
||||||
-----
|
|
||||||
- style points
|
|
||||||
|
|
||||||
1.7.2
|
|
||||||
-----
|
|
||||||
- Fixing dangling goroutines, removing channel messaging
|
|
||||||
|
|
||||||
1.7.1
|
|
||||||
-----
|
|
||||||
- Fixing bug where single repos were not being audited
|
|
||||||
|
|
||||||
1.7.0
|
|
||||||
-----
|
|
||||||
- Exit code == 2 on error
|
|
||||||
- Cleaning up some logs
|
|
||||||
- Removing some unreachable code
|
|
||||||
|
|
||||||
1.6.1
|
|
||||||
-----
|
|
||||||
- Recover from panic when diffing
|
|
||||||
|
|
||||||
1.6.0
|
|
||||||
-----
|
|
||||||
- Default maximum goroutines spawned is number of cores your cpu run with. See benchmarks in wiki.
|
|
||||||
- Cleanup after each repo audit for organizations rather than waiting for the entire organization to complete. Eliminates risk of running out of disk space.
|
|
||||||
|
|
||||||
|
|
||||||
1.5.0
|
|
||||||
-----
|
|
||||||
- Support for CSV reporting
|
|
||||||
- Refactoring github user/owner audits
|
|
||||||
|
|
||||||
1.4.0
|
|
||||||
-----
|
|
||||||
- Support for single commit repos
|
|
||||||
- Bumped go-git version from 4.5.0 to 4.7.0
|
|
||||||
|
|
||||||
1.3.0
|
|
||||||
-----
|
|
||||||
- Target specific branch
|
|
||||||
|
|
||||||
1.2.1
|
|
||||||
-----
|
|
||||||
- Check errors when generating commit patch
|
|
||||||
|
|
||||||
1.2.0
|
|
||||||
-----
|
|
||||||
- Added support for providing an alternate GitHub URL to support scanning GitHub Enteprise repositories
|
|
||||||
|
|
||||||
1.1.2
|
|
||||||
-----
|
|
||||||
- Added version option
|
|
||||||
- Introduced changelog
|
|
||||||
|
|
||||||
1.1.1
|
|
||||||
-----
|
|
||||||
- Fixed commit patch order
|
|
||||||
- Updated Readme
|
|
||||||
|
|
||||||
1.1.0
|
|
||||||
-----
|
|
||||||
- Fixed Twitter typo
|
|
||||||
- Fixed sample docker command
|
|
||||||
- Default clone option to "in-memory"
|
|
||||||
- Added clone option for "disk"
|
|
||||||
- Updated Makefile
|
|
||||||
|
|
||||||
1.0.0
|
|
||||||
-----
|
|
||||||
- Rewrite, see Readme.md: https://github.com/zricethezav/gitleaks/releases/tag/v1.0.0
|
|
||||||
|
|
||||||
0.4.0
|
|
||||||
-----
|
|
||||||
- Added support for external regexes
|
|
||||||
|
|
||||||
0.3.0
|
|
||||||
-----
|
|
||||||
- Added local scan
|
|
||||||
- Meaningful exit codes
|
|
||||||
- Timestamped logs
|
|
||||||
- Refactored for some maintainability
|
|
||||||
|
|
||||||
0.2.0
|
|
||||||
-----
|
|
||||||
- Additionally regex checking
|
|
||||||
- $HOME/.gitleaks/ directory for clones and reports
|
|
||||||
- Pagination for Org/User list... no more partial repo lists
|
|
||||||
- Persistent repos for Orgs and Users (no more re-cloning)
|
|
||||||
- Updated README
|
|
||||||
- Multi-staged Docker build
|
|
||||||
- Travis CI
|
|
||||||
|
|
||||||
0.1.0
|
|
||||||
-----
|
|
||||||
- full git history search
|
|
||||||
- regex/entropy checks
|
|
||||||
- report generation
|
|
||||||
|
|
||||||
+96
-13
@@ -1,20 +1,103 @@
|
|||||||
# Contributing Guidelines
|
# Contribution guidelines
|
||||||
|
|
||||||
The gitleaks project is under [GNU General Public License v3.0](LICENSE.md) and accepts
|
## General
|
||||||
contributions via GitHub pull requests.
|
|
||||||
|
|
||||||
## How to Contribute
|
### Issues
|
||||||
|
|
||||||
Open a PR. Give the PR a descriptive title. Add some comments describing whats the purpose of the PR.
|
If you have a feature or bug fix you would like to contribute please check if
|
||||||
|
there are any open issues describing your proposed addition. If there are open
|
||||||
|
issues, make a comment stating you are working on fixing or implementing said
|
||||||
|
issue. If not, then please open an issue describing your addition. Make sure to
|
||||||
|
link your PR to an issue.
|
||||||
|
|
||||||
__BUT before you do that!__
|
### Pull Requests
|
||||||
|
|
||||||
Make sure you pass this list of requirements.
|
Fill out the template as best you can. Make sure your tests pass. If you see a
|
||||||
|
PR that isn't one you opened and want it introduced in the next release,
|
||||||
|
give it a :thumbsup: on the PR description.
|
||||||
|
|
||||||
- You've ran `go fmt`.
|
## Adding new Gitleaks rules
|
||||||
- You've ran `golint`.
|
|
||||||
- Your Go changes are confined to `gitleaks_test.go` and `main.go`. This is subject to change as the project evolves. Stylistically, I like having a single go file considering the size of this project (its tiny).
|
|
||||||
- You've added test cases for your changes.
|
|
||||||
- You've updated [the changelog](CHANGELOG.md).
|
|
||||||
- Your tests pass.
|
|
||||||
|
|
||||||
|
If you want to add a new rule to the [default Gitleaks configuration](https://github.com/zricethezav/gitleaks/blob/master/config/gitleaks.toml) then follow these steps.
|
||||||
|
|
||||||
|
1. Create a `cmd/generate/config/rules/{provider}.go` file.
|
||||||
|
This file is used to generate a new Gitleaks rule.
|
||||||
|
Let's look at `beamer.go` for example. Comments have been added for context.
|
||||||
|
|
||||||
|
```golang
|
||||||
|
func Beamer() *config.Rule {
|
||||||
|
// Define Rule
|
||||||
|
r := config.Rule{
|
||||||
|
// Human redable description of the rule
|
||||||
|
Description: "Beamer API token",
|
||||||
|
|
||||||
|
// Unique ID for the rule
|
||||||
|
RuleID: "beamer-api-token",
|
||||||
|
|
||||||
|
// Regex capture group for the actual secret
|
||||||
|
SecretGroup: 1,
|
||||||
|
|
||||||
|
|
||||||
|
// Regex used for detecting secrets. See regex section below for more details
|
||||||
|
Regex: generateSemiGenericRegex([]string{"beamer"}, `b_[a-z0-9=_\-]{44}`),
|
||||||
|
|
||||||
|
// Keywords used for string matching on fragments (think of this as a prefilter)
|
||||||
|
Keywords: []string{"beamer"},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("beamer", "b_"+secrets.NewSecret(alphaNumericExtended("44"))),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
|
Feel free to use this example as a template when writing new rules.
|
||||||
|
This file should be fairly self-explanatory except for a few items;
|
||||||
|
regex and secret generation. To help with maintence, _most_ rules should
|
||||||
|
be uniform. The functions,
|
||||||
|
[`generateSemiGenericRegex`](https://github.com/zricethezav/gitleaks/blob/master/cmd/generate/config/rules/rule.go#L31) and [`generateUniqueTokenRegex`](https://github.com/zricethezav/gitleaks/blob/master/cmd/generate/config/rules/rule.go#L44) will generate rules
|
||||||
|
that follow defined patterns.
|
||||||
|
|
||||||
|
The function signatures look like this:
|
||||||
|
|
||||||
|
```golang
|
||||||
|
func generateSemiGenericRegex(identifiers []string, secretRegex string) *regexp.Regexp
|
||||||
|
|
||||||
|
func generateUniqueTokenRegex(secretRegex string) *regexp.Regexp
|
||||||
|
```
|
||||||
|
|
||||||
|
`generateSemiGenericRegex` accepts a list of identifiers and a regex.
|
||||||
|
The list of identifiers _should_ match the list of `Keywords` in the rule
|
||||||
|
definition above. Both `identifiers` in the `generateSemiGenericRegex`
|
||||||
|
function _and_ `Keywords` act as filters for Gitleaks telling the program
|
||||||
|
"_at least one of these strings must be present to be considered a leak_"
|
||||||
|
|
||||||
|
`generateUniqueToken` just accepts a regex. If you are writing a rule for a
|
||||||
|
token that is unique enough not to require an identifier then you can use
|
||||||
|
this function. For example, Pulumi's API Token has the prefix `pul-` which is
|
||||||
|
unique enough to use `generateUniqueToken`. But something like Beamer's API
|
||||||
|
token that has a `b_` prefix is not unqiue enough to use `generateUniqueToken`,
|
||||||
|
so instead we use `generateSemiGenericRegex` and require a `beamer`
|
||||||
|
identifier is part of the rule.
|
||||||
|
If a token's prefix has more than `3` characters then you could
|
||||||
|
probably get away with using `generateUniqueToken`.
|
||||||
|
|
||||||
|
Last thing you'll want to hit before we move on from this file is the
|
||||||
|
validation part. You can use `generateSampleSecret` to create a secret for the
|
||||||
|
true positives (`tps` in the example above) used in `validate`.
|
||||||
|
|
||||||
|
1. Update `cmd/generate/config/main.go`. Add a line like
|
||||||
|
`configRules = append(configRules, rules.Beamer())` in `main()`. Try and keep
|
||||||
|
this alphabetically pretty please.
|
||||||
|
|
||||||
|
1. Change directories into `cmd/generate/config` and run `go run main.go`
|
||||||
|
|
||||||
|
```
|
||||||
|
cd cmd/generate/config && go run main.go
|
||||||
|
```
|
||||||
|
|
||||||
|
1. Check out your new rules in `config/gitleaks.toml` and see if everything looks good.
|
||||||
|
|
||||||
|
1. Open a PR
|
||||||
+10
-11
@@ -1,16 +1,15 @@
|
|||||||
FROM golang:1.10.3 AS build
|
FROM golang:1.18 AS build
|
||||||
WORKDIR /go/src/github.com/zricethezav/gitleaks
|
WORKDIR /go/src/github.com/zricethezav/gitleaks
|
||||||
COPY . .
|
COPY . .
|
||||||
RUN CGO_ENABLED=0 go build -o bin/gitleaks *.go
|
RUN VERSION=$(git describe --tags --abbrev=0) && \
|
||||||
|
CGO_ENABLED=0 go build -o bin/gitleaks -ldflags "-X="github.com/zricethezav/gitleaks/v8/cmd.Version=${VERSION}
|
||||||
|
|
||||||
FROM alpine:3.7
|
FROM alpine:3.16
|
||||||
RUN apk add --no-cache bash git openssh
|
RUN adduser -D gitleaks && \
|
||||||
|
apk add --no-cache bash git openssh-client
|
||||||
COPY --from=build /go/src/github.com/zricethezav/gitleaks/bin/* /usr/bin/
|
COPY --from=build /go/src/github.com/zricethezav/gitleaks/bin/* /usr/bin/
|
||||||
|
USER gitleaks
|
||||||
|
|
||||||
|
RUN git config --global --add safe.directory '*'
|
||||||
|
|
||||||
ENTRYPOINT ["gitleaks"]
|
ENTRYPOINT ["gitleaks"]
|
||||||
|
|
||||||
# How to use me :
|
|
||||||
|
|
||||||
# docker build -t gitleaks .
|
|
||||||
# docker run --rm --name=gitleaks gitleaks https://github.com/zricethezav/gitleaks
|
|
||||||
|
|
||||||
# This will check for secrets in https://github.com/zricethezav/gitleaks
|
|
||||||
Generated
-260
@@ -1,260 +0,0 @@
|
|||||||
# This file is autogenerated, do not edit; changes may be undone by the next 'dep ensure'.
|
|
||||||
|
|
||||||
|
|
||||||
[[projects]]
|
|
||||||
name = "github.com/BurntSushi/toml"
|
|
||||||
packages = ["."]
|
|
||||||
revision = "3012a1dbe2e4bd1391d42b32f0577cb7bbc7f005"
|
|
||||||
version = "v0.3.1"
|
|
||||||
|
|
||||||
[[projects]]
|
|
||||||
name = "github.com/emirpasic/gods"
|
|
||||||
packages = [
|
|
||||||
"containers",
|
|
||||||
"lists",
|
|
||||||
"lists/arraylist",
|
|
||||||
"trees",
|
|
||||||
"trees/binaryheap",
|
|
||||||
"utils"
|
|
||||||
]
|
|
||||||
revision = "1615341f118ae12f353cc8a983f35b584342c9b3"
|
|
||||||
version = "v1.12.0"
|
|
||||||
|
|
||||||
[[projects]]
|
|
||||||
name = "github.com/franela/goblin"
|
|
||||||
packages = ["."]
|
|
||||||
revision = "cd5d08fb4ede9eaac1812fdb513552e7404eae2e"
|
|
||||||
version = "0.0.2"
|
|
||||||
|
|
||||||
[[projects]]
|
|
||||||
name = "github.com/golang/protobuf"
|
|
||||||
packages = ["proto"]
|
|
||||||
revision = "aa810b61a9c79d51363740d207bb46cf8e620ed5"
|
|
||||||
version = "v1.2.0"
|
|
||||||
|
|
||||||
[[projects]]
|
|
||||||
name = "github.com/google/go-github"
|
|
||||||
packages = ["github"]
|
|
||||||
revision = "e48060a28fac52d0f1cb758bc8b87c07bac4a87d"
|
|
||||||
version = "v15.0.0"
|
|
||||||
|
|
||||||
[[projects]]
|
|
||||||
name = "github.com/google/go-querystring"
|
|
||||||
packages = ["query"]
|
|
||||||
revision = "44c6ddd0a2342c386950e880b658017258da92fc"
|
|
||||||
version = "v1.0.0"
|
|
||||||
|
|
||||||
[[projects]]
|
|
||||||
name = "github.com/hako/durafmt"
|
|
||||||
packages = ["."]
|
|
||||||
revision = "7b7ae1e72eade09dbc9c2cfba3e6c4bae7b8bcac"
|
|
||||||
version = "1.0.0"
|
|
||||||
|
|
||||||
[[projects]]
|
|
||||||
branch = "master"
|
|
||||||
name = "github.com/jbenet/go-context"
|
|
||||||
packages = ["io"]
|
|
||||||
revision = "d14ea06fba99483203c19d92cfcd13ebe73135f4"
|
|
||||||
|
|
||||||
[[projects]]
|
|
||||||
name = "github.com/jessevdk/go-flags"
|
|
||||||
packages = ["."]
|
|
||||||
revision = "c6ca198ec95c841fdb89fc0de7496fed11ab854e"
|
|
||||||
version = "v1.4.0"
|
|
||||||
|
|
||||||
[[projects]]
|
|
||||||
name = "github.com/kevinburke/ssh_config"
|
|
||||||
packages = ["."]
|
|
||||||
revision = "81db2a75821ed34e682567d48be488a1c3121088"
|
|
||||||
version = "0.5"
|
|
||||||
|
|
||||||
[[projects]]
|
|
||||||
name = "github.com/mitchellh/go-homedir"
|
|
||||||
packages = ["."]
|
|
||||||
revision = "ae18d6b8b3205b561c79e8e5f69bff09736185f4"
|
|
||||||
version = "v1.0.0"
|
|
||||||
|
|
||||||
[[projects]]
|
|
||||||
name = "github.com/pelletier/go-buffruneio"
|
|
||||||
packages = ["."]
|
|
||||||
revision = "c37440a7cf42ac63b919c752ca73a85067e05992"
|
|
||||||
version = "v0.2.0"
|
|
||||||
|
|
||||||
[[projects]]
|
|
||||||
name = "github.com/sergi/go-diff"
|
|
||||||
packages = ["diffmatchpatch"]
|
|
||||||
revision = "1744e2970ca51c86172c8190fadad617561ed6e7"
|
|
||||||
version = "v1.0.0"
|
|
||||||
|
|
||||||
[[projects]]
|
|
||||||
name = "github.com/sirupsen/logrus"
|
|
||||||
packages = ["."]
|
|
||||||
revision = "3e01752db0189b9157070a0e1668a620f9a85da2"
|
|
||||||
version = "v1.0.6"
|
|
||||||
|
|
||||||
[[projects]]
|
|
||||||
name = "github.com/src-d/gcfg"
|
|
||||||
packages = [
|
|
||||||
".",
|
|
||||||
"scanner",
|
|
||||||
"token",
|
|
||||||
"types"
|
|
||||||
]
|
|
||||||
revision = "f187355171c936ac84a82793659ebb4936bc1c23"
|
|
||||||
version = "v1.3.0"
|
|
||||||
|
|
||||||
[[projects]]
|
|
||||||
name = "github.com/xanzy/ssh-agent"
|
|
||||||
packages = ["."]
|
|
||||||
revision = "640f0ab560aeb89d523bb6ac322b1244d5c3796c"
|
|
||||||
version = "v0.2.0"
|
|
||||||
|
|
||||||
[[projects]]
|
|
||||||
branch = "master"
|
|
||||||
name = "golang.org/x/crypto"
|
|
||||||
packages = [
|
|
||||||
"cast5",
|
|
||||||
"curve25519",
|
|
||||||
"ed25519",
|
|
||||||
"ed25519/internal/edwards25519",
|
|
||||||
"internal/chacha20",
|
|
||||||
"internal/subtle",
|
|
||||||
"openpgp",
|
|
||||||
"openpgp/armor",
|
|
||||||
"openpgp/elgamal",
|
|
||||||
"openpgp/errors",
|
|
||||||
"openpgp/packet",
|
|
||||||
"openpgp/s2k",
|
|
||||||
"poly1305",
|
|
||||||
"ssh",
|
|
||||||
"ssh/agent",
|
|
||||||
"ssh/knownhosts",
|
|
||||||
"ssh/terminal"
|
|
||||||
]
|
|
||||||
revision = "0e37d006457bf46f9e6692014ba72ef82c33022c"
|
|
||||||
|
|
||||||
[[projects]]
|
|
||||||
branch = "master"
|
|
||||||
name = "golang.org/x/net"
|
|
||||||
packages = [
|
|
||||||
"context",
|
|
||||||
"context/ctxhttp"
|
|
||||||
]
|
|
||||||
revision = "f04abc6bdfa7a0171a8a0c9fd2ada9391044d056"
|
|
||||||
|
|
||||||
[[projects]]
|
|
||||||
branch = "master"
|
|
||||||
name = "golang.org/x/oauth2"
|
|
||||||
packages = [
|
|
||||||
".",
|
|
||||||
"internal"
|
|
||||||
]
|
|
||||||
revision = "d2e6202438beef2727060aa7cabdd924d92ebfd9"
|
|
||||||
|
|
||||||
[[projects]]
|
|
||||||
branch = "master"
|
|
||||||
name = "golang.org/x/sys"
|
|
||||||
packages = [
|
|
||||||
"unix",
|
|
||||||
"windows"
|
|
||||||
]
|
|
||||||
revision = "b09afc3d579e346c4a7e4705953acaf6f9e551bd"
|
|
||||||
|
|
||||||
[[projects]]
|
|
||||||
name = "golang.org/x/text"
|
|
||||||
packages = [
|
|
||||||
"internal/gen",
|
|
||||||
"internal/triegen",
|
|
||||||
"internal/ucd",
|
|
||||||
"transform",
|
|
||||||
"unicode/cldr",
|
|
||||||
"unicode/norm"
|
|
||||||
]
|
|
||||||
revision = "f21a4dfb5e38f5895301dc265a8def02365cc3d0"
|
|
||||||
version = "v0.3.0"
|
|
||||||
|
|
||||||
[[projects]]
|
|
||||||
name = "google.golang.org/appengine"
|
|
||||||
packages = [
|
|
||||||
"internal",
|
|
||||||
"internal/base",
|
|
||||||
"internal/datastore",
|
|
||||||
"internal/log",
|
|
||||||
"internal/remote_api",
|
|
||||||
"internal/urlfetch",
|
|
||||||
"urlfetch"
|
|
||||||
]
|
|
||||||
revision = "ae0ab99deb4dc413a2b4bd6c8bdd0eb67f1e4d06"
|
|
||||||
version = "v1.2.0"
|
|
||||||
|
|
||||||
[[projects]]
|
|
||||||
name = "gopkg.in/src-d/go-billy.v4"
|
|
||||||
packages = [
|
|
||||||
".",
|
|
||||||
"helper/chroot",
|
|
||||||
"helper/polyfill",
|
|
||||||
"osfs",
|
|
||||||
"util"
|
|
||||||
]
|
|
||||||
revision = "982626487c60a5252e7d0b695ca23fb0fa2fd670"
|
|
||||||
version = "v4.3.0"
|
|
||||||
|
|
||||||
[[projects]]
|
|
||||||
name = "gopkg.in/src-d/go-git.v4"
|
|
||||||
packages = [
|
|
||||||
".",
|
|
||||||
"config",
|
|
||||||
"internal/revision",
|
|
||||||
"plumbing",
|
|
||||||
"plumbing/cache",
|
|
||||||
"plumbing/filemode",
|
|
||||||
"plumbing/format/config",
|
|
||||||
"plumbing/format/diff",
|
|
||||||
"plumbing/format/gitignore",
|
|
||||||
"plumbing/format/idxfile",
|
|
||||||
"plumbing/format/index",
|
|
||||||
"plumbing/format/objfile",
|
|
||||||
"plumbing/format/packfile",
|
|
||||||
"plumbing/format/pktline",
|
|
||||||
"plumbing/object",
|
|
||||||
"plumbing/protocol/packp",
|
|
||||||
"plumbing/protocol/packp/capability",
|
|
||||||
"plumbing/protocol/packp/sideband",
|
|
||||||
"plumbing/revlist",
|
|
||||||
"plumbing/storer",
|
|
||||||
"plumbing/transport",
|
|
||||||
"plumbing/transport/client",
|
|
||||||
"plumbing/transport/file",
|
|
||||||
"plumbing/transport/git",
|
|
||||||
"plumbing/transport/http",
|
|
||||||
"plumbing/transport/internal/common",
|
|
||||||
"plumbing/transport/server",
|
|
||||||
"plumbing/transport/ssh",
|
|
||||||
"storage",
|
|
||||||
"storage/filesystem",
|
|
||||||
"storage/filesystem/dotgit",
|
|
||||||
"storage/memory",
|
|
||||||
"utils/binary",
|
|
||||||
"utils/diff",
|
|
||||||
"utils/ioutil",
|
|
||||||
"utils/merkletrie",
|
|
||||||
"utils/merkletrie/filesystem",
|
|
||||||
"utils/merkletrie/index",
|
|
||||||
"utils/merkletrie/internal/frame",
|
|
||||||
"utils/merkletrie/noder"
|
|
||||||
]
|
|
||||||
revision = "d3cec13ac0b195bfb897ed038a08b5130ab9969e"
|
|
||||||
version = "v4.7.0"
|
|
||||||
|
|
||||||
[[projects]]
|
|
||||||
name = "gopkg.in/warnings.v0"
|
|
||||||
packages = ["."]
|
|
||||||
revision = "ec4a0fea49c7b46c2aeb0b51aac55779c607e52b"
|
|
||||||
version = "v0.1.2"
|
|
||||||
|
|
||||||
[solve-meta]
|
|
||||||
analyzer-name = "dep"
|
|
||||||
analyzer-version = 1
|
|
||||||
inputs-digest = "ad1b6855b3c8b3e1303f29123160cde693d39d6724682ce1cd246cd1a2343c7c"
|
|
||||||
solver-name = "gps-cdcl"
|
|
||||||
solver-version = 1
|
|
||||||
-58
@@ -1,58 +0,0 @@
|
|||||||
# Gopkg.toml example
|
|
||||||
#
|
|
||||||
# Refer to https://github.com/golang/dep/blob/master/docs/Gopkg.toml.md
|
|
||||||
# for detailed Gopkg.toml documentation.
|
|
||||||
#
|
|
||||||
# required = ["github.com/user/thing/cmd/thing"]
|
|
||||||
# ignored = ["github.com/user/project/pkgX", "bitbucket.org/user/project/pkgA/pkgY"]
|
|
||||||
#
|
|
||||||
# [[constraint]]
|
|
||||||
# name = "github.com/user/project"
|
|
||||||
# version = "1.0.0"
|
|
||||||
#
|
|
||||||
# [[constraint]]
|
|
||||||
# name = "github.com/user/project2"
|
|
||||||
# branch = "dev"
|
|
||||||
# source = "github.com/myfork/project2"
|
|
||||||
#
|
|
||||||
# [[override]]
|
|
||||||
# name = "github.com/x/y"
|
|
||||||
# version = "2.4.0"
|
|
||||||
#
|
|
||||||
# [prune]
|
|
||||||
# non-go = false
|
|
||||||
# go-tests = true
|
|
||||||
# unused-packages = true
|
|
||||||
|
|
||||||
|
|
||||||
[[constraint]]
|
|
||||||
name = "github.com/BurntSushi/toml"
|
|
||||||
version = "0.3.0"
|
|
||||||
|
|
||||||
[[constraint]]
|
|
||||||
name = "github.com/franela/goblin"
|
|
||||||
version = "0.0.2"
|
|
||||||
|
|
||||||
[[constraint]]
|
|
||||||
name = "github.com/google/go-github"
|
|
||||||
version = "15.0.0"
|
|
||||||
|
|
||||||
[[constraint]]
|
|
||||||
name = "github.com/jessevdk/go-flags"
|
|
||||||
version = "1.4.0"
|
|
||||||
|
|
||||||
[[constraint]]
|
|
||||||
name = "github.com/sirupsen/logrus"
|
|
||||||
version = "1.0.5"
|
|
||||||
|
|
||||||
[[constraint]]
|
|
||||||
branch = "master"
|
|
||||||
name = "golang.org/x/oauth2"
|
|
||||||
|
|
||||||
[[constraint]]
|
|
||||||
name = "gopkg.in/src-d/go-git.v4"
|
|
||||||
version = "4.7.0"
|
|
||||||
|
|
||||||
[prune]
|
|
||||||
go-tests = true
|
|
||||||
unused-packages = true
|
|
||||||
@@ -1,6 +1,6 @@
|
|||||||
The MIT License (MIT)
|
MIT License
|
||||||
|
|
||||||
Copyright (c) 2016 Wesley Hill
|
Copyright (c) 2019 Zachary Rice
|
||||||
|
|
||||||
Permission is hereby granted, free of charge, to any person obtaining a copy
|
Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||||
of this software and associated documentation files (the "Software"), to deal
|
of this software and associated documentation files (the "Software"), to deal
|
||||||
-674
@@ -1,674 +0,0 @@
|
|||||||
GNU GENERAL PUBLIC LICENSE
|
|
||||||
Version 3, 29 June 2007
|
|
||||||
|
|
||||||
Copyright (C) 2007 Free Software Foundation, Inc. <http://fsf.org/>
|
|
||||||
Everyone is permitted to copy and distribute verbatim copies
|
|
||||||
of this license document, but changing it is not allowed.
|
|
||||||
|
|
||||||
Preamble
|
|
||||||
|
|
||||||
The GNU General Public License is a free, copyleft license for
|
|
||||||
software and other kinds of works.
|
|
||||||
|
|
||||||
The licenses for most software and other practical works are designed
|
|
||||||
to take away your freedom to share and change the works. By contrast,
|
|
||||||
the GNU General Public License is intended to guarantee your freedom to
|
|
||||||
share and change all versions of a program--to make sure it remains free
|
|
||||||
software for all its users. We, the Free Software Foundation, use the
|
|
||||||
GNU General Public License for most of our software; it applies also to
|
|
||||||
any other work released this way by its authors. You can apply it to
|
|
||||||
your programs, too.
|
|
||||||
|
|
||||||
When we speak of free software, we are referring to freedom, not
|
|
||||||
price. Our General Public Licenses are designed to make sure that you
|
|
||||||
have the freedom to distribute copies of free software (and charge for
|
|
||||||
them if you wish), that you receive source code or can get it if you
|
|
||||||
want it, that you can change the software or use pieces of it in new
|
|
||||||
free programs, and that you know you can do these things.
|
|
||||||
|
|
||||||
To protect your rights, we need to prevent others from denying you
|
|
||||||
these rights or asking you to surrender the rights. Therefore, you have
|
|
||||||
certain responsibilities if you distribute copies of the software, or if
|
|
||||||
you modify it: responsibilities to respect the freedom of others.
|
|
||||||
|
|
||||||
For example, if you distribute copies of such a program, whether
|
|
||||||
gratis or for a fee, you must pass on to the recipients the same
|
|
||||||
freedoms that you received. You must make sure that they, too, receive
|
|
||||||
or can get the source code. And you must show them these terms so they
|
|
||||||
know their rights.
|
|
||||||
|
|
||||||
Developers that use the GNU GPL protect your rights with two steps:
|
|
||||||
(1) assert copyright on the software, and (2) offer you this License
|
|
||||||
giving you legal permission to copy, distribute and/or modify it.
|
|
||||||
|
|
||||||
For the developers' and authors' protection, the GPL clearly explains
|
|
||||||
that there is no warranty for this free software. For both users' and
|
|
||||||
authors' sake, the GPL requires that modified versions be marked as
|
|
||||||
changed, so that their problems will not be attributed erroneously to
|
|
||||||
authors of previous versions.
|
|
||||||
|
|
||||||
Some devices are designed to deny users access to install or run
|
|
||||||
modified versions of the software inside them, although the manufacturer
|
|
||||||
can do so. This is fundamentally incompatible with the aim of
|
|
||||||
protecting users' freedom to change the software. The systematic
|
|
||||||
pattern of such abuse occurs in the area of products for individuals to
|
|
||||||
use, which is precisely where it is most unacceptable. Therefore, we
|
|
||||||
have designed this version of the GPL to prohibit the practice for those
|
|
||||||
products. If such problems arise substantially in other domains, we
|
|
||||||
stand ready to extend this provision to those domains in future versions
|
|
||||||
of the GPL, as needed to protect the freedom of users.
|
|
||||||
|
|
||||||
Finally, every program is threatened constantly by software patents.
|
|
||||||
States should not allow patents to restrict development and use of
|
|
||||||
software on general-purpose computers, but in those that do, we wish to
|
|
||||||
avoid the special danger that patents applied to a free program could
|
|
||||||
make it effectively proprietary. To prevent this, the GPL assures that
|
|
||||||
patents cannot be used to render the program non-free.
|
|
||||||
|
|
||||||
The precise terms and conditions for copying, distribution and
|
|
||||||
modification follow.
|
|
||||||
|
|
||||||
TERMS AND CONDITIONS
|
|
||||||
|
|
||||||
0. Definitions.
|
|
||||||
|
|
||||||
"This License" refers to version 3 of the GNU General Public License.
|
|
||||||
|
|
||||||
"Copyright" also means copyright-like laws that apply to other kinds of
|
|
||||||
works, such as semiconductor masks.
|
|
||||||
|
|
||||||
"The Program" refers to any copyrightable work licensed under this
|
|
||||||
License. Each licensee is addressed as "you". "Licensees" and
|
|
||||||
"recipients" may be individuals or organizations.
|
|
||||||
|
|
||||||
To "modify" a work means to copy from or adapt all or part of the work
|
|
||||||
in a fashion requiring copyright permission, other than the making of an
|
|
||||||
exact copy. The resulting work is called a "modified version" of the
|
|
||||||
earlier work or a work "based on" the earlier work.
|
|
||||||
|
|
||||||
A "covered work" means either the unmodified Program or a work based
|
|
||||||
on the Program.
|
|
||||||
|
|
||||||
To "propagate" a work means to do anything with it that, without
|
|
||||||
permission, would make you directly or secondarily liable for
|
|
||||||
infringement under applicable copyright law, except executing it on a
|
|
||||||
computer or modifying a private copy. Propagation includes copying,
|
|
||||||
distribution (with or without modification), making available to the
|
|
||||||
public, and in some countries other activities as well.
|
|
||||||
|
|
||||||
To "convey" a work means any kind of propagation that enables other
|
|
||||||
parties to make or receive copies. Mere interaction with a user through
|
|
||||||
a computer network, with no transfer of a copy, is not conveying.
|
|
||||||
|
|
||||||
An interactive user interface displays "Appropriate Legal Notices"
|
|
||||||
to the extent that it includes a convenient and prominently visible
|
|
||||||
feature that (1) displays an appropriate copyright notice, and (2)
|
|
||||||
tells the user that there is no warranty for the work (except to the
|
|
||||||
extent that warranties are provided), that licensees may convey the
|
|
||||||
work under this License, and how to view a copy of this License. If
|
|
||||||
the interface presents a list of user commands or options, such as a
|
|
||||||
menu, a prominent item in the list meets this criterion.
|
|
||||||
|
|
||||||
1. Source Code.
|
|
||||||
|
|
||||||
The "source code" for a work means the preferred form of the work
|
|
||||||
for making modifications to it. "Object code" means any non-source
|
|
||||||
form of a work.
|
|
||||||
|
|
||||||
A "Standard Interface" means an interface that either is an official
|
|
||||||
standard defined by a recognized standards body, or, in the case of
|
|
||||||
interfaces specified for a particular programming language, one that
|
|
||||||
is widely used among developers working in that language.
|
|
||||||
|
|
||||||
The "System Libraries" of an executable work include anything, other
|
|
||||||
than the work as a whole, that (a) is included in the normal form of
|
|
||||||
packaging a Major Component, but which is not part of that Major
|
|
||||||
Component, and (b) serves only to enable use of the work with that
|
|
||||||
Major Component, or to implement a Standard Interface for which an
|
|
||||||
implementation is available to the public in source code form. A
|
|
||||||
"Major Component", in this context, means a major essential component
|
|
||||||
(kernel, window system, and so on) of the specific operating system
|
|
||||||
(if any) on which the executable work runs, or a compiler used to
|
|
||||||
produce the work, or an object code interpreter used to run it.
|
|
||||||
|
|
||||||
The "Corresponding Source" for a work in object code form means all
|
|
||||||
the source code needed to generate, install, and (for an executable
|
|
||||||
work) run the object code and to modify the work, including scripts to
|
|
||||||
control those activities. However, it does not include the work's
|
|
||||||
System Libraries, or general-purpose tools or generally available free
|
|
||||||
programs which are used unmodified in performing those activities but
|
|
||||||
which are not part of the work. For example, Corresponding Source
|
|
||||||
includes interface definition files associated with source files for
|
|
||||||
the work, and the source code for shared libraries and dynamically
|
|
||||||
linked subprograms that the work is specifically designed to require,
|
|
||||||
such as by intimate data communication or control flow between those
|
|
||||||
subprograms and other parts of the work.
|
|
||||||
|
|
||||||
The Corresponding Source need not include anything that users
|
|
||||||
can regenerate automatically from other parts of the Corresponding
|
|
||||||
Source.
|
|
||||||
|
|
||||||
The Corresponding Source for a work in source code form is that
|
|
||||||
same work.
|
|
||||||
|
|
||||||
2. Basic Permissions.
|
|
||||||
|
|
||||||
All rights granted under this License are granted for the term of
|
|
||||||
copyright on the Program, and are irrevocable provided the stated
|
|
||||||
conditions are met. This License explicitly affirms your unlimited
|
|
||||||
permission to run the unmodified Program. The output from running a
|
|
||||||
covered work is covered by this License only if the output, given its
|
|
||||||
content, constitutes a covered work. This License acknowledges your
|
|
||||||
rights of fair use or other equivalent, as provided by copyright law.
|
|
||||||
|
|
||||||
You may make, run and propagate covered works that you do not
|
|
||||||
convey, without conditions so long as your license otherwise remains
|
|
||||||
in force. You may convey covered works to others for the sole purpose
|
|
||||||
of having them make modifications exclusively for you, or provide you
|
|
||||||
with facilities for running those works, provided that you comply with
|
|
||||||
the terms of this License in conveying all material for which you do
|
|
||||||
not control copyright. Those thus making or running the covered works
|
|
||||||
for you must do so exclusively on your behalf, under your direction
|
|
||||||
and control, on terms that prohibit them from making any copies of
|
|
||||||
your copyrighted material outside their relationship with you.
|
|
||||||
|
|
||||||
Conveying under any other circumstances is permitted solely under
|
|
||||||
the conditions stated below. Sublicensing is not allowed; section 10
|
|
||||||
makes it unnecessary.
|
|
||||||
|
|
||||||
3. Protecting Users' Legal Rights From Anti-Circumvention Law.
|
|
||||||
|
|
||||||
No covered work shall be deemed part of an effective technological
|
|
||||||
measure under any applicable law fulfilling obligations under article
|
|
||||||
11 of the WIPO copyright treaty adopted on 20 December 1996, or
|
|
||||||
similar laws prohibiting or restricting circumvention of such
|
|
||||||
measures.
|
|
||||||
|
|
||||||
When you convey a covered work, you waive any legal power to forbid
|
|
||||||
circumvention of technological measures to the extent such circumvention
|
|
||||||
is effected by exercising rights under this License with respect to
|
|
||||||
the covered work, and you disclaim any intention to limit operation or
|
|
||||||
modification of the work as a means of enforcing, against the work's
|
|
||||||
users, your or third parties' legal rights to forbid circumvention of
|
|
||||||
technological measures.
|
|
||||||
|
|
||||||
4. Conveying Verbatim Copies.
|
|
||||||
|
|
||||||
You may convey verbatim copies of the Program's source code as you
|
|
||||||
receive it, in any medium, provided that you conspicuously and
|
|
||||||
appropriately publish on each copy an appropriate copyright notice;
|
|
||||||
keep intact all notices stating that this License and any
|
|
||||||
non-permissive terms added in accord with section 7 apply to the code;
|
|
||||||
keep intact all notices of the absence of any warranty; and give all
|
|
||||||
recipients a copy of this License along with the Program.
|
|
||||||
|
|
||||||
You may charge any price or no price for each copy that you convey,
|
|
||||||
and you may offer support or warranty protection for a fee.
|
|
||||||
|
|
||||||
5. Conveying Modified Source Versions.
|
|
||||||
|
|
||||||
You may convey a work based on the Program, or the modifications to
|
|
||||||
produce it from the Program, in the form of source code under the
|
|
||||||
terms of section 4, provided that you also meet all of these conditions:
|
|
||||||
|
|
||||||
a) The work must carry prominent notices stating that you modified
|
|
||||||
it, and giving a relevant date.
|
|
||||||
|
|
||||||
b) The work must carry prominent notices stating that it is
|
|
||||||
released under this License and any conditions added under section
|
|
||||||
7. This requirement modifies the requirement in section 4 to
|
|
||||||
"keep intact all notices".
|
|
||||||
|
|
||||||
c) You must license the entire work, as a whole, under this
|
|
||||||
License to anyone who comes into possession of a copy. This
|
|
||||||
License will therefore apply, along with any applicable section 7
|
|
||||||
additional terms, to the whole of the work, and all its parts,
|
|
||||||
regardless of how they are packaged. This License gives no
|
|
||||||
permission to license the work in any other way, but it does not
|
|
||||||
invalidate such permission if you have separately received it.
|
|
||||||
|
|
||||||
d) If the work has interactive user interfaces, each must display
|
|
||||||
Appropriate Legal Notices; however, if the Program has interactive
|
|
||||||
interfaces that do not display Appropriate Legal Notices, your
|
|
||||||
work need not make them do so.
|
|
||||||
|
|
||||||
A compilation of a covered work with other separate and independent
|
|
||||||
works, which are not by their nature extensions of the covered work,
|
|
||||||
and which are not combined with it such as to form a larger program,
|
|
||||||
in or on a volume of a storage or distribution medium, is called an
|
|
||||||
"aggregate" if the compilation and its resulting copyright are not
|
|
||||||
used to limit the access or legal rights of the compilation's users
|
|
||||||
beyond what the individual works permit. Inclusion of a covered work
|
|
||||||
in an aggregate does not cause this License to apply to the other
|
|
||||||
parts of the aggregate.
|
|
||||||
|
|
||||||
6. Conveying Non-Source Forms.
|
|
||||||
|
|
||||||
You may convey a covered work in object code form under the terms
|
|
||||||
of sections 4 and 5, provided that you also convey the
|
|
||||||
machine-readable Corresponding Source under the terms of this License,
|
|
||||||
in one of these ways:
|
|
||||||
|
|
||||||
a) Convey the object code in, or embodied in, a physical product
|
|
||||||
(including a physical distribution medium), accompanied by the
|
|
||||||
Corresponding Source fixed on a durable physical medium
|
|
||||||
customarily used for software interchange.
|
|
||||||
|
|
||||||
b) Convey the object code in, or embodied in, a physical product
|
|
||||||
(including a physical distribution medium), accompanied by a
|
|
||||||
written offer, valid for at least three years and valid for as
|
|
||||||
long as you offer spare parts or customer support for that product
|
|
||||||
model, to give anyone who possesses the object code either (1) a
|
|
||||||
copy of the Corresponding Source for all the software in the
|
|
||||||
product that is covered by this License, on a durable physical
|
|
||||||
medium customarily used for software interchange, for a price no
|
|
||||||
more than your reasonable cost of physically performing this
|
|
||||||
conveying of source, or (2) access to copy the
|
|
||||||
Corresponding Source from a network server at no charge.
|
|
||||||
|
|
||||||
c) Convey individual copies of the object code with a copy of the
|
|
||||||
written offer to provide the Corresponding Source. This
|
|
||||||
alternative is allowed only occasionally and noncommercially, and
|
|
||||||
only if you received the object code with such an offer, in accord
|
|
||||||
with subsection 6b.
|
|
||||||
|
|
||||||
d) Convey the object code by offering access from a designated
|
|
||||||
place (gratis or for a charge), and offer equivalent access to the
|
|
||||||
Corresponding Source in the same way through the same place at no
|
|
||||||
further charge. You need not require recipients to copy the
|
|
||||||
Corresponding Source along with the object code. If the place to
|
|
||||||
copy the object code is a network server, the Corresponding Source
|
|
||||||
may be on a different server (operated by you or a third party)
|
|
||||||
that supports equivalent copying facilities, provided you maintain
|
|
||||||
clear directions next to the object code saying where to find the
|
|
||||||
Corresponding Source. Regardless of what server hosts the
|
|
||||||
Corresponding Source, you remain obligated to ensure that it is
|
|
||||||
available for as long as needed to satisfy these requirements.
|
|
||||||
|
|
||||||
e) Convey the object code using peer-to-peer transmission, provided
|
|
||||||
you inform other peers where the object code and Corresponding
|
|
||||||
Source of the work are being offered to the general public at no
|
|
||||||
charge under subsection 6d.
|
|
||||||
|
|
||||||
A separable portion of the object code, whose source code is excluded
|
|
||||||
from the Corresponding Source as a System Library, need not be
|
|
||||||
included in conveying the object code work.
|
|
||||||
|
|
||||||
A "User Product" is either (1) a "consumer product", which means any
|
|
||||||
tangible personal property which is normally used for personal, family,
|
|
||||||
or household purposes, or (2) anything designed or sold for incorporation
|
|
||||||
into a dwelling. In determining whether a product is a consumer product,
|
|
||||||
doubtful cases shall be resolved in favor of coverage. For a particular
|
|
||||||
product received by a particular user, "normally used" refers to a
|
|
||||||
typical or common use of that class of product, regardless of the status
|
|
||||||
of the particular user or of the way in which the particular user
|
|
||||||
actually uses, or expects or is expected to use, the product. A product
|
|
||||||
is a consumer product regardless of whether the product has substantial
|
|
||||||
commercial, industrial or non-consumer uses, unless such uses represent
|
|
||||||
the only significant mode of use of the product.
|
|
||||||
|
|
||||||
"Installation Information" for a User Product means any methods,
|
|
||||||
procedures, authorization keys, or other information required to install
|
|
||||||
and execute modified versions of a covered work in that User Product from
|
|
||||||
a modified version of its Corresponding Source. The information must
|
|
||||||
suffice to ensure that the continued functioning of the modified object
|
|
||||||
code is in no case prevented or interfered with solely because
|
|
||||||
modification has been made.
|
|
||||||
|
|
||||||
If you convey an object code work under this section in, or with, or
|
|
||||||
specifically for use in, a User Product, and the conveying occurs as
|
|
||||||
part of a transaction in which the right of possession and use of the
|
|
||||||
User Product is transferred to the recipient in perpetuity or for a
|
|
||||||
fixed term (regardless of how the transaction is characterized), the
|
|
||||||
Corresponding Source conveyed under this section must be accompanied
|
|
||||||
by the Installation Information. But this requirement does not apply
|
|
||||||
if neither you nor any third party retains the ability to install
|
|
||||||
modified object code on the User Product (for example, the work has
|
|
||||||
been installed in ROM).
|
|
||||||
|
|
||||||
The requirement to provide Installation Information does not include a
|
|
||||||
requirement to continue to provide support service, warranty, or updates
|
|
||||||
for a work that has been modified or installed by the recipient, or for
|
|
||||||
the User Product in which it has been modified or installed. Access to a
|
|
||||||
network may be denied when the modification itself materially and
|
|
||||||
adversely affects the operation of the network or violates the rules and
|
|
||||||
protocols for communication across the network.
|
|
||||||
|
|
||||||
Corresponding Source conveyed, and Installation Information provided,
|
|
||||||
in accord with this section must be in a format that is publicly
|
|
||||||
documented (and with an implementation available to the public in
|
|
||||||
source code form), and must require no special password or key for
|
|
||||||
unpacking, reading or copying.
|
|
||||||
|
|
||||||
7. Additional Terms.
|
|
||||||
|
|
||||||
"Additional permissions" are terms that supplement the terms of this
|
|
||||||
License by making exceptions from one or more of its conditions.
|
|
||||||
Additional permissions that are applicable to the entire Program shall
|
|
||||||
be treated as though they were included in this License, to the extent
|
|
||||||
that they are valid under applicable law. If additional permissions
|
|
||||||
apply only to part of the Program, that part may be used separately
|
|
||||||
under those permissions, but the entire Program remains governed by
|
|
||||||
this License without regard to the additional permissions.
|
|
||||||
|
|
||||||
When you convey a copy of a covered work, you may at your option
|
|
||||||
remove any additional permissions from that copy, or from any part of
|
|
||||||
it. (Additional permissions may be written to require their own
|
|
||||||
removal in certain cases when you modify the work.) You may place
|
|
||||||
additional permissions on material, added by you to a covered work,
|
|
||||||
for which you have or can give appropriate copyright permission.
|
|
||||||
|
|
||||||
Notwithstanding any other provision of this License, for material you
|
|
||||||
add to a covered work, you may (if authorized by the copyright holders of
|
|
||||||
that material) supplement the terms of this License with terms:
|
|
||||||
|
|
||||||
a) Disclaiming warranty or limiting liability differently from the
|
|
||||||
terms of sections 15 and 16 of this License; or
|
|
||||||
|
|
||||||
b) Requiring preservation of specified reasonable legal notices or
|
|
||||||
author attributions in that material or in the Appropriate Legal
|
|
||||||
Notices displayed by works containing it; or
|
|
||||||
|
|
||||||
c) Prohibiting misrepresentation of the origin of that material, or
|
|
||||||
requiring that modified versions of such material be marked in
|
|
||||||
reasonable ways as different from the original version; or
|
|
||||||
|
|
||||||
d) Limiting the use for publicity purposes of names of licensors or
|
|
||||||
authors of the material; or
|
|
||||||
|
|
||||||
e) Declining to grant rights under trademark law for use of some
|
|
||||||
trade names, trademarks, or service marks; or
|
|
||||||
|
|
||||||
f) Requiring indemnification of licensors and authors of that
|
|
||||||
material by anyone who conveys the material (or modified versions of
|
|
||||||
it) with contractual assumptions of liability to the recipient, for
|
|
||||||
any liability that these contractual assumptions directly impose on
|
|
||||||
those licensors and authors.
|
|
||||||
|
|
||||||
All other non-permissive additional terms are considered "further
|
|
||||||
restrictions" within the meaning of section 10. If the Program as you
|
|
||||||
received it, or any part of it, contains a notice stating that it is
|
|
||||||
governed by this License along with a term that is a further
|
|
||||||
restriction, you may remove that term. If a license document contains
|
|
||||||
a further restriction but permits relicensing or conveying under this
|
|
||||||
License, you may add to a covered work material governed by the terms
|
|
||||||
of that license document, provided that the further restriction does
|
|
||||||
not survive such relicensing or conveying.
|
|
||||||
|
|
||||||
If you add terms to a covered work in accord with this section, you
|
|
||||||
must place, in the relevant source files, a statement of the
|
|
||||||
additional terms that apply to those files, or a notice indicating
|
|
||||||
where to find the applicable terms.
|
|
||||||
|
|
||||||
Additional terms, permissive or non-permissive, may be stated in the
|
|
||||||
form of a separately written license, or stated as exceptions;
|
|
||||||
the above requirements apply either way.
|
|
||||||
|
|
||||||
8. Termination.
|
|
||||||
|
|
||||||
You may not propagate or modify a covered work except as expressly
|
|
||||||
provided under this License. Any attempt otherwise to propagate or
|
|
||||||
modify it is void, and will automatically terminate your rights under
|
|
||||||
this License (including any patent licenses granted under the third
|
|
||||||
paragraph of section 11).
|
|
||||||
|
|
||||||
However, if you cease all violation of this License, then your
|
|
||||||
license from a particular copyright holder is reinstated (a)
|
|
||||||
provisionally, unless and until the copyright holder explicitly and
|
|
||||||
finally terminates your license, and (b) permanently, if the copyright
|
|
||||||
holder fails to notify you of the violation by some reasonable means
|
|
||||||
prior to 60 days after the cessation.
|
|
||||||
|
|
||||||
Moreover, your license from a particular copyright holder is
|
|
||||||
reinstated permanently if the copyright holder notifies you of the
|
|
||||||
violation by some reasonable means, this is the first time you have
|
|
||||||
received notice of violation of this License (for any work) from that
|
|
||||||
copyright holder, and you cure the violation prior to 30 days after
|
|
||||||
your receipt of the notice.
|
|
||||||
|
|
||||||
Termination of your rights under this section does not terminate the
|
|
||||||
licenses of parties who have received copies or rights from you under
|
|
||||||
this License. If your rights have been terminated and not permanently
|
|
||||||
reinstated, you do not qualify to receive new licenses for the same
|
|
||||||
material under section 10.
|
|
||||||
|
|
||||||
9. Acceptance Not Required for Having Copies.
|
|
||||||
|
|
||||||
You are not required to accept this License in order to receive or
|
|
||||||
run a copy of the Program. Ancillary propagation of a covered work
|
|
||||||
occurring solely as a consequence of using peer-to-peer transmission
|
|
||||||
to receive a copy likewise does not require acceptance. However,
|
|
||||||
nothing other than this License grants you permission to propagate or
|
|
||||||
modify any covered work. These actions infringe copyright if you do
|
|
||||||
not accept this License. Therefore, by modifying or propagating a
|
|
||||||
covered work, you indicate your acceptance of this License to do so.
|
|
||||||
|
|
||||||
10. Automatic Licensing of Downstream Recipients.
|
|
||||||
|
|
||||||
Each time you convey a covered work, the recipient automatically
|
|
||||||
receives a license from the original licensors, to run, modify and
|
|
||||||
propagate that work, subject to this License. You are not responsible
|
|
||||||
for enforcing compliance by third parties with this License.
|
|
||||||
|
|
||||||
An "entity transaction" is a transaction transferring control of an
|
|
||||||
organization, or substantially all assets of one, or subdividing an
|
|
||||||
organization, or merging organizations. If propagation of a covered
|
|
||||||
work results from an entity transaction, each party to that
|
|
||||||
transaction who receives a copy of the work also receives whatever
|
|
||||||
licenses to the work the party's predecessor in interest had or could
|
|
||||||
give under the previous paragraph, plus a right to possession of the
|
|
||||||
Corresponding Source of the work from the predecessor in interest, if
|
|
||||||
the predecessor has it or can get it with reasonable efforts.
|
|
||||||
|
|
||||||
You may not impose any further restrictions on the exercise of the
|
|
||||||
rights granted or affirmed under this License. For example, you may
|
|
||||||
not impose a license fee, royalty, or other charge for exercise of
|
|
||||||
rights granted under this License, and you may not initiate litigation
|
|
||||||
(including a cross-claim or counterclaim in a lawsuit) alleging that
|
|
||||||
any patent claim is infringed by making, using, selling, offering for
|
|
||||||
sale, or importing the Program or any portion of it.
|
|
||||||
|
|
||||||
11. Patents.
|
|
||||||
|
|
||||||
A "contributor" is a copyright holder who authorizes use under this
|
|
||||||
License of the Program or a work on which the Program is based. The
|
|
||||||
work thus licensed is called the contributor's "contributor version".
|
|
||||||
|
|
||||||
A contributor's "essential patent claims" are all patent claims
|
|
||||||
owned or controlled by the contributor, whether already acquired or
|
|
||||||
hereafter acquired, that would be infringed by some manner, permitted
|
|
||||||
by this License, of making, using, or selling its contributor version,
|
|
||||||
but do not include claims that would be infringed only as a
|
|
||||||
consequence of further modification of the contributor version. For
|
|
||||||
purposes of this definition, "control" includes the right to grant
|
|
||||||
patent sublicenses in a manner consistent with the requirements of
|
|
||||||
this License.
|
|
||||||
|
|
||||||
Each contributor grants you a non-exclusive, worldwide, royalty-free
|
|
||||||
patent license under the contributor's essential patent claims, to
|
|
||||||
make, use, sell, offer for sale, import and otherwise run, modify and
|
|
||||||
propagate the contents of its contributor version.
|
|
||||||
|
|
||||||
In the following three paragraphs, a "patent license" is any express
|
|
||||||
agreement or commitment, however denominated, not to enforce a patent
|
|
||||||
(such as an express permission to practice a patent or covenant not to
|
|
||||||
sue for patent infringement). To "grant" such a patent license to a
|
|
||||||
party means to make such an agreement or commitment not to enforce a
|
|
||||||
patent against the party.
|
|
||||||
|
|
||||||
If you convey a covered work, knowingly relying on a patent license,
|
|
||||||
and the Corresponding Source of the work is not available for anyone
|
|
||||||
to copy, free of charge and under the terms of this License, through a
|
|
||||||
publicly available network server or other readily accessible means,
|
|
||||||
then you must either (1) cause the Corresponding Source to be so
|
|
||||||
available, or (2) arrange to deprive yourself of the benefit of the
|
|
||||||
patent license for this particular work, or (3) arrange, in a manner
|
|
||||||
consistent with the requirements of this License, to extend the patent
|
|
||||||
license to downstream recipients. "Knowingly relying" means you have
|
|
||||||
actual knowledge that, but for the patent license, your conveying the
|
|
||||||
covered work in a country, or your recipient's use of the covered work
|
|
||||||
in a country, would infringe one or more identifiable patents in that
|
|
||||||
country that you have reason to believe are valid.
|
|
||||||
|
|
||||||
If, pursuant to or in connection with a single transaction or
|
|
||||||
arrangement, you convey, or propagate by procuring conveyance of, a
|
|
||||||
covered work, and grant a patent license to some of the parties
|
|
||||||
receiving the covered work authorizing them to use, propagate, modify
|
|
||||||
or convey a specific copy of the covered work, then the patent license
|
|
||||||
you grant is automatically extended to all recipients of the covered
|
|
||||||
work and works based on it.
|
|
||||||
|
|
||||||
A patent license is "discriminatory" if it does not include within
|
|
||||||
the scope of its coverage, prohibits the exercise of, or is
|
|
||||||
conditioned on the non-exercise of one or more of the rights that are
|
|
||||||
specifically granted under this License. You may not convey a covered
|
|
||||||
work if you are a party to an arrangement with a third party that is
|
|
||||||
in the business of distributing software, under which you make payment
|
|
||||||
to the third party based on the extent of your activity of conveying
|
|
||||||
the work, and under which the third party grants, to any of the
|
|
||||||
parties who would receive the covered work from you, a discriminatory
|
|
||||||
patent license (a) in connection with copies of the covered work
|
|
||||||
conveyed by you (or copies made from those copies), or (b) primarily
|
|
||||||
for and in connection with specific products or compilations that
|
|
||||||
contain the covered work, unless you entered into that arrangement,
|
|
||||||
or that patent license was granted, prior to 28 March 2007.
|
|
||||||
|
|
||||||
Nothing in this License shall be construed as excluding or limiting
|
|
||||||
any implied license or other defenses to infringement that may
|
|
||||||
otherwise be available to you under applicable patent law.
|
|
||||||
|
|
||||||
12. No Surrender of Others' Freedom.
|
|
||||||
|
|
||||||
If conditions are imposed on you (whether by court order, agreement or
|
|
||||||
otherwise) that contradict the conditions of this License, they do not
|
|
||||||
excuse you from the conditions of this License. If you cannot convey a
|
|
||||||
covered work so as to satisfy simultaneously your obligations under this
|
|
||||||
License and any other pertinent obligations, then as a consequence you may
|
|
||||||
not convey it at all. For example, if you agree to terms that obligate you
|
|
||||||
to collect a royalty for further conveying from those to whom you convey
|
|
||||||
the Program, the only way you could satisfy both those terms and this
|
|
||||||
License would be to refrain entirely from conveying the Program.
|
|
||||||
|
|
||||||
13. Use with the GNU Affero General Public License.
|
|
||||||
|
|
||||||
Notwithstanding any other provision of this License, you have
|
|
||||||
permission to link or combine any covered work with a work licensed
|
|
||||||
under version 3 of the GNU Affero General Public License into a single
|
|
||||||
combined work, and to convey the resulting work. The terms of this
|
|
||||||
License will continue to apply to the part which is the covered work,
|
|
||||||
but the special requirements of the GNU Affero General Public License,
|
|
||||||
section 13, concerning interaction through a network will apply to the
|
|
||||||
combination as such.
|
|
||||||
|
|
||||||
14. Revised Versions of this License.
|
|
||||||
|
|
||||||
The Free Software Foundation may publish revised and/or new versions of
|
|
||||||
the GNU General Public License from time to time. Such new versions will
|
|
||||||
be similar in spirit to the present version, but may differ in detail to
|
|
||||||
address new problems or concerns.
|
|
||||||
|
|
||||||
Each version is given a distinguishing version number. If the
|
|
||||||
Program specifies that a certain numbered version of the GNU General
|
|
||||||
Public License "or any later version" applies to it, you have the
|
|
||||||
option of following the terms and conditions either of that numbered
|
|
||||||
version or of any later version published by the Free Software
|
|
||||||
Foundation. If the Program does not specify a version number of the
|
|
||||||
GNU General Public License, you may choose any version ever published
|
|
||||||
by the Free Software Foundation.
|
|
||||||
|
|
||||||
If the Program specifies that a proxy can decide which future
|
|
||||||
versions of the GNU General Public License can be used, that proxy's
|
|
||||||
public statement of acceptance of a version permanently authorizes you
|
|
||||||
to choose that version for the Program.
|
|
||||||
|
|
||||||
Later license versions may give you additional or different
|
|
||||||
permissions. However, no additional obligations are imposed on any
|
|
||||||
author or copyright holder as a result of your choosing to follow a
|
|
||||||
later version.
|
|
||||||
|
|
||||||
15. Disclaimer of Warranty.
|
|
||||||
|
|
||||||
THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY
|
|
||||||
APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT
|
|
||||||
HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY
|
|
||||||
OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO,
|
|
||||||
THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
|
|
||||||
PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM
|
|
||||||
IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF
|
|
||||||
ALL NECESSARY SERVICING, REPAIR OR CORRECTION.
|
|
||||||
|
|
||||||
16. Limitation of Liability.
|
|
||||||
|
|
||||||
IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
|
|
||||||
WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS
|
|
||||||
THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY
|
|
||||||
GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE
|
|
||||||
USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF
|
|
||||||
DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD
|
|
||||||
PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS),
|
|
||||||
EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF
|
|
||||||
SUCH DAMAGES.
|
|
||||||
|
|
||||||
17. Interpretation of Sections 15 and 16.
|
|
||||||
|
|
||||||
If the disclaimer of warranty and limitation of liability provided
|
|
||||||
above cannot be given local legal effect according to their terms,
|
|
||||||
reviewing courts shall apply local law that most closely approximates
|
|
||||||
an absolute waiver of all civil liability in connection with the
|
|
||||||
Program, unless a warranty or assumption of liability accompanies a
|
|
||||||
copy of the Program in return for a fee.
|
|
||||||
|
|
||||||
END OF TERMS AND CONDITIONS
|
|
||||||
|
|
||||||
How to Apply These Terms to Your New Programs
|
|
||||||
|
|
||||||
If you develop a new program, and you want it to be of the greatest
|
|
||||||
possible use to the public, the best way to achieve this is to make it
|
|
||||||
free software which everyone can redistribute and change under these terms.
|
|
||||||
|
|
||||||
To do so, attach the following notices to the program. It is safest
|
|
||||||
to attach them to the start of each source file to most effectively
|
|
||||||
state the exclusion of warranty; and each file should have at least
|
|
||||||
the "copyright" line and a pointer to where the full notice is found.
|
|
||||||
|
|
||||||
<one line to give the program's name and a brief idea of what it does.>
|
|
||||||
Copyright (C) <year> <name of author>
|
|
||||||
|
|
||||||
This program is free software: you can redistribute it and/or modify
|
|
||||||
it under the terms of the GNU General Public License as published by
|
|
||||||
the Free Software Foundation, either version 3 of the License, or
|
|
||||||
(at your option) any later version.
|
|
||||||
|
|
||||||
This program is distributed in the hope that it will be useful,
|
|
||||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
||||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
||||||
GNU General Public License for more details.
|
|
||||||
|
|
||||||
You should have received a copy of the GNU General Public License
|
|
||||||
along with this program. If not, see <http://www.gnu.org/licenses/>.
|
|
||||||
|
|
||||||
Also add information on how to contact you by electronic and paper mail.
|
|
||||||
|
|
||||||
If the program does terminal interaction, make it output a short
|
|
||||||
notice like this when it starts in an interactive mode:
|
|
||||||
|
|
||||||
<program> Copyright (C) <year> <name of author>
|
|
||||||
This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
|
|
||||||
This is free software, and you are welcome to redistribute it
|
|
||||||
under certain conditions; type `show c' for details.
|
|
||||||
|
|
||||||
The hypothetical commands `show w' and `show c' should show the appropriate
|
|
||||||
parts of the General Public License. Of course, your program's commands
|
|
||||||
might be different; for a GUI interface, you would use an "about box".
|
|
||||||
|
|
||||||
You should also get your employer (if you work as a programmer) or school,
|
|
||||||
if any, to sign a "copyright disclaimer" for the program, if necessary.
|
|
||||||
For more information on this, and how to apply and follow the GNU GPL, see
|
|
||||||
<http://www.gnu.org/licenses/>.
|
|
||||||
|
|
||||||
The GNU General Public License does not permit incorporating your program
|
|
||||||
into proprietary programs. If your program is a subroutine library, you
|
|
||||||
may consider it more useful to permit linking proprietary applications with
|
|
||||||
the library. If this is what you want to do, use the GNU Lesser General
|
|
||||||
Public License instead of this License. But first, please read
|
|
||||||
<http://www.gnu.org/philosophy/why-not-lgpl.html>.
|
|
||||||
@@ -1,27 +1,26 @@
|
|||||||
.PHONY: test build-all deploy
|
.PHONY: test test-cover
|
||||||
|
|
||||||
test:
|
PKG=github.com/zricethezav/gitleaks
|
||||||
go get golang.org/x/lint/golint
|
VERSION := `git fetch --tags && git tag | sort -V | tail -1`
|
||||||
go fmt
|
LDFLAGS=-ldflags "-X=github.com/zricethezav/gitleaks/v8/cmd.Version=$(VERSION)"
|
||||||
golint
|
COVER=--cover --coverprofile=cover.out
|
||||||
go test --race --cover -run=Test$
|
|
||||||
deploy:
|
|
||||||
@echo "$(DOCKER_PASSWORD)" | docker login -u "$(DOCKER_USERNAME)" --password-stdin
|
|
||||||
docker build -f Dockerfile -t $(REPO):$(TAG) .
|
|
||||||
echo "Pushing $(REPO):$(COMMIT) $(REPO):$(TAG)"
|
|
||||||
docker push $(REPO)
|
|
||||||
build-all:
|
|
||||||
rm -rf build
|
|
||||||
mkdir build
|
|
||||||
env GOOS="windows" GOARCH="amd64" go build -o "build/gitleaks-windows-amd64.exe"
|
|
||||||
env GOOS="windows" GOARCH="386" go build -o "build/gitleaks-windows-386.exe"
|
|
||||||
env GOOS="linux" GOARCH="amd64" go build -o "build/gitleaks-linux-amd64"
|
|
||||||
env GOOS="linux" GOARCH="arm" go build -o "build/gitleaks-linux-arm"
|
|
||||||
env GOOS="linux" GOARCH="mips" go build -o "build/gitleaks-linux-mips"
|
|
||||||
env GOOS="linux" GOARCH="mips" go build -o "build/gitleaks-linux-mips"
|
|
||||||
env GOOS="darwin" GOARCH="amd64" go build -o "build/gitleaks-darwin-amd64"
|
|
||||||
benchmark:
|
|
||||||
go test -run=Benchmark -bench=. -benchtime=5s
|
|
||||||
benchmark-fast:
|
|
||||||
go test -bench=BenchmarkAuditLeakRepo -run=BenchmarkAuditLeakRepo$
|
|
||||||
|
|
||||||
|
test-cover:
|
||||||
|
go test -v ./... --race $(COVER) $(PKG)
|
||||||
|
go tool cover -html=cover.out
|
||||||
|
|
||||||
|
format:
|
||||||
|
go fmt ./...
|
||||||
|
|
||||||
|
test: format
|
||||||
|
go vet ./...
|
||||||
|
go test -v ./... --race $(PKG)
|
||||||
|
|
||||||
|
build: format
|
||||||
|
go vet ./...
|
||||||
|
go mod tidy
|
||||||
|
go build $(LDFLAGS)
|
||||||
|
|
||||||
|
clean:
|
||||||
|
find . -type f -name '*.got.*' -delete
|
||||||
|
find . -type f -name '*.out' -delete
|
||||||
@@ -1,70 +1,396 @@
|
|||||||
<p align="center">
|
# gitleaks
|
||||||
<img alt="gitleaks" src="https://raw.githubusercontent.com/zricethezav/gifs/master/gitleaks5.png" height="140" />
|
|
||||||
<p align="center">
|
```
|
||||||
<a href="https://travis-ci.org/zricethezav/gitleaks"><img alt="Travis" src="https://img.shields.io/travis/zricethezav/gitleaks/master.svg?style=flat-square"></a>
|
┌─○───┐
|
||||||
|
│ │╲ │
|
||||||
|
│ │ ○ │
|
||||||
|
│ ○ ░ │
|
||||||
|
└─░───┘
|
||||||
|
```
|
||||||
|
|
||||||
|
<p align="left">
|
||||||
|
<p align="left">
|
||||||
|
<a href="https://github.com/zricethezav/gitleaks/actions/workflows/test.yml">
|
||||||
|
<img alt="Github Test" src="https://github.com/zricethezav/gitleaks/actions/workflows/test.yml/badge.svg">
|
||||||
|
</a>
|
||||||
|
<a href="https://hub.docker.com/r/zricethezav/gitleaks">
|
||||||
|
<img src="https://img.shields.io/docker/pulls/zricethezav/gitleaks.svg" />
|
||||||
|
</a>
|
||||||
|
<a href="https://www.jit.io/jit-open-source-gitleaks?utm_source=github&utm_medium=badge&utm_campaign=GitleaksReadme&utm_id=oss&items=item-secret-detection">
|
||||||
|
<img src="https://img.shields.io/badge/Secured%20by-Jit-B8287F?style=?style=plastic" />
|
||||||
|
</a>
|
||||||
|
<a href="https://github.com/zricethezav/gitleaks-action">
|
||||||
|
<img alt="gitleaks badge" src="https://img.shields.io/badge/protected%20by-gitleaks-blue">
|
||||||
|
</a>
|
||||||
|
<a href="https://twitter.com/intent/follow?screen_name=zricethezav">
|
||||||
|
<img src="https://img.shields.io/twitter/follow/zricethezav?label=Follow%20zricethezav&style=social&color=blue" alt="Follow @zricethezav" />
|
||||||
|
</a>
|
||||||
</p>
|
</p>
|
||||||
</p>
|
</p>
|
||||||
|
|
||||||
## Audit git repos for secrets
|
Gitleaks is a SAST tool for **detecting** and **preventing** hardcoded secrets like passwords, api keys, and tokens in git repos. Gitleaks is an **easy-to-use, all-in-one solution** for detecting secrets, past or present, in your code.
|
||||||
### Powered by src-d's [go-git](https://github.com/src-d/go-git)
|
|
||||||
<p align="center">
|
|
||||||
<img src="https://cdn.rawgit.com/zricethezav/5bf8259b7fea0170becffc06b8588edb/raw/f762769fe20ef3669bff34612b1bede6457631e6/termtosvg_je8bp82s.svg">
|
|
||||||
</p>
|
|
||||||
|
|
||||||
#### Installing
|
| Demos |
|
||||||
|
| ----------- |
|
||||||
|
| CLI [](https://asciinema.org/a/455683)|
|
||||||
|
| [Github-Action](https://github.com/gitleaks/gitleaks-action) |
|
||||||
|
|
||||||
|
## Getting Started
|
||||||
|
|
||||||
|
Gitleaks can be installed using Homebrew, Docker, or Go. Gitleaks is also available in binary form for many popular platforms and OS types on the [releases page](https://github.com/zricethezav/gitleaks/releases). In addition, Gitleaks can be implemented as a pre-commit hook directly in your repo or as a GitHub action using [Gitleaks-Action](https://github.com/gitleaks/gitleaks-action) (see demo above).
|
||||||
|
|
||||||
|
### MacOS
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
go get -u github.com/zricethezav/gitleaks
|
brew install gitleaks
|
||||||
```
|
```
|
||||||
Or download from release binaries [here](https://github.com/zricethezav/gitleaks/releases)
|
|
||||||
|
|
||||||
|
### Docker
|
||||||
|
|
||||||
|
#### DockerHub
|
||||||
|
|
||||||
|
```bash
|
||||||
|
docker pull zricethezav/gitleaks:latest
|
||||||
|
docker run -v ${path_to_host_folder_to_scan}:/path zricethezav/gitleaks:latest [COMMAND] --source="/path" [OPTIONS]
|
||||||
|
```
|
||||||
|
|
||||||
|
#### ghcr.io
|
||||||
|
|
||||||
|
```bash
|
||||||
|
docker pull ghcr.io/zricethezav/gitleaks:latest
|
||||||
|
docker run -v ${path_to_host_folder_to_scan}:/path zricethezav/gitleaks:latest [COMMAND] --source="/path" [OPTIONS]
|
||||||
|
```
|
||||||
|
|
||||||
|
### From Source
|
||||||
|
|
||||||
|
1. Download and install Go from https://golang.org/dl/
|
||||||
|
2. Clone the repo
|
||||||
|
|
||||||
|
```bash
|
||||||
|
git clone https://github.com/zricethezav/gitleaks.git
|
||||||
|
```
|
||||||
|
|
||||||
|
3. Build the binary
|
||||||
|
|
||||||
|
```bash
|
||||||
|
cd gitleaks
|
||||||
|
make build
|
||||||
|
```
|
||||||
|
|
||||||
|
### Github Action
|
||||||
|
|
||||||
|
Check out the official [Gitleaks GitHub Action](https://github.com/gitleaks/gitleaks-action)
|
||||||
|
|
||||||
|
```
|
||||||
|
name: gitleaks
|
||||||
|
on: [pull_request, push, workflow_dispatch]
|
||||||
|
jobs:
|
||||||
|
scan:
|
||||||
|
name: gitleaks
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v3
|
||||||
|
with:
|
||||||
|
fetch-depth: 0
|
||||||
|
- uses: gitleaks/gitleaks-action@v2
|
||||||
|
env:
|
||||||
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
GITLEAKS_LICENSE: ${{ secrets.GITLEAKS_LICENSE}} # Only required for Organizations, not personal accounts.
|
||||||
|
```
|
||||||
|
|
||||||
|
### Pre-Commit
|
||||||
|
|
||||||
|
1. Install pre-commit from https://pre-commit.com/#install
|
||||||
|
2. Create a `.pre-commit-config.yaml` file at the root of your repository with the following content:
|
||||||
|
|
||||||
|
```
|
||||||
|
repos:
|
||||||
|
- repo: https://github.com/zricethezav/gitleaks
|
||||||
|
rev: v8.2.0
|
||||||
|
hooks:
|
||||||
|
- id: gitleaks
|
||||||
|
```
|
||||||
|
|
||||||
|
for a [native execution of GitLeaks](https://github.com/zricethezav/gitleaks/releases) or use the [`gitleaks-docker` pre-commit ID](https://github.com/zricethezav/gitleaks/blob/master/.pre-commit-hooks.yaml) for executing GitLeaks using the [official Docker images](#docker)
|
||||||
|
|
||||||
|
3. Install with `pre-commit install`
|
||||||
|
4. Now you're all set!
|
||||||
|
|
||||||
|
```
|
||||||
|
➜ git commit -m "this commit contains a secret"
|
||||||
|
Detect hardcoded secrets.................................................Failed
|
||||||
|
```
|
||||||
|
|
||||||
|
Note: to disable the gitleaks pre-commit hook you can prepend `SKIP=gitleaks` to the commit command
|
||||||
|
and it will skip running gitleaks
|
||||||
|
|
||||||
|
```
|
||||||
|
➜ SKIP=gitleaks git commit -m "skip gitleaks check"
|
||||||
|
Detect hardcoded secrets................................................Skipped
|
||||||
|
```
|
||||||
|
|
||||||
|
## Usage
|
||||||
|
|
||||||
#### Usage and Options
|
|
||||||
```
|
```
|
||||||
Usage:
|
Usage:
|
||||||
gitleaks [OPTIONS]
|
gitleaks [command]
|
||||||
|
|
||||||
Application Options:
|
Available Commands:
|
||||||
-r, --repo= Repo url to audit
|
completion generate the autocompletion script for the specified shell
|
||||||
--github-user= Github user to audit
|
detect Detect secrets in code
|
||||||
--github-org= Github organization to audit
|
help Help about any command
|
||||||
--github-url= GitHub API Base URL, use for GitHub Enterprise. Example: https://github.example.com/api/v3/ (default: https://api.github.com/)
|
protect Protect secrets in code
|
||||||
-p, --private Include private repos in audit
|
version Display gitleaks version
|
||||||
-b, --branch= branch name to audit (defaults to HEAD)
|
|
||||||
-c, --commit= sha of commit to stop at
|
|
||||||
--depth= maximum commit depth
|
|
||||||
--repo-path= Path to repo
|
|
||||||
--owner-path= Path to owner directory (repos discovered)
|
|
||||||
--max-go= Maximum number of concurrent go-routines gitleaks spawns
|
|
||||||
--disk Clones repo(s) to disk
|
|
||||||
--all-refs run audit on all refs
|
|
||||||
--single-search= single regular expression to search for
|
|
||||||
--config= path to gitleaks config
|
|
||||||
--ssh-key= path to ssh key
|
|
||||||
--exclude-forks exclude forks for organization/user audits
|
|
||||||
-e, --entropy= Include entropy checks during audit. Entropy scale: 0.0(no entropy) - 8.0(max entropy)
|
|
||||||
-l, --log= log level
|
|
||||||
-v, --verbose Show verbose output from gitleaks audit
|
|
||||||
--report= path to write report file
|
|
||||||
--redact redact secrets from log messages and report
|
|
||||||
--version version number
|
|
||||||
--sample-config prints a sample config file
|
|
||||||
|
|
||||||
Help Options:
|
Flags:
|
||||||
-h, --help Show this help message
|
-c, --config string config file path
|
||||||
```
|
order of precedence:
|
||||||
#### Exit Codes
|
1. --config/-c
|
||||||
```
|
2. env var GITLEAKS_CONFIG
|
||||||
0: no leaks
|
3. (--source/-s)/.gitleaks.toml
|
||||||
1: leaks present
|
If none of the three options are used, then gitleaks will use the default config
|
||||||
2: error encountered
|
--exit-code string exit code when leaks have been encountered (default: 1)
|
||||||
|
-h, --help help for gitleaks
|
||||||
|
-l, --log-level string log level (debug, info, warn, error, fatal) (default "info")
|
||||||
|
--redact redact secrets from logs and stdout
|
||||||
|
-f, --report-format string output format (json, csv, sarif)
|
||||||
|
-r, --report-path string report file
|
||||||
|
-s, --source string path to source (git repo, directory, file)
|
||||||
|
-v, --verbose show verbose output from scan
|
||||||
|
|
||||||
|
Use "gitleaks [command] --help" for more information about a command.
|
||||||
```
|
```
|
||||||
|
|
||||||
#### Additional Examples and Explanations
|
### Commands
|
||||||
Check the wiki [here](https://github.com/zricethezav/gitleaks/wiki)
|
|
||||||
|
|
||||||
### If you find a valid leak in a repo
|
There are two commands you will use to detect secrets; `detect` and `protect`.
|
||||||
Please read this [Github article on removing sensitive data from a repository](https://help.github.com/articles/removing-sensitive-data-from-a-repository/) to remove the sensitive information from your history.
|
|
||||||
|
|
||||||
### Run me with docker
|
#### Detect
|
||||||
Simply run `docker run --rm --name=gitleaks zricethezav/gitleaks --help`
|
|
||||||
|
The `detect` command is used to scan repos, directories, and files. This command can be used on developer machines and in CI environments.
|
||||||
|
|
||||||
|
When running `detect` on a git repository, gitleaks will parse the output of a `git log -p` command (you can see how this executed
|
||||||
|
[here](https://github.com/zricethezav/gitleaks/blob/7240e16769b92d2a1b137c17d6bf9d55a8562899/git/git.go#L17-L25)).
|
||||||
|
[`git log -p` generates patches](https://git-scm.com/docs/git-log#_generating_patch_text_with_p) which gitleaks will use to detect secrets.
|
||||||
|
You can configure what commits `git log` will range over by using the `--log-opts` flag. `--log-opts` accepts any option for `git log -p`.
|
||||||
|
For example, if you wanted to run gitleaks on a range of commits you could use the following command: `gitleaks detect --source . --log-opts="--all commitA..commitB"`.
|
||||||
|
See the `git log` [documentation](https://git-scm.com/docs/git-log) for more information.
|
||||||
|
|
||||||
|
You can scan files and directories by using the `--no-git` option.
|
||||||
|
|
||||||
|
#### Protect
|
||||||
|
|
||||||
|
The `protect` command is used to uncommitted changes in a git repo. This command should be used on developer machines in accordance with
|
||||||
|
[shifting left on security](https://cloud.google.com/architecture/devops/devops-tech-shifting-left-on-security).
|
||||||
|
When running `protect` on a git repository, gitleaks will parse the output of a `git diff` command (you can see how this executed
|
||||||
|
[here](https://github.com/zricethezav/gitleaks/blob/7240e16769b92d2a1b137c17d6bf9d55a8562899/git/git.go#L48-L49)). You can set the
|
||||||
|
`--staged` flag to check for changes in commits that have been `git add`ed. The `--staged` flag should be used when running Gitleaks
|
||||||
|
as a pre-commit.
|
||||||
|
|
||||||
|
**NOTE**: the `protect` command can only be used on git repos, running `protect` on files or directories will result in an error message.
|
||||||
|
|
||||||
|
### Verify Findings
|
||||||
|
|
||||||
|
You can verify a finding found by gitleaks using a `git log` command.
|
||||||
|
Example output:
|
||||||
|
|
||||||
|
```
|
||||||
|
{
|
||||||
|
"Description": "AWS",
|
||||||
|
"StartLine": 37,
|
||||||
|
"EndLine": 37,
|
||||||
|
"StartColumn": 19,
|
||||||
|
"EndColumn": 38,
|
||||||
|
"Match": "\t\t\"aws_secret= \\\"AKIAIMNOJVGFDXXXE4OA\\\"\": true,",
|
||||||
|
"Secret": "AKIAIMNOJVGFDXXXE4OA",
|
||||||
|
"File": "checks_test.go",
|
||||||
|
"Commit": "ec2fc9d6cb0954fb3b57201cf6133c48d8ca0d29",
|
||||||
|
"Entropy": 0,
|
||||||
|
"Author": "zricethezav",
|
||||||
|
"Email": "thisispublicanyways@gmail.com",
|
||||||
|
"Date": "2018-01-28 17:39:00 -0500 -0500",
|
||||||
|
"Message": "[update] entropy check",
|
||||||
|
"Tags": [],
|
||||||
|
"RuleID": "aws-access-token"
|
||||||
|
}
|
||||||
|
|
||||||
|
```
|
||||||
|
|
||||||
|
We can use the following format to verify the leak:
|
||||||
|
|
||||||
|
```
|
||||||
|
git log -L {StartLine,EndLine}:{File} {Commit}
|
||||||
|
```
|
||||||
|
|
||||||
|
So in this example it would look like:
|
||||||
|
|
||||||
|
```
|
||||||
|
git log -L 37,37:checks_test.go ec2fc9d6cb0954fb3b57201cf6133c48d8ca0d29
|
||||||
|
```
|
||||||
|
|
||||||
|
Which gives us:
|
||||||
|
|
||||||
|
```
|
||||||
|
commit ec2fc9d6cb0954fb3b57201cf6133c48d8ca0d29
|
||||||
|
Author: zricethezav <thisispublicanyways@gmail.com>
|
||||||
|
Date: Sun Jan 28 17:39:00 2018 -0500
|
||||||
|
|
||||||
|
[update] entropy check
|
||||||
|
|
||||||
|
diff --git a/checks_test.go b/checks_test.go
|
||||||
|
--- a/checks_test.go
|
||||||
|
+++ b/checks_test.go
|
||||||
|
@@ -28,0 +37,1 @@
|
||||||
|
+ "aws_secret= \"AKIAIMNOJVGFDXXXE4OA\"": true,
|
||||||
|
|
||||||
|
```
|
||||||
|
|
||||||
|
## Pre-Commit hook
|
||||||
|
|
||||||
|
You can run Gitleaks as a pre-commit hook by copying the example `pre-commit.py` script into
|
||||||
|
your `.git/hooks/` directory.
|
||||||
|
|
||||||
|
## Configuration
|
||||||
|
|
||||||
|
Gitleaks offers a configuration format you can follow to write your own secret detection rules:
|
||||||
|
|
||||||
|
```toml
|
||||||
|
# Title for the gitleaks configuration file.
|
||||||
|
title = "Gitleaks title"
|
||||||
|
|
||||||
|
# Extend the base (this) configuration. When you extend a configuration
|
||||||
|
# the base rules take precendence over the extended rules. I.e, if there are
|
||||||
|
# duplicate rules in both the base configuration and the extended configuration
|
||||||
|
# the base rules will override the extended rules.
|
||||||
|
# Another thing to know with extending configurations is you can chain together
|
||||||
|
# multiple configuration files to a depth of 2. Allowlist arrays are appended
|
||||||
|
# and can contain duplicates.
|
||||||
|
# useDefault and path can NOT be used at the same time. Choose one.
|
||||||
|
[extend]
|
||||||
|
# useDefault will extend the base configuration with the default gitleaks config:
|
||||||
|
# https://github.com/zricethezav/gitleaks/blob/master/config/gitleaks.toml
|
||||||
|
useDefault = true
|
||||||
|
# or you can supply a path to a configuration. Path is relative to where gitleaks
|
||||||
|
# was invoked, not the location of the base config.
|
||||||
|
path = "common_config.toml"
|
||||||
|
|
||||||
|
# An array of tables that contain information that define instructions
|
||||||
|
# on how to detect secrets
|
||||||
|
[[rules]]
|
||||||
|
|
||||||
|
# Unique identifier for this rule
|
||||||
|
id = "awesome-rule-1"
|
||||||
|
|
||||||
|
# Short human readable description of the rule.
|
||||||
|
description = "awesome rule 1"
|
||||||
|
|
||||||
|
# Golang regular expression used to detect secrets. Note Golang's regex engine
|
||||||
|
# does not support lookaheads.
|
||||||
|
regex = '''one-go-style-regex-for-this-rule'''
|
||||||
|
|
||||||
|
# Golang regular expression used to match paths. This can be used as a standalone rule or it can be used
|
||||||
|
# in conjunction with a valid `regex` entry.
|
||||||
|
path = '''a-file-path-regex'''
|
||||||
|
|
||||||
|
# Array of strings used for metadata and reporting purposes.
|
||||||
|
tags = ["tag","another tag"]
|
||||||
|
|
||||||
|
# Int used to extract secret from regex match and used as the group that will have
|
||||||
|
# its entropy checked if `entropy` is set.
|
||||||
|
secretGroup = 3
|
||||||
|
|
||||||
|
# Float representing the minimum shannon entropy a regex group must have to be considered a secret.
|
||||||
|
entropy = 3.5
|
||||||
|
|
||||||
|
# Keywords are used for pre-regex check filtering. Rules that contain
|
||||||
|
# keywords will perform a quick string compare check to make sure the
|
||||||
|
# keyword(s) are in the content being scanned. Ideally these values should
|
||||||
|
# either be part of the idenitifer or unique strings specific to the rule's regex
|
||||||
|
# (introduced in v8.6.0)
|
||||||
|
keywords = [
|
||||||
|
"auth",
|
||||||
|
"password",
|
||||||
|
"token",
|
||||||
|
]
|
||||||
|
|
||||||
|
# You can include an allowlist table for a single rule to reduce false positives or ignore commits
|
||||||
|
# with known/rotated secrets
|
||||||
|
[rules.allowlist]
|
||||||
|
description = "ignore commit A"
|
||||||
|
commits = [ "commit-A", "commit-B"]
|
||||||
|
paths = [
|
||||||
|
'''go\.mod''',
|
||||||
|
'''go\.sum'''
|
||||||
|
]
|
||||||
|
regexes = [
|
||||||
|
'''process''',
|
||||||
|
'''getenv''',
|
||||||
|
]
|
||||||
|
# note: stopwords targets the extracted secret, not the entire regex match
|
||||||
|
# like 'regexes' does. (stopwords introduced in 8.8.0)
|
||||||
|
stopwords = [
|
||||||
|
'''client''',
|
||||||
|
'''endpoint''',
|
||||||
|
]
|
||||||
|
|
||||||
|
|
||||||
|
# This is a global allowlist which has a higher order of precedence than rule-specific allowlists.
|
||||||
|
# If a commit listed in the `commits` field below is encountered then that commit will be skipped and no
|
||||||
|
# secrets will be detected for said commit. The same logic applies for regexes and paths.
|
||||||
|
[allowlist]
|
||||||
|
description = "global allow list"
|
||||||
|
commits = [ "commit-A", "commit-B", "commit-C"]
|
||||||
|
paths = [
|
||||||
|
'''gitleaks\.toml''',
|
||||||
|
'''(.*?)(jpg|gif|doc)'''
|
||||||
|
]
|
||||||
|
regexes = [
|
||||||
|
'''219-09-9999''',
|
||||||
|
'''078-05-1120''',
|
||||||
|
'''(9[0-9]{2}|666)-\d{2}-\d{4}''',
|
||||||
|
]
|
||||||
|
# note: stopwords targets the extracted secret, not the entire regex match
|
||||||
|
# like 'regexes' does. (stopwords introduced in 8.8.0)
|
||||||
|
stopwords = [
|
||||||
|
'''client''',
|
||||||
|
'''endpoint''',
|
||||||
|
]
|
||||||
|
```
|
||||||
|
Refer to the default [gitleaks config](https://github.com/zricethezav/gitleaks/blob/master/config/gitleaks.toml) for examples or follow the [contributing guidelines](https://github.com/zricethezav/gitleaks/blob/master/README.md).
|
||||||
|
|
||||||
|
### Additional Configuration
|
||||||
|
#### gitleaks:allow
|
||||||
|
If you are knowingly committing a test secret that gitleaks will catch you can add a `gitleaks:allow` comment to that line which will instruct gitleaks
|
||||||
|
to ignore that secret. Ex:
|
||||||
|
```
|
||||||
|
class CustomClass:
|
||||||
|
discord_client_secret = '8dyfuiRyq=vVc3RRr_edRk-fK__JItpZ' #gitleaks:allow
|
||||||
|
|
||||||
|
```
|
||||||
|
|
||||||
|
#### .gitleaksignore
|
||||||
|
You can ignore specific findings by creating a `.gitleaksignore` file at the root of your repo. In release v8.10.0 Gitleaks added a `Fingerprint` value to the Gitleaks report. Each leak, or finding, has a Fingerprint that uniquely identifies a secret. Add this fingerprint to the `.gitleaksignore` file to ignore that specific secret. See Gitleaks' [.gitleaksignore](https://github.com/zricethezav/gitleaks/blob/master/.gitleaksignore) for an example.
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
## Secured by Jit
|
||||||
|
|
||||||
|
We use [Jit](https://www.jit.io/jit-open-source-gitleaks?utm_source=github&utm_medium=readme&utm_campaign=GitleaksReadme&utm_id=oss&items=item-secret-detection) to secure our codebase, to achieve fully automated, full-stack continuous security using the world's best OSS security tools.
|
||||||
|
|
||||||
|
## Sponsorships
|
||||||
|
|
||||||
|
<p align="left">
|
||||||
|
<a href="https://www.tines.com/?utm_source=oss&utm_medium=sponsorship&utm_campaign=gitleaks">
|
||||||
|
<img alt="Tines Sponsorship" src="https://user-images.githubusercontent.com/15034943/146411864-4878f936-b4f7-49a0-b625-f9f40c704bfa.png" width=200>
|
||||||
|
</a>
|
||||||
|
</p>
|
||||||
|
|
||||||
|
## Exit Codes
|
||||||
|
|
||||||
|
You can always set the exit code when leaks are encountered with the --exit-code flag. Default exit codes below:
|
||||||
|
|
||||||
|
```
|
||||||
|
0 - no leaks present
|
||||||
|
1 - leaks or error encountered
|
||||||
|
126 - unknown flag
|
||||||
|
```
|
||||||
+133
@@ -0,0 +1,133 @@
|
|||||||
|
package cmd
|
||||||
|
|
||||||
|
import (
|
||||||
|
"os"
|
||||||
|
"path/filepath"
|
||||||
|
"time"
|
||||||
|
|
||||||
|
"github.com/rs/zerolog/log"
|
||||||
|
"github.com/spf13/cobra"
|
||||||
|
"github.com/spf13/viper"
|
||||||
|
|
||||||
|
"github.com/zricethezav/gitleaks/v8/config"
|
||||||
|
"github.com/zricethezav/gitleaks/v8/detect"
|
||||||
|
"github.com/zricethezav/gitleaks/v8/report"
|
||||||
|
)
|
||||||
|
|
||||||
|
func init() {
|
||||||
|
rootCmd.AddCommand(detectCmd)
|
||||||
|
detectCmd.Flags().String("log-opts", "", "git log options")
|
||||||
|
detectCmd.Flags().Bool("no-git", false, "treat git repo as a regular directory and scan those files, --log-opts has no effect on the scan when --no-git is set")
|
||||||
|
}
|
||||||
|
|
||||||
|
var detectCmd = &cobra.Command{
|
||||||
|
Use: "detect",
|
||||||
|
Short: "detect secrets in code",
|
||||||
|
Run: runDetect,
|
||||||
|
}
|
||||||
|
|
||||||
|
func runDetect(cmd *cobra.Command, args []string) {
|
||||||
|
initConfig()
|
||||||
|
var (
|
||||||
|
vc config.ViperConfig
|
||||||
|
findings []report.Finding
|
||||||
|
err error
|
||||||
|
)
|
||||||
|
|
||||||
|
// Load config
|
||||||
|
if err = viper.Unmarshal(&vc); err != nil {
|
||||||
|
log.Fatal().Err(err).Msg("Failed to load config")
|
||||||
|
}
|
||||||
|
cfg, err := vc.Translate()
|
||||||
|
if err != nil {
|
||||||
|
log.Fatal().Err(err).Msg("Failed to load config")
|
||||||
|
}
|
||||||
|
cfg.Path, _ = cmd.Flags().GetString("config")
|
||||||
|
|
||||||
|
// start timer
|
||||||
|
start := time.Now()
|
||||||
|
|
||||||
|
// Setup detector
|
||||||
|
detector := detect.NewDetector(cfg)
|
||||||
|
detector.Config.Path, err = cmd.Flags().GetString("config")
|
||||||
|
if err != nil {
|
||||||
|
log.Fatal().Err(err)
|
||||||
|
}
|
||||||
|
source, err := cmd.Flags().GetString("source")
|
||||||
|
if err != nil {
|
||||||
|
log.Fatal().Err(err)
|
||||||
|
}
|
||||||
|
// if config path is not set, then use the {source}/.gitleaks.toml path.
|
||||||
|
// note that there may not be a `{source}/.gitleaks.toml` file, this is ok.
|
||||||
|
if detector.Config.Path == "" {
|
||||||
|
detector.Config.Path = filepath.Join(source, ".gitleaks.toml")
|
||||||
|
}
|
||||||
|
// set verbose flag
|
||||||
|
if detector.Verbose, err = cmd.Flags().GetBool("verbose"); err != nil {
|
||||||
|
log.Fatal().Err(err)
|
||||||
|
}
|
||||||
|
// set redact flag
|
||||||
|
if detector.Redact, err = cmd.Flags().GetBool("redact"); err != nil {
|
||||||
|
log.Fatal().Err(err)
|
||||||
|
}
|
||||||
|
|
||||||
|
// check for a .gitleaksignore file
|
||||||
|
if info, err := os.Stat(filepath.Join(source, ".gitleaksignore")); !os.IsNotExist(err) && !info.IsDir() {
|
||||||
|
detector.AddGitleaksIgnore(filepath.Join(source, ".gitleaksignore"))
|
||||||
|
}
|
||||||
|
|
||||||
|
// set exit code
|
||||||
|
exitCode, err := cmd.Flags().GetInt("exit-code")
|
||||||
|
if err != nil {
|
||||||
|
log.Fatal().Err(err)
|
||||||
|
}
|
||||||
|
|
||||||
|
// determine what type of scan:
|
||||||
|
// - git: scan the history of the repo
|
||||||
|
// - no-git: scan files by treating the repo as a plain directory
|
||||||
|
noGit, err := cmd.Flags().GetBool("no-git")
|
||||||
|
if err != nil {
|
||||||
|
log.Fatal().Err(err)
|
||||||
|
}
|
||||||
|
|
||||||
|
// start the detector scan
|
||||||
|
if noGit {
|
||||||
|
findings, err = detector.DetectFiles(source)
|
||||||
|
if err != nil {
|
||||||
|
// don't exit on error, just log it
|
||||||
|
log.Error().Err(err)
|
||||||
|
}
|
||||||
|
|
||||||
|
} else {
|
||||||
|
logOpts, err := cmd.Flags().GetString("log-opts")
|
||||||
|
if err != nil {
|
||||||
|
log.Fatal().Err(err)
|
||||||
|
}
|
||||||
|
findings, err = detector.DetectGit(source, logOpts, detect.DetectType)
|
||||||
|
if err != nil {
|
||||||
|
// don't exit on error, just log it
|
||||||
|
log.Error().Err(err)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// log info about the scan
|
||||||
|
log.Info().Msgf("scan completed in %s", time.Since(start))
|
||||||
|
if len(findings) != 0 {
|
||||||
|
log.Warn().Msgf("leaks found: %d", len(findings))
|
||||||
|
} else {
|
||||||
|
log.Info().Msg("no leaks found")
|
||||||
|
}
|
||||||
|
|
||||||
|
// write report if desired
|
||||||
|
reportPath, _ := cmd.Flags().GetString("report-path")
|
||||||
|
ext, _ := cmd.Flags().GetString("report-format")
|
||||||
|
if reportPath != "" {
|
||||||
|
if err = report.Write(findings, cfg, ext, reportPath); err != nil {
|
||||||
|
log.Fatal().Err(err)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if len(findings) != 0 {
|
||||||
|
os.Exit(exitCode)
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,181 @@
|
|||||||
|
package main
|
||||||
|
|
||||||
|
import (
|
||||||
|
"os"
|
||||||
|
"text/template"
|
||||||
|
|
||||||
|
"github.com/rs/zerolog/log"
|
||||||
|
|
||||||
|
"github.com/zricethezav/gitleaks/v8/cmd/generate/config/rules"
|
||||||
|
"github.com/zricethezav/gitleaks/v8/config"
|
||||||
|
)
|
||||||
|
|
||||||
|
const (
|
||||||
|
templatePath = "rules/config.tmpl"
|
||||||
|
)
|
||||||
|
|
||||||
|
func main() {
|
||||||
|
configRules := []*config.Rule{}
|
||||||
|
configRules = append(configRules, rules.AdafruitAPIKey())
|
||||||
|
configRules = append(configRules, rules.AdobeClientID())
|
||||||
|
configRules = append(configRules, rules.AdobeClientSecret())
|
||||||
|
configRules = append(configRules, rules.AgeSecretKey())
|
||||||
|
configRules = append(configRules, rules.Airtable())
|
||||||
|
configRules = append(configRules, rules.AlgoliaApiKey())
|
||||||
|
configRules = append(configRules, rules.AlibabaAccessKey())
|
||||||
|
configRules = append(configRules, rules.AlibabaSecretKey())
|
||||||
|
configRules = append(configRules, rules.AsanaClientID())
|
||||||
|
configRules = append(configRules, rules.AsanaClientSecret())
|
||||||
|
configRules = append(configRules, rules.Atlassian())
|
||||||
|
configRules = append(configRules, rules.AWS())
|
||||||
|
configRules = append(configRules, rules.BitBucketClientID())
|
||||||
|
configRules = append(configRules, rules.BitBucketClientSecret())
|
||||||
|
configRules = append(configRules, rules.BittrexAccessKey())
|
||||||
|
configRules = append(configRules, rules.BittrexSecretKey())
|
||||||
|
configRules = append(configRules, rules.Beamer())
|
||||||
|
configRules = append(configRules, rules.CodecovAccessToken())
|
||||||
|
configRules = append(configRules, rules.CoinbaseAccessToken())
|
||||||
|
configRules = append(configRules, rules.Clojars())
|
||||||
|
configRules = append(configRules, rules.ConfluentAccessToken())
|
||||||
|
configRules = append(configRules, rules.ConfluentSecretKey())
|
||||||
|
configRules = append(configRules, rules.Contentful())
|
||||||
|
configRules = append(configRules, rules.Databricks())
|
||||||
|
configRules = append(configRules, rules.DatadogtokenAccessToken())
|
||||||
|
configRules = append(configRules, rules.DiscordAPIToken())
|
||||||
|
configRules = append(configRules, rules.DiscordClientID())
|
||||||
|
configRules = append(configRules, rules.DiscordClientSecret())
|
||||||
|
configRules = append(configRules, rules.Doppler())
|
||||||
|
configRules = append(configRules, rules.DropBoxAPISecret())
|
||||||
|
configRules = append(configRules, rules.DropBoxLongLivedAPIToken())
|
||||||
|
configRules = append(configRules, rules.DropBoxShortLivedAPIToken())
|
||||||
|
configRules = append(configRules, rules.DroneciAccessToken())
|
||||||
|
configRules = append(configRules, rules.Duffel())
|
||||||
|
configRules = append(configRules, rules.Dynatrace())
|
||||||
|
configRules = append(configRules, rules.EasyPost())
|
||||||
|
configRules = append(configRules, rules.EasyPostTestAPI())
|
||||||
|
configRules = append(configRules, rules.EtsyAccessToken())
|
||||||
|
configRules = append(configRules, rules.Facebook())
|
||||||
|
configRules = append(configRules, rules.FastlyAPIToken())
|
||||||
|
configRules = append(configRules, rules.FinicityClientSecret())
|
||||||
|
configRules = append(configRules, rules.FinicityAPIToken())
|
||||||
|
configRules = append(configRules, rules.FlickrAccessToken())
|
||||||
|
configRules = append(configRules, rules.FinnhubAccessToken())
|
||||||
|
configRules = append(configRules, rules.FlutterwavePublicKey())
|
||||||
|
configRules = append(configRules, rules.FlutterwaveSecretKey())
|
||||||
|
configRules = append(configRules, rules.FlutterwaveEncKey())
|
||||||
|
configRules = append(configRules, rules.FrameIO())
|
||||||
|
configRules = append(configRules, rules.FreshbooksAccessToken())
|
||||||
|
configRules = append(configRules, rules.GoCardless())
|
||||||
|
// TODO figure out what makes sense for GCP
|
||||||
|
// configRules = append(configRules, rules.GCPServiceAccount())
|
||||||
|
configRules = append(configRules, rules.GCPAPIKey())
|
||||||
|
configRules = append(configRules, rules.GitHubPat())
|
||||||
|
configRules = append(configRules, rules.GitHubOauth())
|
||||||
|
configRules = append(configRules, rules.GitHubApp())
|
||||||
|
configRules = append(configRules, rules.GitHubRefresh())
|
||||||
|
configRules = append(configRules, rules.Gitlab())
|
||||||
|
configRules = append(configRules, rules.GitterAccessToken())
|
||||||
|
configRules = append(configRules, rules.Hashicorp())
|
||||||
|
configRules = append(configRules, rules.Heroku())
|
||||||
|
configRules = append(configRules, rules.HubSpot())
|
||||||
|
configRules = append(configRules, rules.Intercom())
|
||||||
|
configRules = append(configRules, rules.JWT())
|
||||||
|
configRules = append(configRules, rules.KrakenAccessToken())
|
||||||
|
configRules = append(configRules, rules.KucoinAccessToken())
|
||||||
|
configRules = append(configRules, rules.KucoinSecretKey())
|
||||||
|
configRules = append(configRules, rules.LaunchDarklyAccessToken())
|
||||||
|
configRules = append(configRules, rules.LinearAPIToken())
|
||||||
|
configRules = append(configRules, rules.LinearClientSecret())
|
||||||
|
configRules = append(configRules, rules.LinkedinClientID())
|
||||||
|
configRules = append(configRules, rules.LinkedinClientSecret())
|
||||||
|
configRules = append(configRules, rules.LobAPIToken())
|
||||||
|
configRules = append(configRules, rules.LobPubAPIToken())
|
||||||
|
configRules = append(configRules, rules.MailChimp())
|
||||||
|
configRules = append(configRules, rules.MailGunPubAPIToken())
|
||||||
|
configRules = append(configRules, rules.MailGunPrivateAPIToken())
|
||||||
|
configRules = append(configRules, rules.MailGunSigningKey())
|
||||||
|
configRules = append(configRules, rules.MapBox())
|
||||||
|
configRules = append(configRules, rules.MattermostAccessToken())
|
||||||
|
configRules = append(configRules, rules.MessageBirdAPIToken())
|
||||||
|
configRules = append(configRules, rules.MessageBirdClientID())
|
||||||
|
configRules = append(configRules, rules.NetlifyAccessToken())
|
||||||
|
configRules = append(configRules, rules.NewRelicUserID())
|
||||||
|
configRules = append(configRules, rules.NewRelicUserKey())
|
||||||
|
configRules = append(configRules, rules.NewRelicBrowserAPIKey())
|
||||||
|
configRules = append(configRules, rules.NPM())
|
||||||
|
configRules = append(configRules, rules.NytimesAccessToken())
|
||||||
|
configRules = append(configRules, rules.OktaAccessToken())
|
||||||
|
configRules = append(configRules, rules.PlaidAccessID())
|
||||||
|
configRules = append(configRules, rules.PlaidSecretKey())
|
||||||
|
configRules = append(configRules, rules.PlaidAccessToken())
|
||||||
|
configRules = append(configRules, rules.PlanetScalePassword())
|
||||||
|
configRules = append(configRules, rules.PlanetScaleAPIToken())
|
||||||
|
configRules = append(configRules, rules.PlanetScaleOAuthToken())
|
||||||
|
configRules = append(configRules, rules.PostManAPI())
|
||||||
|
configRules = append(configRules, rules.PrivateKey())
|
||||||
|
configRules = append(configRules, rules.PulumiAPIToken())
|
||||||
|
configRules = append(configRules, rules.PyPiUploadToken())
|
||||||
|
configRules = append(configRules, rules.RubyGemsAPIToken())
|
||||||
|
configRules = append(configRules, rules.RapidAPIAccessToken())
|
||||||
|
configRules = append(configRules, rules.SendbirdAccessID())
|
||||||
|
configRules = append(configRules, rules.SendbirdAccessToken())
|
||||||
|
configRules = append(configRules, rules.SendGridAPIToken())
|
||||||
|
configRules = append(configRules, rules.SendInBlueAPIToken())
|
||||||
|
configRules = append(configRules, rules.SentryAccessToken())
|
||||||
|
configRules = append(configRules, rules.ShippoAPIToken())
|
||||||
|
configRules = append(configRules, rules.ShopifyAccessToken())
|
||||||
|
configRules = append(configRules, rules.ShopifyCustomAccessToken())
|
||||||
|
configRules = append(configRules, rules.ShopifyPrivateAppAccessToken())
|
||||||
|
configRules = append(configRules, rules.ShopifySharedSecret())
|
||||||
|
configRules = append(configRules, rules.SidekiqSecret())
|
||||||
|
configRules = append(configRules, rules.SidekiqSensitiveUrl())
|
||||||
|
configRules = append(configRules, rules.SlackAccessToken())
|
||||||
|
configRules = append(configRules, rules.SlackWebHook())
|
||||||
|
configRules = append(configRules, rules.StripeAccessToken())
|
||||||
|
configRules = append(configRules, rules.SquareAccessToken())
|
||||||
|
configRules = append(configRules, rules.SquareSpaceAccessToken())
|
||||||
|
configRules = append(configRules, rules.SumoLogicAccessID())
|
||||||
|
configRules = append(configRules, rules.SumoLogicAccessToken())
|
||||||
|
configRules = append(configRules, rules.TravisCIAccessToken())
|
||||||
|
configRules = append(configRules, rules.Twilio())
|
||||||
|
configRules = append(configRules, rules.TwitchAPIToken())
|
||||||
|
configRules = append(configRules, rules.TwitterAPIKey())
|
||||||
|
configRules = append(configRules, rules.TwitterAPISecret())
|
||||||
|
configRules = append(configRules, rules.TwitterAccessToken())
|
||||||
|
configRules = append(configRules, rules.TwitterAccessSecret())
|
||||||
|
configRules = append(configRules, rules.TwitterBearerToken())
|
||||||
|
configRules = append(configRules, rules.Typeform())
|
||||||
|
configRules = append(configRules, rules.VaultBatchToken())
|
||||||
|
configRules = append(configRules, rules.VaultServiceToken())
|
||||||
|
configRules = append(configRules, rules.YandexAPIKey())
|
||||||
|
configRules = append(configRules, rules.YandexAWSAccessToken())
|
||||||
|
configRules = append(configRules, rules.YandexAccessToken())
|
||||||
|
configRules = append(configRules, rules.ZendeskSecretKey())
|
||||||
|
configRules = append(configRules, rules.GenericCredential())
|
||||||
|
|
||||||
|
// ensure rules have unique ids
|
||||||
|
ruleLookUp := make(map[string]config.Rule)
|
||||||
|
for _, rule := range configRules {
|
||||||
|
// check if rule is in ruleLookUp
|
||||||
|
if _, ok := ruleLookUp[rule.RuleID]; ok {
|
||||||
|
log.Fatal().Msgf("rule id %s is not unique", rule.RuleID)
|
||||||
|
}
|
||||||
|
// TODO: eventually change all the signatures to get ride of this
|
||||||
|
// nasty dereferencing.
|
||||||
|
ruleLookUp[rule.RuleID] = *rule
|
||||||
|
}
|
||||||
|
config := config.Config{
|
||||||
|
Rules: ruleLookUp,
|
||||||
|
}
|
||||||
|
tmpl, err := template.ParseFiles(templatePath)
|
||||||
|
if err != nil {
|
||||||
|
log.Fatal().Err(err).Msg("Failed to parse template")
|
||||||
|
}
|
||||||
|
|
||||||
|
f, err := os.Create("../../../config/gitleaks.toml")
|
||||||
|
if err != nil {
|
||||||
|
log.Fatal().Err(err).Msg("Failed to create rules.toml")
|
||||||
|
}
|
||||||
|
tmpl.Execute(f, config)
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,23 @@
|
|||||||
|
package rules
|
||||||
|
|
||||||
|
import (
|
||||||
|
"github.com/zricethezav/gitleaks/v8/cmd/generate/secrets"
|
||||||
|
"github.com/zricethezav/gitleaks/v8/config"
|
||||||
|
)
|
||||||
|
|
||||||
|
func AdafruitAPIKey() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
Description: "Adafruit API Key",
|
||||||
|
RuleID: "adafruit-api-key",
|
||||||
|
Regex: generateSemiGenericRegex([]string{"adafruit"}, alphaNumericExtendedShort("32")),
|
||||||
|
SecretGroup: 1,
|
||||||
|
Keywords: []string{"adafruit"},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("adafruit", secrets.NewSecret(alphaNumericExtendedShort("32"))),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
@@ -0,0 +1,39 @@
|
|||||||
|
package rules
|
||||||
|
|
||||||
|
import (
|
||||||
|
"github.com/zricethezav/gitleaks/v8/cmd/generate/secrets"
|
||||||
|
"github.com/zricethezav/gitleaks/v8/config"
|
||||||
|
)
|
||||||
|
|
||||||
|
func AdobeClientID() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
Description: "Adobe Client ID (OAuth Web)",
|
||||||
|
RuleID: "adobe-client-id",
|
||||||
|
Regex: generateSemiGenericRegex([]string{"adobe"}, hex("32")),
|
||||||
|
SecretGroup: 1,
|
||||||
|
Keywords: []string{"adobe"},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("adobe", secrets.NewSecret(hex("32"))),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
|
|
||||||
|
func AdobeClientSecret() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
Description: "Adobe Client Secret",
|
||||||
|
RuleID: "adobe-client-secret",
|
||||||
|
Regex: generateUniqueTokenRegex(`(p8e-)(?i)[a-z0-9]{32}`),
|
||||||
|
Keywords: []string{"p8e-"},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
"adobeClient := \"p8e-" + secrets.NewSecret(hex("32")) + "\"",
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
@@ -0,0 +1,23 @@
|
|||||||
|
package rules
|
||||||
|
|
||||||
|
import (
|
||||||
|
"regexp"
|
||||||
|
|
||||||
|
"github.com/zricethezav/gitleaks/v8/config"
|
||||||
|
)
|
||||||
|
|
||||||
|
func AgeSecretKey() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
Description: "Age secret key",
|
||||||
|
RuleID: "age secret key",
|
||||||
|
Regex: regexp.MustCompile(`AGE-SECRET-KEY-1[QPZRY9X8GF2TVDW0S3JN54KHCE6MUA7L]{58}`),
|
||||||
|
Keywords: []string{"AGE-SECRET-KEY-1"},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
`apiKey := "AGE-SECRET-KEY-1QQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQ`, // gitleaks:allow
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
@@ -0,0 +1,23 @@
|
|||||||
|
package rules
|
||||||
|
|
||||||
|
import (
|
||||||
|
"github.com/zricethezav/gitleaks/v8/cmd/generate/secrets"
|
||||||
|
"github.com/zricethezav/gitleaks/v8/config"
|
||||||
|
)
|
||||||
|
|
||||||
|
func Airtable() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
Description: "Airtable API Key",
|
||||||
|
RuleID: "airtable-api-key",
|
||||||
|
Regex: generateSemiGenericRegex([]string{"airtable"}, alphaNumeric("17")),
|
||||||
|
SecretGroup: 1,
|
||||||
|
Keywords: []string{"airtable"},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("airtable", secrets.NewSecret(alphaNumeric("17"))),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
@@ -0,0 +1,22 @@
|
|||||||
|
package rules
|
||||||
|
|
||||||
|
import (
|
||||||
|
"github.com/zricethezav/gitleaks/v8/cmd/generate/secrets"
|
||||||
|
"github.com/zricethezav/gitleaks/v8/config"
|
||||||
|
)
|
||||||
|
|
||||||
|
func AlgoliaApiKey() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
Description: "Algolia API Key",
|
||||||
|
RuleID: "algolia-api-key",
|
||||||
|
Regex: generateSemiGenericRegex([]string{"algolia"}, `[a-z0-9]{32}`),
|
||||||
|
Keywords: []string{"algolia"},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
"algolia_key := " + secrets.NewSecret(hex("32")),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
@@ -0,0 +1,41 @@
|
|||||||
|
package rules
|
||||||
|
|
||||||
|
import (
|
||||||
|
"github.com/zricethezav/gitleaks/v8/cmd/generate/secrets"
|
||||||
|
"github.com/zricethezav/gitleaks/v8/config"
|
||||||
|
)
|
||||||
|
|
||||||
|
func AlibabaAccessKey() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
Description: "Alibaba AccessKey ID",
|
||||||
|
RuleID: "alibaba-access-key-id",
|
||||||
|
Regex: generateUniqueTokenRegex(`(LTAI)(?i)[a-z0-9]{20}`),
|
||||||
|
Keywords: []string{"LTAI"},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
"alibabaKey := \"LTAI" + secrets.NewSecret(hex("20")) + "\"",
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
|
|
||||||
|
// TODO
|
||||||
|
func AlibabaSecretKey() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
Description: "Alibaba Secret Key",
|
||||||
|
RuleID: "alibaba-secret-key",
|
||||||
|
Regex: generateSemiGenericRegex([]string{"alibaba"},
|
||||||
|
alphaNumeric("30")),
|
||||||
|
SecretGroup: 1,
|
||||||
|
Keywords: []string{"alibaba"},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("alibaba", secrets.NewSecret(alphaNumeric("30"))),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
@@ -0,0 +1,40 @@
|
|||||||
|
package rules
|
||||||
|
|
||||||
|
import (
|
||||||
|
"github.com/zricethezav/gitleaks/v8/cmd/generate/secrets"
|
||||||
|
"github.com/zricethezav/gitleaks/v8/config"
|
||||||
|
)
|
||||||
|
|
||||||
|
func AsanaClientID() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
Description: "Asana Client ID",
|
||||||
|
RuleID: "asana-client-id",
|
||||||
|
Regex: generateSemiGenericRegex([]string{"asana"}, numeric("16")),
|
||||||
|
SecretGroup: 1,
|
||||||
|
Keywords: []string{"asana"},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("asana", secrets.NewSecret(numeric("16"))),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
|
|
||||||
|
func AsanaClientSecret() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
Description: "Asana Client Secret",
|
||||||
|
RuleID: "asana-client-secret",
|
||||||
|
Regex: generateSemiGenericRegex([]string{"asana"}, alphaNumeric("32")),
|
||||||
|
SecretGroup: 1,
|
||||||
|
Keywords: []string{"asana"},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("asana", secrets.NewSecret(alphaNumeric("32"))),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
@@ -0,0 +1,25 @@
|
|||||||
|
package rules
|
||||||
|
|
||||||
|
import (
|
||||||
|
"github.com/zricethezav/gitleaks/v8/cmd/generate/secrets"
|
||||||
|
"github.com/zricethezav/gitleaks/v8/config"
|
||||||
|
)
|
||||||
|
|
||||||
|
func Atlassian() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
Description: "Atlassian API token",
|
||||||
|
RuleID: "atlassian-api-token",
|
||||||
|
Regex: generateSemiGenericRegex([]string{
|
||||||
|
"atlassian", "confluence", "jira"}, alphaNumeric("24")),
|
||||||
|
SecretGroup: 1,
|
||||||
|
Keywords: []string{"atlassian", "confluence", "jira"},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("atlassian", secrets.NewSecret(alphaNumeric("24"))),
|
||||||
|
generateSampleSecret("confluence", secrets.NewSecret(alphaNumeric("24"))),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
@@ -0,0 +1,31 @@
|
|||||||
|
package rules
|
||||||
|
|
||||||
|
import (
|
||||||
|
"regexp"
|
||||||
|
|
||||||
|
"github.com/zricethezav/gitleaks/v8/config"
|
||||||
|
)
|
||||||
|
|
||||||
|
func AWS() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
Description: "AWS",
|
||||||
|
RuleID: "aws-access-token",
|
||||||
|
Regex: regexp.MustCompile(
|
||||||
|
"(A3T[A-Z0-9]|AKIA|AGPA|AIDA|AROA|AIPA|ANPA|ANVA|ASIA)[A-Z0-9]{16}"),
|
||||||
|
Keywords: []string{
|
||||||
|
"AKIA",
|
||||||
|
"AGPA",
|
||||||
|
"AIDA",
|
||||||
|
"AROA",
|
||||||
|
"AIPA",
|
||||||
|
"ANPA",
|
||||||
|
"ANVA",
|
||||||
|
"ASIA",
|
||||||
|
},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{generateSampleSecret("AWS", "AKIALALEMEL33243OLIB")} // gitleaks:allow
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
@@ -0,0 +1,24 @@
|
|||||||
|
package rules
|
||||||
|
|
||||||
|
import (
|
||||||
|
"github.com/zricethezav/gitleaks/v8/cmd/generate/secrets"
|
||||||
|
"github.com/zricethezav/gitleaks/v8/config"
|
||||||
|
)
|
||||||
|
|
||||||
|
func Beamer() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
Description: "Beamer API token",
|
||||||
|
RuleID: "beamer-api-token",
|
||||||
|
SecretGroup: 1,
|
||||||
|
Regex: generateSemiGenericRegex([]string{"beamer"},
|
||||||
|
`b_[a-z0-9=_\-]{44}`),
|
||||||
|
Keywords: []string{"beamer"},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("beamer", "b_"+secrets.NewSecret(alphaNumericExtended("44"))),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
@@ -0,0 +1,40 @@
|
|||||||
|
package rules
|
||||||
|
|
||||||
|
import (
|
||||||
|
"github.com/zricethezav/gitleaks/v8/cmd/generate/secrets"
|
||||||
|
"github.com/zricethezav/gitleaks/v8/config"
|
||||||
|
)
|
||||||
|
|
||||||
|
func BitBucketClientID() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
Description: "Bitbucket Client ID",
|
||||||
|
RuleID: "bitbucket-client-id",
|
||||||
|
Regex: generateSemiGenericRegex([]string{"bitbucket"}, alphaNumeric("32")),
|
||||||
|
SecretGroup: 1,
|
||||||
|
Keywords: []string{"bitbucket"},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("bitbucket", secrets.NewSecret(alphaNumeric("32"))),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
|
|
||||||
|
func BitBucketClientSecret() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
Description: "Bitbucket Client Secret",
|
||||||
|
RuleID: "bitbucket-client-secret",
|
||||||
|
Regex: generateSemiGenericRegex([]string{"bitbucket"}, alphaNumericExtended("64")),
|
||||||
|
SecretGroup: 1,
|
||||||
|
Keywords: []string{"bitbucket"},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("bitbucket", secrets.NewSecret(alphaNumeric("64"))),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
@@ -0,0 +1,40 @@
|
|||||||
|
package rules
|
||||||
|
|
||||||
|
import (
|
||||||
|
"github.com/zricethezav/gitleaks/v8/cmd/generate/secrets"
|
||||||
|
"github.com/zricethezav/gitleaks/v8/config"
|
||||||
|
)
|
||||||
|
|
||||||
|
func BittrexAccessKey() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
Description: "Bittrex Access Key",
|
||||||
|
RuleID: "bittrex-access-key",
|
||||||
|
Regex: generateSemiGenericRegex([]string{"bittrex"}, alphaNumeric("32")),
|
||||||
|
SecretGroup: 1,
|
||||||
|
Keywords: []string{"bittrex"},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("bittrex", secrets.NewSecret(alphaNumeric("32"))),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
|
|
||||||
|
func BittrexSecretKey() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
Description: "Bittrex Secret Key",
|
||||||
|
RuleID: "bittrex-secret-key",
|
||||||
|
Regex: generateSemiGenericRegex([]string{"bittrex"}, alphaNumeric("32")),
|
||||||
|
SecretGroup: 1,
|
||||||
|
Keywords: []string{"bittrex"},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("bittrex", secrets.NewSecret(alphaNumeric("32"))),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
@@ -0,0 +1,24 @@
|
|||||||
|
package rules
|
||||||
|
|
||||||
|
import (
|
||||||
|
"regexp"
|
||||||
|
|
||||||
|
"github.com/zricethezav/gitleaks/v8/cmd/generate/secrets"
|
||||||
|
"github.com/zricethezav/gitleaks/v8/config"
|
||||||
|
)
|
||||||
|
|
||||||
|
func Clojars() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
Description: "Clojars API token",
|
||||||
|
RuleID: "clojars-api-token",
|
||||||
|
Regex: regexp.MustCompile(`(?i)(CLOJARS_)[a-z0-9]{60}`),
|
||||||
|
Keywords: []string{"clojars"},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("clojars", "CLOJARS_"+secrets.NewSecret(alphaNumeric("60"))),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
@@ -0,0 +1,25 @@
|
|||||||
|
package rules
|
||||||
|
|
||||||
|
import (
|
||||||
|
"github.com/zricethezav/gitleaks/v8/cmd/generate/secrets"
|
||||||
|
"github.com/zricethezav/gitleaks/v8/config"
|
||||||
|
)
|
||||||
|
|
||||||
|
func CodecovAccessToken() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
RuleID: "codecov-access-token",
|
||||||
|
Description: "Codecov Access Token",
|
||||||
|
Regex: generateSemiGenericRegex([]string{"codecov"}, alphaNumeric("32")),
|
||||||
|
SecretGroup: 1,
|
||||||
|
Keywords: []string{
|
||||||
|
"codecov",
|
||||||
|
},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("codecov", secrets.NewSecret(alphaNumeric("32"))),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
@@ -0,0 +1,27 @@
|
|||||||
|
package rules
|
||||||
|
|
||||||
|
import (
|
||||||
|
"github.com/zricethezav/gitleaks/v8/cmd/generate/secrets"
|
||||||
|
"github.com/zricethezav/gitleaks/v8/config"
|
||||||
|
)
|
||||||
|
|
||||||
|
func CoinbaseAccessToken() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
RuleID: "coinbase-access-token",
|
||||||
|
Description: "Coinbase Access Token",
|
||||||
|
Regex: generateSemiGenericRegex([]string{"coinbase"},
|
||||||
|
alphaNumericExtendedShort("64")),
|
||||||
|
SecretGroup: 1,
|
||||||
|
Keywords: []string{
|
||||||
|
"coinbase",
|
||||||
|
},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("coinbase",
|
||||||
|
secrets.NewSecret(alphaNumericExtendedShort("64"))),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
@@ -0,0 +1,60 @@
|
|||||||
|
# This file has been auto-generated. Do not edit manually.
|
||||||
|
# If you would like to contribute new rules, please use
|
||||||
|
# cmd/generate/config/main.go and follow the contributing guidelines
|
||||||
|
# at https://github.com/zricethezav/gitleaks/blob/master/CONTRIBUTING.md
|
||||||
|
|
||||||
|
# This is the default gitleaks configuration file.
|
||||||
|
# Rules and allowlists are defined within this file.
|
||||||
|
# Rules instruct gitleaks on what should be considered a secret.
|
||||||
|
# Allowlists instruct gitleaks on what is allowed, i.e. not a secret.
|
||||||
|
|
||||||
|
title = "gitleaks config"
|
||||||
|
|
||||||
|
[allowlist]
|
||||||
|
description = "global allow lists"
|
||||||
|
paths = [
|
||||||
|
'''gitleaks.toml''',
|
||||||
|
'''(.*?)(jpg|gif|doc|docx|zip|xls|pdf|bin|svg|socket)$''',
|
||||||
|
'''(go.mod|go.sum)$''',
|
||||||
|
'''node_modules''',
|
||||||
|
'''vendor''',
|
||||||
|
]
|
||||||
|
|
||||||
|
{{ range $i, $rule := .Rules }}[[rules]]
|
||||||
|
{{ if and $rule.SecretGroup $rule.Entropy $rule.Allowlist.StopWords }}description = "{{$rule.Description}}"
|
||||||
|
id = "{{$rule.RuleID}}"
|
||||||
|
regex = '''{{$rule.Regex}}'''
|
||||||
|
secretGroup = {{ $rule.SecretGroup }}
|
||||||
|
entropy = {{ $rule.Entropy}}
|
||||||
|
keywords = [
|
||||||
|
{{ range $j, $keyword := $rule.Keywords }}"{{$keyword}}",{{end}}
|
||||||
|
]
|
||||||
|
[rules.allowlist]
|
||||||
|
stopwords= [{{ range $j, $stopword := $rule.Allowlist.StopWords }}
|
||||||
|
"{{$stopword}}",{{end}}
|
||||||
|
]
|
||||||
|
{{ else if and $rule.SecretGroup $rule.Entropy }}description = "{{$rule.Description}}"
|
||||||
|
id = "{{$rule.RuleID}}"
|
||||||
|
regex = '''{{$rule.Regex}}'''
|
||||||
|
secretGroup = {{ $rule.SecretGroup }}
|
||||||
|
entropy = {{ $rule.Entropy}}
|
||||||
|
keywords = [
|
||||||
|
{{ range $j, $keyword := $rule.Keywords }}"{{$keyword}}",{{end}}
|
||||||
|
]
|
||||||
|
|
||||||
|
{{ else if $rule.SecretGroup }}description = "{{$rule.Description}}"
|
||||||
|
id = "{{$rule.RuleID}}"
|
||||||
|
regex = '''{{$rule.Regex}}'''
|
||||||
|
secretGroup = {{ $rule.SecretGroup }}
|
||||||
|
keywords = [
|
||||||
|
{{ range $j, $keyword := $rule.Keywords }}"{{$keyword}}",{{end}}
|
||||||
|
]
|
||||||
|
|
||||||
|
{{ else }}description = "{{$rule.Description}}"
|
||||||
|
id = "{{$rule.RuleID}}"
|
||||||
|
regex = '''{{$rule.Regex}}'''
|
||||||
|
keywords = [
|
||||||
|
{{ range $j, $keyword := $rule.Keywords }}"{{$keyword}}",{{end}}
|
||||||
|
]
|
||||||
|
|
||||||
|
{{end}}{{end}}
|
||||||
@@ -0,0 +1,44 @@
|
|||||||
|
package rules
|
||||||
|
|
||||||
|
import (
|
||||||
|
"github.com/zricethezav/gitleaks/v8/cmd/generate/secrets"
|
||||||
|
"github.com/zricethezav/gitleaks/v8/config"
|
||||||
|
)
|
||||||
|
|
||||||
|
func ConfluentSecretKey() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
RuleID: "confluent-secret-key",
|
||||||
|
Description: "Confluent Secret Key",
|
||||||
|
Regex: generateSemiGenericRegex([]string{"confluent"}, alphaNumeric("64")),
|
||||||
|
SecretGroup: 1,
|
||||||
|
Keywords: []string{
|
||||||
|
"confluent",
|
||||||
|
},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("confluent", secrets.NewSecret(alphaNumeric("64"))),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
|
|
||||||
|
func ConfluentAccessToken() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
RuleID: "confluent-access-token",
|
||||||
|
Description: "Confluent Access Token",
|
||||||
|
Regex: generateSemiGenericRegex([]string{"confluent"}, alphaNumeric("16")),
|
||||||
|
SecretGroup: 1,
|
||||||
|
Keywords: []string{
|
||||||
|
"confluent",
|
||||||
|
},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("confluent", secrets.NewSecret(alphaNumeric("16"))),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
@@ -0,0 +1,24 @@
|
|||||||
|
package rules
|
||||||
|
|
||||||
|
import (
|
||||||
|
"github.com/zricethezav/gitleaks/v8/cmd/generate/secrets"
|
||||||
|
"github.com/zricethezav/gitleaks/v8/config"
|
||||||
|
)
|
||||||
|
|
||||||
|
func Contentful() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
Description: "Contentful delivery API token",
|
||||||
|
RuleID: "contentful-delivery-api-token",
|
||||||
|
Regex: generateSemiGenericRegex([]string{"contentful"},
|
||||||
|
alphaNumericExtended("43")),
|
||||||
|
SecretGroup: 1,
|
||||||
|
Keywords: []string{"contentful"},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("contentful", secrets.NewSecret(alphaNumeric("43"))),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
@@ -0,0 +1,22 @@
|
|||||||
|
package rules
|
||||||
|
|
||||||
|
import (
|
||||||
|
"github.com/zricethezav/gitleaks/v8/cmd/generate/secrets"
|
||||||
|
"github.com/zricethezav/gitleaks/v8/config"
|
||||||
|
)
|
||||||
|
|
||||||
|
func Databricks() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
Description: "Databricks API token",
|
||||||
|
RuleID: "databricks-api-token",
|
||||||
|
Regex: generateUniqueTokenRegex(`dapi[a-h0-9]{32}`),
|
||||||
|
Keywords: []string{"dapi"},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("databricks", "dapi"+secrets.NewSecret(hex("32"))),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
@@ -0,0 +1,26 @@
|
|||||||
|
package rules
|
||||||
|
|
||||||
|
import (
|
||||||
|
"github.com/zricethezav/gitleaks/v8/cmd/generate/secrets"
|
||||||
|
"github.com/zricethezav/gitleaks/v8/config"
|
||||||
|
)
|
||||||
|
|
||||||
|
func DatadogtokenAccessToken() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
RuleID: "datadog-access-token",
|
||||||
|
Description: "Datadog Access Token",
|
||||||
|
Regex: generateSemiGenericRegex([]string{"datadog"},
|
||||||
|
alphaNumeric("40")),
|
||||||
|
SecretGroup: 1,
|
||||||
|
Keywords: []string{
|
||||||
|
"datadog",
|
||||||
|
},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("datadog", secrets.NewSecret(alphaNumeric("40"))),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
@@ -0,0 +1,57 @@
|
|||||||
|
package rules
|
||||||
|
|
||||||
|
import (
|
||||||
|
"github.com/zricethezav/gitleaks/v8/cmd/generate/secrets"
|
||||||
|
"github.com/zricethezav/gitleaks/v8/config"
|
||||||
|
)
|
||||||
|
|
||||||
|
func DiscordAPIToken() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
Description: "Discord API key",
|
||||||
|
RuleID: "discord-api-token",
|
||||||
|
Regex: generateSemiGenericRegex([]string{"discord"}, hex("64")),
|
||||||
|
SecretGroup: 1,
|
||||||
|
Keywords: []string{"discord"},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("discord", secrets.NewSecret(hex("64"))),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
|
|
||||||
|
func DiscordClientID() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
Description: "Discord client ID",
|
||||||
|
RuleID: "discord-client-id",
|
||||||
|
Regex: generateSemiGenericRegex([]string{"discord"}, numeric("18")),
|
||||||
|
SecretGroup: 1,
|
||||||
|
Keywords: []string{"discord"},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("discord", secrets.NewSecret(numeric("18"))),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
|
|
||||||
|
func DiscordClientSecret() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
Description: "Discord client secret",
|
||||||
|
RuleID: "discord-client-secret",
|
||||||
|
Regex: generateSemiGenericRegex([]string{"discord"}, alphaNumericExtended("32")),
|
||||||
|
SecretGroup: 1,
|
||||||
|
Keywords: []string{"discord"},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("discord", secrets.NewSecret(numeric("32"))),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
@@ -0,0 +1,27 @@
|
|||||||
|
package rules
|
||||||
|
|
||||||
|
import (
|
||||||
|
"regexp"
|
||||||
|
|
||||||
|
"github.com/zricethezav/gitleaks/v8/cmd/generate/secrets"
|
||||||
|
"github.com/zricethezav/gitleaks/v8/config"
|
||||||
|
)
|
||||||
|
|
||||||
|
func Doppler() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
Description: "Doppler API token",
|
||||||
|
RuleID: "doppler-api-token",
|
||||||
|
Regex: regexp.MustCompile(`(dp\.pt\.)(?i)[a-z0-9]{43}`),
|
||||||
|
Keywords: []string{"doppler"},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("doppler", "dp.pt."+secrets.NewSecret(alphaNumeric("43"))),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
|
|
||||||
|
// TODO add additional doppler formats:
|
||||||
|
// https://docs.doppler.com/reference/auth-token-formats
|
||||||
@@ -0,0 +1,25 @@
|
|||||||
|
package rules
|
||||||
|
|
||||||
|
import (
|
||||||
|
"github.com/zricethezav/gitleaks/v8/cmd/generate/secrets"
|
||||||
|
"github.com/zricethezav/gitleaks/v8/config"
|
||||||
|
)
|
||||||
|
|
||||||
|
func DroneciAccessToken() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
RuleID: "droneci-access-token",
|
||||||
|
Description: "Droneci Access Token",
|
||||||
|
Regex: generateSemiGenericRegex([]string{"droneci"}, alphaNumeric("32")),
|
||||||
|
SecretGroup: 1,
|
||||||
|
Keywords: []string{
|
||||||
|
"droneci",
|
||||||
|
},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("droneci", secrets.NewSecret(alphaNumeric("32"))),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
@@ -0,0 +1,49 @@
|
|||||||
|
package rules
|
||||||
|
|
||||||
|
import (
|
||||||
|
"github.com/zricethezav/gitleaks/v8/cmd/generate/secrets"
|
||||||
|
"github.com/zricethezav/gitleaks/v8/config"
|
||||||
|
)
|
||||||
|
|
||||||
|
func DropBoxAPISecret() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
Description: "Dropbox API secret",
|
||||||
|
RuleID: "dropbox-api-token",
|
||||||
|
Regex: generateSemiGenericRegex([]string{"dropbox"}, alphaNumeric("15")),
|
||||||
|
SecretGroup: 1,
|
||||||
|
Keywords: []string{"dropbox"},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("dropbox", secrets.NewSecret(alphaNumeric("15"))),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
|
|
||||||
|
func DropBoxShortLivedAPIToken() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
RuleID: "dropbox-short-lived-api-token",
|
||||||
|
Description: "Dropbox short lived API token",
|
||||||
|
Regex: generateSemiGenericRegex([]string{"dropbox"}, `sl\.[a-z0-9\-=_]{135}`),
|
||||||
|
Keywords: []string{"dropbox"},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate TODO
|
||||||
|
return &r
|
||||||
|
}
|
||||||
|
|
||||||
|
func DropBoxLongLivedAPIToken() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
RuleID: "dropbox-long-lived-api-token",
|
||||||
|
Description: "Dropbox long lived API token",
|
||||||
|
Regex: generateSemiGenericRegex([]string{"dropbox"}, `[a-z0-9]{11}(AAAAAAAAAA)[a-z0-9\-_=]{43}`),
|
||||||
|
Keywords: []string{"dropbox"},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate TODO
|
||||||
|
return &r
|
||||||
|
}
|
||||||
@@ -0,0 +1,24 @@
|
|||||||
|
package rules
|
||||||
|
|
||||||
|
import (
|
||||||
|
"regexp"
|
||||||
|
|
||||||
|
"github.com/zricethezav/gitleaks/v8/cmd/generate/secrets"
|
||||||
|
"github.com/zricethezav/gitleaks/v8/config"
|
||||||
|
)
|
||||||
|
|
||||||
|
func Duffel() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
RuleID: "duffel-api-token",
|
||||||
|
Description: "Duffel API token",
|
||||||
|
Regex: regexp.MustCompile(`duffel_(test|live)_(?i)[a-z0-9_\-=]{43}`),
|
||||||
|
Keywords: []string{"duffel"},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("duffel", "duffel_test_"+secrets.NewSecret(alphaNumericExtended("43"))),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
@@ -0,0 +1,24 @@
|
|||||||
|
package rules
|
||||||
|
|
||||||
|
import (
|
||||||
|
"regexp"
|
||||||
|
|
||||||
|
"github.com/zricethezav/gitleaks/v8/cmd/generate/secrets"
|
||||||
|
"github.com/zricethezav/gitleaks/v8/config"
|
||||||
|
)
|
||||||
|
|
||||||
|
func Dynatrace() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
Description: "Dynatrace API token",
|
||||||
|
RuleID: "dynatrace-api-token",
|
||||||
|
Regex: regexp.MustCompile(`dt0c01\.(?i)[a-z0-9]{24}\.[a-z0-9]{64}`),
|
||||||
|
Keywords: []string{"dynatrace"},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("dynatrace", "dt0c01."+secrets.NewSecret(alphaNumeric("24"))+"."+secrets.NewSecret(alphaNumeric("64"))),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
@@ -0,0 +1,40 @@
|
|||||||
|
package rules
|
||||||
|
|
||||||
|
import (
|
||||||
|
"regexp"
|
||||||
|
|
||||||
|
"github.com/zricethezav/gitleaks/v8/cmd/generate/secrets"
|
||||||
|
"github.com/zricethezav/gitleaks/v8/config"
|
||||||
|
)
|
||||||
|
|
||||||
|
func EasyPost() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
Description: "EasyPost API token",
|
||||||
|
RuleID: "easypost-api-token",
|
||||||
|
Regex: regexp.MustCompile(`EZAK(?i)[a-z0-9]{54}`),
|
||||||
|
Keywords: []string{"EZAK"},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("EZAK", "EZAK"+secrets.NewSecret(alphaNumeric("54"))),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
|
|
||||||
|
func EasyPostTestAPI() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
Description: "EasyPost test API token",
|
||||||
|
RuleID: "easypost-test-api-token",
|
||||||
|
Regex: regexp.MustCompile(`EZTK(?i)[a-z0-9]{54}`),
|
||||||
|
Keywords: []string{"EZTK"},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("EZTK", "EZTK"+secrets.NewSecret(alphaNumeric("54"))),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
@@ -0,0 +1,25 @@
|
|||||||
|
package rules
|
||||||
|
|
||||||
|
import (
|
||||||
|
"github.com/zricethezav/gitleaks/v8/cmd/generate/secrets"
|
||||||
|
"github.com/zricethezav/gitleaks/v8/config"
|
||||||
|
)
|
||||||
|
|
||||||
|
func EtsyAccessToken() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
RuleID: "etsy-access-token",
|
||||||
|
Description: "Etsy Access Token",
|
||||||
|
Regex: generateSemiGenericRegex([]string{"etsy"}, alphaNumeric("24")),
|
||||||
|
SecretGroup: 1,
|
||||||
|
Keywords: []string{
|
||||||
|
"etsy",
|
||||||
|
},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("etsy", secrets.NewSecret(alphaNumeric("24"))),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
@@ -0,0 +1,23 @@
|
|||||||
|
package rules
|
||||||
|
|
||||||
|
import (
|
||||||
|
"github.com/zricethezav/gitleaks/v8/cmd/generate/secrets"
|
||||||
|
"github.com/zricethezav/gitleaks/v8/config"
|
||||||
|
)
|
||||||
|
|
||||||
|
func Facebook() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
Description: "Facebook",
|
||||||
|
RuleID: "facebook",
|
||||||
|
Regex: generateSemiGenericRegex([]string{"facebook"}, hex("32")),
|
||||||
|
SecretGroup: 1,
|
||||||
|
Keywords: []string{"facebook"},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("facebook", secrets.NewSecret(hex("32"))),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
@@ -0,0 +1,23 @@
|
|||||||
|
package rules
|
||||||
|
|
||||||
|
import (
|
||||||
|
"github.com/zricethezav/gitleaks/v8/cmd/generate/secrets"
|
||||||
|
"github.com/zricethezav/gitleaks/v8/config"
|
||||||
|
)
|
||||||
|
|
||||||
|
func FastlyAPIToken() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
Description: "Fastly API key",
|
||||||
|
RuleID: "fastly-api-token",
|
||||||
|
Regex: generateSemiGenericRegex([]string{"fastly"}, alphaNumericExtended("32")),
|
||||||
|
SecretGroup: 1,
|
||||||
|
Keywords: []string{"fastly"},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("fastly", secrets.NewSecret(alphaNumericExtended("32"))),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
@@ -0,0 +1,40 @@
|
|||||||
|
package rules
|
||||||
|
|
||||||
|
import (
|
||||||
|
"github.com/zricethezav/gitleaks/v8/cmd/generate/secrets"
|
||||||
|
"github.com/zricethezav/gitleaks/v8/config"
|
||||||
|
)
|
||||||
|
|
||||||
|
func FinicityClientSecret() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
Description: "Finicity Client Secret",
|
||||||
|
RuleID: "finicity-client-secret",
|
||||||
|
Regex: generateSemiGenericRegex([]string{"finicity"}, alphaNumeric("20")),
|
||||||
|
SecretGroup: 1,
|
||||||
|
Keywords: []string{"finicity"},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("finicity", secrets.NewSecret(alphaNumeric("20"))),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
|
|
||||||
|
func FinicityAPIToken() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
Description: "Finicity API token",
|
||||||
|
RuleID: "finicity-api-token",
|
||||||
|
Regex: generateSemiGenericRegex([]string{"finicity"}, hex("32")),
|
||||||
|
SecretGroup: 1,
|
||||||
|
Keywords: []string{"finicity"},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("finicity", secrets.NewSecret(hex("32"))),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
@@ -0,0 +1,25 @@
|
|||||||
|
package rules
|
||||||
|
|
||||||
|
import (
|
||||||
|
"github.com/zricethezav/gitleaks/v8/cmd/generate/secrets"
|
||||||
|
"github.com/zricethezav/gitleaks/v8/config"
|
||||||
|
)
|
||||||
|
|
||||||
|
func FinnhubAccessToken() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
RuleID: "finnhub-access-token",
|
||||||
|
Description: "Finnhub Access Token",
|
||||||
|
Regex: generateSemiGenericRegex([]string{"finnhub"}, alphaNumeric("20")),
|
||||||
|
SecretGroup: 1,
|
||||||
|
Keywords: []string{
|
||||||
|
"finnhub",
|
||||||
|
},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("finnhub", secrets.NewSecret(alphaNumeric("20"))),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
@@ -0,0 +1,25 @@
|
|||||||
|
package rules
|
||||||
|
|
||||||
|
import (
|
||||||
|
"github.com/zricethezav/gitleaks/v8/cmd/generate/secrets"
|
||||||
|
"github.com/zricethezav/gitleaks/v8/config"
|
||||||
|
)
|
||||||
|
|
||||||
|
func FlickrAccessToken() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
RuleID: "flickr-access-token",
|
||||||
|
Description: "Flickr Access Token",
|
||||||
|
Regex: generateSemiGenericRegex([]string{"flickr"}, alphaNumeric("32")),
|
||||||
|
SecretGroup: 1,
|
||||||
|
Keywords: []string{
|
||||||
|
"flickr",
|
||||||
|
},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("flickr", secrets.NewSecret(alphaNumeric("32"))),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
@@ -0,0 +1,56 @@
|
|||||||
|
package rules
|
||||||
|
|
||||||
|
import (
|
||||||
|
"regexp"
|
||||||
|
|
||||||
|
"github.com/zricethezav/gitleaks/v8/cmd/generate/secrets"
|
||||||
|
"github.com/zricethezav/gitleaks/v8/config"
|
||||||
|
)
|
||||||
|
|
||||||
|
func FlutterwavePublicKey() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
Description: "Finicity Public Key",
|
||||||
|
RuleID: "flutterwave-public-key",
|
||||||
|
Regex: regexp.MustCompile(`FLWPUBK_TEST-(?i)[a-h0-9]{32}-X`),
|
||||||
|
Keywords: []string{"FLWPUBK_TEST"},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("flutterwavePubKey", "FLWPUBK_TEST-"+secrets.NewSecret(hex("32"))+"-X"),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
|
|
||||||
|
func FlutterwaveSecretKey() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
Description: "Flutterwave Secret Key",
|
||||||
|
RuleID: "flutterwave-secret-key",
|
||||||
|
Regex: regexp.MustCompile(`FLWSECK_TEST-(?i)[a-h0-9]{32}-X`),
|
||||||
|
Keywords: []string{"FLWSECK_TEST"},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("flutterwavePubKey", "FLWSECK_TEST-"+secrets.NewSecret(hex("32"))+"-X"),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
|
|
||||||
|
func FlutterwaveEncKey() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
Description: "Flutterwave Encryption Key",
|
||||||
|
RuleID: "flutterwave-encryption-key",
|
||||||
|
Regex: regexp.MustCompile(`FLWSECK_TEST-(?i)[a-h0-9]{12}`),
|
||||||
|
Keywords: []string{"FLWSECK_TEST"},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("flutterwavePubKey", "FLWSECK_TEST-"+secrets.NewSecret(hex("12"))),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
@@ -0,0 +1,24 @@
|
|||||||
|
package rules
|
||||||
|
|
||||||
|
import (
|
||||||
|
"regexp"
|
||||||
|
|
||||||
|
"github.com/zricethezav/gitleaks/v8/cmd/generate/secrets"
|
||||||
|
"github.com/zricethezav/gitleaks/v8/config"
|
||||||
|
)
|
||||||
|
|
||||||
|
func FrameIO() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
Description: "Frame.io API token",
|
||||||
|
RuleID: "frameio-api-token",
|
||||||
|
Regex: regexp.MustCompile(`fio-u-(?i)[a-z0-9\-_=]{64}`),
|
||||||
|
Keywords: []string{"fio-u-"},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("frameio", "fio-u-"+secrets.NewSecret(alphaNumericExtended("64"))),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
@@ -0,0 +1,25 @@
|
|||||||
|
package rules
|
||||||
|
|
||||||
|
import (
|
||||||
|
"github.com/zricethezav/gitleaks/v8/cmd/generate/secrets"
|
||||||
|
"github.com/zricethezav/gitleaks/v8/config"
|
||||||
|
)
|
||||||
|
|
||||||
|
func FreshbooksAccessToken() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
RuleID: "freshbooks-access-token",
|
||||||
|
Description: "Freshbooks Access Token",
|
||||||
|
Regex: generateSemiGenericRegex([]string{"freshbooks"}, alphaNumeric("64")),
|
||||||
|
SecretGroup: 1,
|
||||||
|
Keywords: []string{
|
||||||
|
"freshbooks",
|
||||||
|
},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("freshbooks", secrets.NewSecret(alphaNumeric("64"))),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
@@ -0,0 +1,44 @@
|
|||||||
|
package rules
|
||||||
|
|
||||||
|
import (
|
||||||
|
"regexp"
|
||||||
|
|
||||||
|
"github.com/zricethezav/gitleaks/v8/cmd/generate/secrets"
|
||||||
|
"github.com/zricethezav/gitleaks/v8/config"
|
||||||
|
)
|
||||||
|
|
||||||
|
// TODO this one could probably use some work
|
||||||
|
func GCPServiceAccount() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
Description: "Google (GCP) Service-account",
|
||||||
|
RuleID: "gcp-service-account",
|
||||||
|
Regex: regexp.MustCompile(`\"type\": \"service_account\"`),
|
||||||
|
Keywords: []string{`\"type\": \"service_account\"`},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
`"type": "service_account"`,
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
|
|
||||||
|
func GCPAPIKey() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
RuleID: "gcp-api-key",
|
||||||
|
Description: "GCP API key",
|
||||||
|
Regex: generateUniqueTokenRegex(`AIza[0-9A-Za-z\\-_]{35}`),
|
||||||
|
SecretGroup: 1,
|
||||||
|
Keywords: []string{
|
||||||
|
"AIza",
|
||||||
|
},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("gcp", secrets.NewSecret(`AIza[0-9A-Za-z\\-_]{35}`)),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
@@ -0,0 +1,55 @@
|
|||||||
|
package rules
|
||||||
|
|
||||||
|
import (
|
||||||
|
"github.com/zricethezav/gitleaks/v8/config"
|
||||||
|
)
|
||||||
|
|
||||||
|
func GenericCredential() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
RuleID: "generic-api-key",
|
||||||
|
Description: "Generic API Key",
|
||||||
|
Regex: generateSemiGenericRegex([]string{
|
||||||
|
"key",
|
||||||
|
"api",
|
||||||
|
"token",
|
||||||
|
"secret",
|
||||||
|
"client",
|
||||||
|
"passwd",
|
||||||
|
"password",
|
||||||
|
"auth",
|
||||||
|
"access",
|
||||||
|
}, `[0-9a-z\-_.=]{10,150}`),
|
||||||
|
SecretGroup: 1,
|
||||||
|
Keywords: []string{
|
||||||
|
"key",
|
||||||
|
"api",
|
||||||
|
"token",
|
||||||
|
"secret",
|
||||||
|
"client",
|
||||||
|
"passwd",
|
||||||
|
"password",
|
||||||
|
"auth",
|
||||||
|
"access",
|
||||||
|
},
|
||||||
|
Entropy: 3.5,
|
||||||
|
Allowlist: config.Allowlist{
|
||||||
|
StopWords: DefaultStopWords,
|
||||||
|
},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("generic", "CLOJARS_34bf0e88955ff5a1c328d6a7491acc4f48e865a7b8dd4d70a70749037443"),
|
||||||
|
generateSampleSecret("generic", "Zf3D0LXCM3EIMbgJpUNnkRtOfOueHznB"),
|
||||||
|
`"client_id" : "0afae57f3ccfd9d7f5767067bc48b30f719e271ba470488056e37ab35d4b6506"`,
|
||||||
|
`"client_secret" : "6da89121079f83b2eb6acccf8219ea982c3d79bccc3e9c6a85856480661f8fde",`,
|
||||||
|
}
|
||||||
|
fps := []string{
|
||||||
|
`client_vpn_endpoint_id = aws_ec2_client_vpn_endpoint.client-vpn-endpoint.id`,
|
||||||
|
`password combination.
|
||||||
|
|
||||||
|
R5: Regulatory--21`,
|
||||||
|
}
|
||||||
|
return validate(r, tps, fps)
|
||||||
|
}
|
||||||
@@ -0,0 +1,73 @@
|
|||||||
|
package rules
|
||||||
|
|
||||||
|
import (
|
||||||
|
"regexp"
|
||||||
|
|
||||||
|
"github.com/zricethezav/gitleaks/v8/cmd/generate/secrets"
|
||||||
|
"github.com/zricethezav/gitleaks/v8/config"
|
||||||
|
)
|
||||||
|
|
||||||
|
func GitHubPat() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
Description: "GitHub Personal Access Token",
|
||||||
|
RuleID: "github-pat",
|
||||||
|
Regex: regexp.MustCompile(`ghp_[0-9a-zA-Z]{36}`),
|
||||||
|
Keywords: []string{"ghp_"},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("github", "ghp_"+secrets.NewSecret(alphaNumeric("36"))),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
|
|
||||||
|
func GitHubOauth() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
Description: "GitHub OAuth Access Token",
|
||||||
|
RuleID: "github-oauth",
|
||||||
|
Regex: regexp.MustCompile(`gho_[0-9a-zA-Z]{36}`),
|
||||||
|
Keywords: []string{"gho_"},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("github", "gho_"+secrets.NewSecret(alphaNumeric("36"))),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
|
|
||||||
|
func GitHubApp() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
Description: "GitHub App Token",
|
||||||
|
RuleID: "github-app-token",
|
||||||
|
Regex: regexp.MustCompile(`(ghu|ghs)_[0-9a-zA-Z]{36}`),
|
||||||
|
Keywords: []string{"ghu_", "ghs_"},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("github", "ghu_"+secrets.NewSecret(alphaNumeric("36"))),
|
||||||
|
generateSampleSecret("github", "ghs_"+secrets.NewSecret(alphaNumeric("36"))),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
|
|
||||||
|
func GitHubRefresh() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
Description: "GitHub Refresh Token",
|
||||||
|
RuleID: "github-refresh-token",
|
||||||
|
Regex: regexp.MustCompile(`ghr_[0-9a-zA-Z]{36}`),
|
||||||
|
Keywords: []string{"ghr_"},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("github", "ghr_"+secrets.NewSecret(alphaNumeric("36"))),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
@@ -0,0 +1,24 @@
|
|||||||
|
package rules
|
||||||
|
|
||||||
|
import (
|
||||||
|
"regexp"
|
||||||
|
|
||||||
|
"github.com/zricethezav/gitleaks/v8/cmd/generate/secrets"
|
||||||
|
"github.com/zricethezav/gitleaks/v8/config"
|
||||||
|
)
|
||||||
|
|
||||||
|
func Gitlab() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
Description: "GitLab Personal Access Token",
|
||||||
|
RuleID: "gitlab-pat",
|
||||||
|
Regex: regexp.MustCompile(`glpat-[0-9a-zA-Z\-\_]{20}`),
|
||||||
|
Keywords: []string{"glpat-"},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("gitlab", "glpat-"+secrets.NewSecret(alphaNumeric("20"))),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
@@ -0,0 +1,27 @@
|
|||||||
|
package rules
|
||||||
|
|
||||||
|
import (
|
||||||
|
"github.com/zricethezav/gitleaks/v8/cmd/generate/secrets"
|
||||||
|
"github.com/zricethezav/gitleaks/v8/config"
|
||||||
|
)
|
||||||
|
|
||||||
|
func GitterAccessToken() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
RuleID: "gitter-access-token",
|
||||||
|
Description: "Gitter Access Token",
|
||||||
|
Regex: generateSemiGenericRegex([]string{"gitter"},
|
||||||
|
alphaNumericExtendedShort("40")),
|
||||||
|
SecretGroup: 1,
|
||||||
|
Keywords: []string{
|
||||||
|
"gitter",
|
||||||
|
},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("gitter",
|
||||||
|
secrets.NewSecret(alphaNumericExtendedShort("40"))),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
@@ -0,0 +1,26 @@
|
|||||||
|
package rules
|
||||||
|
|
||||||
|
import (
|
||||||
|
"github.com/zricethezav/gitleaks/v8/cmd/generate/secrets"
|
||||||
|
"github.com/zricethezav/gitleaks/v8/config"
|
||||||
|
)
|
||||||
|
|
||||||
|
func GoCardless() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
RuleID: "gocardless-api-token",
|
||||||
|
Description: "GoCardless API token",
|
||||||
|
Regex: generateSemiGenericRegex([]string{"gocardless"}, `live_(?i)[a-z0-9\-_=]{40}`),
|
||||||
|
SecretGroup: 1,
|
||||||
|
Keywords: []string{
|
||||||
|
"live_",
|
||||||
|
"gocardless",
|
||||||
|
},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("gocardless", "live_"+secrets.NewSecret(alphaNumericExtended("40"))),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
@@ -0,0 +1,24 @@
|
|||||||
|
package rules
|
||||||
|
|
||||||
|
import (
|
||||||
|
"regexp"
|
||||||
|
|
||||||
|
"github.com/zricethezav/gitleaks/v8/cmd/generate/secrets"
|
||||||
|
"github.com/zricethezav/gitleaks/v8/config"
|
||||||
|
)
|
||||||
|
|
||||||
|
func Hashicorp() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
Description: "HashiCorp Terraform user/org API token",
|
||||||
|
RuleID: "hashicorp-tf-api-token",
|
||||||
|
Regex: regexp.MustCompile(`(?i)[a-z0-9]{14}\.atlasv1\.[a-z0-9\-_=]{60,70}`),
|
||||||
|
Keywords: []string{"atlasv1"},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("hashicorpToken", secrets.NewSecret(hex("14"))+".atlasv1."+secrets.NewSecret(alphaNumericExtended("60,70"))),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
@@ -0,0 +1,22 @@
|
|||||||
|
package rules
|
||||||
|
|
||||||
|
import (
|
||||||
|
"github.com/zricethezav/gitleaks/v8/config"
|
||||||
|
)
|
||||||
|
|
||||||
|
func Heroku() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
Description: "Heroku API Key",
|
||||||
|
RuleID: "heroku-api-key",
|
||||||
|
Regex: generateSemiGenericRegex([]string{"heroku"}, hex8_4_4_4_12()),
|
||||||
|
SecretGroup: 1,
|
||||||
|
Keywords: []string{"heroku"},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
`const HEROKU_KEY = "12345678-ABCD-ABCD-ABCD-1234567890AB"`, // gitleaks:allow
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
@@ -0,0 +1,23 @@
|
|||||||
|
package rules
|
||||||
|
|
||||||
|
import (
|
||||||
|
"github.com/zricethezav/gitleaks/v8/config"
|
||||||
|
)
|
||||||
|
|
||||||
|
func HubSpot() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
Description: "HubSpot API Token",
|
||||||
|
RuleID: "hubspot-api-key",
|
||||||
|
Regex: generateSemiGenericRegex([]string{"hubspot"},
|
||||||
|
`[0-9A-F]{8}-[0-9A-F]{4}-[0-9A-F]{4}-[0-9A-F]{4}-[0-9A-F]{12}`),
|
||||||
|
SecretGroup: 1,
|
||||||
|
Keywords: []string{"hubspot"},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
`const hubspotKey = "12345678-ABCD-ABCD-ABCD-1234567890AB"`, // gitleaks:allow
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
@@ -0,0 +1,23 @@
|
|||||||
|
package rules
|
||||||
|
|
||||||
|
import (
|
||||||
|
"github.com/zricethezav/gitleaks/v8/cmd/generate/secrets"
|
||||||
|
"github.com/zricethezav/gitleaks/v8/config"
|
||||||
|
)
|
||||||
|
|
||||||
|
func Intercom() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
Description: "Intercom API Token",
|
||||||
|
RuleID: "intercom-api-key",
|
||||||
|
Regex: generateSemiGenericRegex([]string{"intercom"}, alphaNumericExtended("60")),
|
||||||
|
SecretGroup: 1,
|
||||||
|
Keywords: []string{"intercom"},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("intercom", secrets.NewSecret(alphaNumericExtended("60"))),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
@@ -0,0 +1,22 @@
|
|||||||
|
package rules
|
||||||
|
|
||||||
|
import (
|
||||||
|
"github.com/zricethezav/gitleaks/v8/config"
|
||||||
|
)
|
||||||
|
|
||||||
|
func JWT() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
Description: "JSON Web Token",
|
||||||
|
RuleID: "jwt",
|
||||||
|
Regex: generateUniqueTokenRegex(`ey[0-9a-z]{30,34}\.ey[0-9a-z-\/_]{30,500}\.[0-9a-zA-Z-\/_]{10,200}`),
|
||||||
|
Keywords: []string{"ey"},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{`eyJhbGciOieeeiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiIxMjM0NTY3ODkwIiwibmFtZSI6IkpvaG4gRG9lIiwic3ViZSI6IjEyMzQ1Njc4OTAiLCJuYW1lZWEiOiJKb2huIERvZSIsInN1ZmV3YWZiIjoiMTIzNDU2Nzg5MCIsIm5hbWVmZWF3ZnciOiJKb2huIERvZSIsIm5hbWVhZmV3ZmEiOiJKb2huIERvZSIsInN1ZndhZndlYWIiOiIxMjM0NTY3ODkwIiwibmFtZWZ3YWYiOiJKb2huIERvZSIsInN1YmZ3YWYiOiIxMjM0NTY3ODkwIiwibmFtZndhZSI6IkpvaG4gRG9lIiwiaWZ3YWZhYXQiOjE1MTYyMzkwMjJ9.a_5icKBDo-8EjUlrfvz2k2k-FYaindQ0DEYNrlsnRG0
|
||||||
|
`, // gitleaks:allow
|
||||||
|
`JWT := eyJhbGciOieeeiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiIxMjM0NTY3ODkwIiwibmFtZSI6IkpvaG4gRG9lIiwic3ViZSI6IjEyMzQ1Njc4OTAiLCJuYW1lZWEiOiJKb2huIERvZSIsInN1ZmV3YWZiIjoiMTIzNDU2Nzg5MCIsIm5hbWVmZWF3ZnciOiJKb2huIERvZSIsIm5hbWVhZmV3ZmEiOiJKb2huIERvZSIsInN1ZndhZndlYWIiOiIxMjM0NTY3ODkwIiwibmFtZWZ3YWYiOiJKb2huIERvZSIsInN1YmZ3YWYiOiIxMjM0NTY3ODkwIiwibmFtZndhZSI6IkpvaG4gRG9lIiwiaWZ3YWZhYXQiOjE1MTYyMzkwMjJ9.a_5icKBDo-8EjUlrfvz2k2k-FYaindQ0DEYNrlsnRG0`, // gitleaks:allow
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
@@ -0,0 +1,27 @@
|
|||||||
|
package rules
|
||||||
|
|
||||||
|
import (
|
||||||
|
"github.com/zricethezav/gitleaks/v8/cmd/generate/secrets"
|
||||||
|
"github.com/zricethezav/gitleaks/v8/config"
|
||||||
|
)
|
||||||
|
|
||||||
|
func KrakenAccessToken() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
RuleID: "kraken-access-token",
|
||||||
|
Description: "Kraken Access Token",
|
||||||
|
Regex: generateSemiGenericRegex([]string{"kraken"},
|
||||||
|
alphaNumericExtendedLong("80,90")),
|
||||||
|
SecretGroup: 1,
|
||||||
|
Keywords: []string{
|
||||||
|
"kraken",
|
||||||
|
},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("kraken",
|
||||||
|
secrets.NewSecret(alphaNumericExtendedLong("80,90"))),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
@@ -0,0 +1,44 @@
|
|||||||
|
package rules
|
||||||
|
|
||||||
|
import (
|
||||||
|
"github.com/zricethezav/gitleaks/v8/cmd/generate/secrets"
|
||||||
|
"github.com/zricethezav/gitleaks/v8/config"
|
||||||
|
)
|
||||||
|
|
||||||
|
func KucoinAccessToken() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
RuleID: "kucoin-access-token",
|
||||||
|
Description: "Kucoin Access Token",
|
||||||
|
Regex: generateSemiGenericRegex([]string{"kucoin"}, hex("24")),
|
||||||
|
SecretGroup: 1,
|
||||||
|
Keywords: []string{
|
||||||
|
"kucoin",
|
||||||
|
},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("kucoin", secrets.NewSecret(hex("24"))),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
|
|
||||||
|
func KucoinSecretKey() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
RuleID: "kucoin-secret-key",
|
||||||
|
Description: "Kucoin Secret Key",
|
||||||
|
Regex: generateSemiGenericRegex([]string{"kucoin"}, hex8_4_4_4_12()),
|
||||||
|
SecretGroup: 1,
|
||||||
|
Keywords: []string{
|
||||||
|
"kucoin",
|
||||||
|
},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("kucoin", secrets.NewSecret(hex8_4_4_4_12())),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
@@ -0,0 +1,25 @@
|
|||||||
|
package rules
|
||||||
|
|
||||||
|
import (
|
||||||
|
"github.com/zricethezav/gitleaks/v8/cmd/generate/secrets"
|
||||||
|
"github.com/zricethezav/gitleaks/v8/config"
|
||||||
|
)
|
||||||
|
|
||||||
|
func LaunchDarklyAccessToken() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
RuleID: "launchdarkly-access-token",
|
||||||
|
Description: "Launchdarkly Access Token",
|
||||||
|
Regex: generateSemiGenericRegex([]string{"launchdarkly"}, alphaNumericExtended("40")),
|
||||||
|
SecretGroup: 1,
|
||||||
|
Keywords: []string{
|
||||||
|
"launchdarkly",
|
||||||
|
},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("launchdarkly", secrets.NewSecret(alphaNumericExtended("40"))),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
@@ -0,0 +1,41 @@
|
|||||||
|
package rules
|
||||||
|
|
||||||
|
import (
|
||||||
|
"regexp"
|
||||||
|
|
||||||
|
"github.com/zricethezav/gitleaks/v8/cmd/generate/secrets"
|
||||||
|
"github.com/zricethezav/gitleaks/v8/config"
|
||||||
|
)
|
||||||
|
|
||||||
|
func LinearAPIToken() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
Description: "Linear API Token",
|
||||||
|
RuleID: "linear-api-key",
|
||||||
|
Regex: regexp.MustCompile(`lin_api_(?i)[a-z0-9]{40}`),
|
||||||
|
Keywords: []string{"lin_api_"},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("linear", "lin_api_"+secrets.NewSecret(alphaNumeric("40"))),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
|
|
||||||
|
func LinearClientSecret() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
Description: "Linear Client Secret",
|
||||||
|
RuleID: "linear-client-secret",
|
||||||
|
Regex: generateSemiGenericRegex([]string{"linear"}, hex("32")),
|
||||||
|
Keywords: []string{"linear"},
|
||||||
|
SecretGroup: 1,
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("linear", secrets.NewSecret(hex("32"))),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
@@ -0,0 +1,52 @@
|
|||||||
|
package rules
|
||||||
|
|
||||||
|
import (
|
||||||
|
"github.com/zricethezav/gitleaks/v8/cmd/generate/secrets"
|
||||||
|
"github.com/zricethezav/gitleaks/v8/config"
|
||||||
|
)
|
||||||
|
|
||||||
|
func LinkedinClientSecret() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
RuleID: "linkedin-client-secret",
|
||||||
|
Description: "LinkedIn Client secret",
|
||||||
|
Regex: generateSemiGenericRegex([]string{
|
||||||
|
"linkedin",
|
||||||
|
"linked-in",
|
||||||
|
}, alphaNumeric("16")),
|
||||||
|
SecretGroup: 1,
|
||||||
|
Keywords: []string{
|
||||||
|
"linkedin",
|
||||||
|
"linked-in",
|
||||||
|
},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("linkedin", secrets.NewSecret(alphaNumeric("16"))),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
|
|
||||||
|
func LinkedinClientID() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
RuleID: "linkedin-client-id",
|
||||||
|
Description: "LinkedIn Client ID",
|
||||||
|
Regex: generateSemiGenericRegex([]string{
|
||||||
|
"linkedin",
|
||||||
|
"linked-in",
|
||||||
|
}, alphaNumeric("14")),
|
||||||
|
SecretGroup: 1,
|
||||||
|
Keywords: []string{
|
||||||
|
"linkedin",
|
||||||
|
"linked-in",
|
||||||
|
},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("linkedin", secrets.NewSecret(alphaNumeric("14"))),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
@@ -0,0 +1,47 @@
|
|||||||
|
package rules
|
||||||
|
|
||||||
|
import (
|
||||||
|
"github.com/zricethezav/gitleaks/v8/cmd/generate/secrets"
|
||||||
|
"github.com/zricethezav/gitleaks/v8/config"
|
||||||
|
)
|
||||||
|
|
||||||
|
func LobPubAPIToken() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
Description: "Lob Publishable API Key",
|
||||||
|
RuleID: "lob-pub-api-key",
|
||||||
|
Regex: generateSemiGenericRegex([]string{"lob"}, `(test|live)_pub_[a-f0-9]{31}`),
|
||||||
|
SecretGroup: 1,
|
||||||
|
Keywords: []string{
|
||||||
|
"test_pub",
|
||||||
|
"live_pub",
|
||||||
|
"_pub",
|
||||||
|
},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("lob", "test_pub_"+secrets.NewSecret(hex("31"))),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
|
|
||||||
|
func LobAPIToken() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
Description: "Lob API Key",
|
||||||
|
RuleID: "lob-api-key",
|
||||||
|
Regex: generateSemiGenericRegex([]string{"lob"}, `(live|test)_[a-f0-9]{35}`),
|
||||||
|
Keywords: []string{
|
||||||
|
"test_",
|
||||||
|
"live_",
|
||||||
|
},
|
||||||
|
SecretGroup: 1,
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("lob", "test_"+secrets.NewSecret(hex("35"))),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
@@ -0,0 +1,25 @@
|
|||||||
|
package rules
|
||||||
|
|
||||||
|
import (
|
||||||
|
"github.com/zricethezav/gitleaks/v8/cmd/generate/secrets"
|
||||||
|
"github.com/zricethezav/gitleaks/v8/config"
|
||||||
|
)
|
||||||
|
|
||||||
|
func MailChimp() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
RuleID: "mailchimp-api-key",
|
||||||
|
Description: "Mailchimp API key",
|
||||||
|
Regex: generateSemiGenericRegex([]string{"mailchimp"}, `[a-f0-9]{32}-us20`),
|
||||||
|
SecretGroup: 1,
|
||||||
|
Keywords: []string{
|
||||||
|
"mailchimp",
|
||||||
|
},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("mailchimp", secrets.NewSecret(hex("32"))+"-us20"),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
@@ -0,0 +1,63 @@
|
|||||||
|
package rules
|
||||||
|
|
||||||
|
import (
|
||||||
|
"github.com/zricethezav/gitleaks/v8/cmd/generate/secrets"
|
||||||
|
"github.com/zricethezav/gitleaks/v8/config"
|
||||||
|
)
|
||||||
|
|
||||||
|
func MailGunPrivateAPIToken() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
RuleID: "mailgun-private-api-token",
|
||||||
|
Description: "Mailgun private API token",
|
||||||
|
Regex: generateSemiGenericRegex([]string{"mailgun"}, `key-[a-f0-9]{32}`),
|
||||||
|
SecretGroup: 1,
|
||||||
|
Keywords: []string{
|
||||||
|
"mailgun",
|
||||||
|
},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("mailgun", "key-"+secrets.NewSecret(hex("32"))),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
|
|
||||||
|
func MailGunPubAPIToken() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
RuleID: "mailgun-pub-key",
|
||||||
|
Description: "Mailgun public validation key",
|
||||||
|
Regex: generateSemiGenericRegex([]string{"mailgun"}, `pubkey-[a-f0-9]{32}`),
|
||||||
|
SecretGroup: 1,
|
||||||
|
Keywords: []string{
|
||||||
|
"mailgun",
|
||||||
|
},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("mailgun", "pubkey-"+secrets.NewSecret(hex("32"))),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
|
|
||||||
|
func MailGunSigningKey() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
RuleID: "mailgun-signing-key",
|
||||||
|
Description: "Mailgun webhook signing key",
|
||||||
|
Regex: generateSemiGenericRegex([]string{"mailgun"}, `[a-h0-9]{32}-[a-h0-9]{8}-[a-h0-9]{8}`),
|
||||||
|
SecretGroup: 1,
|
||||||
|
Keywords: []string{
|
||||||
|
"mailgun",
|
||||||
|
},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("mailgun", secrets.NewSecret(hex("32"))+"-00001111-22223333"),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
@@ -0,0 +1,23 @@
|
|||||||
|
package rules
|
||||||
|
|
||||||
|
import (
|
||||||
|
"github.com/zricethezav/gitleaks/v8/cmd/generate/secrets"
|
||||||
|
"github.com/zricethezav/gitleaks/v8/config"
|
||||||
|
)
|
||||||
|
|
||||||
|
func MapBox() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
Description: "MapBox API token",
|
||||||
|
RuleID: "mapbox-api-token",
|
||||||
|
Regex: generateSemiGenericRegex([]string{"mapbox"}, `pk\.[a-z0-9]{60}\.[a-z0-9]{22}`),
|
||||||
|
SecretGroup: 1,
|
||||||
|
Keywords: []string{"mapbox"},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("mapbox", "pk."+secrets.NewSecret(alphaNumeric("60"))+"."+secrets.NewSecret(alphaNumeric("22"))),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
@@ -0,0 +1,25 @@
|
|||||||
|
package rules
|
||||||
|
|
||||||
|
import (
|
||||||
|
"github.com/zricethezav/gitleaks/v8/cmd/generate/secrets"
|
||||||
|
"github.com/zricethezav/gitleaks/v8/config"
|
||||||
|
)
|
||||||
|
|
||||||
|
func MattermostAccessToken() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
RuleID: "mattermost-access-token",
|
||||||
|
Description: "Mattermost Access Token",
|
||||||
|
Regex: generateSemiGenericRegex([]string{"mattermost"}, alphaNumeric("26")),
|
||||||
|
SecretGroup: 1,
|
||||||
|
Keywords: []string{
|
||||||
|
"mattermost",
|
||||||
|
},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("mattermost", secrets.NewSecret(alphaNumeric("26"))),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
@@ -0,0 +1,58 @@
|
|||||||
|
package rules
|
||||||
|
|
||||||
|
import (
|
||||||
|
"github.com/zricethezav/gitleaks/v8/cmd/generate/secrets"
|
||||||
|
"github.com/zricethezav/gitleaks/v8/config"
|
||||||
|
)
|
||||||
|
|
||||||
|
func MessageBirdAPIToken() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
Description: "MessageBird API token",
|
||||||
|
RuleID: "messagebird-api-token",
|
||||||
|
Regex: generateSemiGenericRegex([]string{
|
||||||
|
"messagebird",
|
||||||
|
"message-bird",
|
||||||
|
"message_bird",
|
||||||
|
}, alphaNumeric("25")),
|
||||||
|
SecretGroup: 1,
|
||||||
|
Keywords: []string{
|
||||||
|
"messagebird",
|
||||||
|
"message-bird",
|
||||||
|
"message_bird",
|
||||||
|
},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("messagebird", secrets.NewSecret(alphaNumeric("25"))),
|
||||||
|
generateSampleSecret("message-bird", secrets.NewSecret(alphaNumeric("25"))),
|
||||||
|
generateSampleSecret("message_bird", secrets.NewSecret(alphaNumeric("25"))),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
|
|
||||||
|
func MessageBirdClientID() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
Description: "MessageBird client ID",
|
||||||
|
RuleID: "messagebird-client-id",
|
||||||
|
Regex: generateSemiGenericRegex([]string{
|
||||||
|
"messagebird",
|
||||||
|
"message-bird",
|
||||||
|
"message_bird",
|
||||||
|
}, hex8_4_4_4_12()),
|
||||||
|
SecretGroup: 1,
|
||||||
|
Keywords: []string{
|
||||||
|
"messagebird",
|
||||||
|
"message-bird",
|
||||||
|
"message_bird",
|
||||||
|
},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
`const MessageBirdClientID = "12345678-ABCD-ABCD-ABCD-1234567890AB"`, // gitleaks:allow
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
@@ -0,0 +1,26 @@
|
|||||||
|
package rules
|
||||||
|
|
||||||
|
import (
|
||||||
|
"github.com/zricethezav/gitleaks/v8/cmd/generate/secrets"
|
||||||
|
"github.com/zricethezav/gitleaks/v8/config"
|
||||||
|
)
|
||||||
|
|
||||||
|
func NetlifyAccessToken() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
RuleID: "netlify-access-token",
|
||||||
|
Description: "Netlify Access Token",
|
||||||
|
Regex: generateSemiGenericRegex([]string{"netlify"},
|
||||||
|
alphaNumericExtended("40,46")),
|
||||||
|
SecretGroup: 1,
|
||||||
|
Keywords: []string{
|
||||||
|
"netlify",
|
||||||
|
},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("netlify", secrets.NewSecret(alphaNumericExtended("40,46"))),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
@@ -0,0 +1,77 @@
|
|||||||
|
package rules
|
||||||
|
|
||||||
|
import (
|
||||||
|
"github.com/zricethezav/gitleaks/v8/cmd/generate/secrets"
|
||||||
|
"github.com/zricethezav/gitleaks/v8/config"
|
||||||
|
)
|
||||||
|
|
||||||
|
func NewRelicUserID() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
RuleID: "new-relic-user-api-key",
|
||||||
|
Description: "New Relic user API Key",
|
||||||
|
Regex: generateSemiGenericRegex([]string{
|
||||||
|
"new-relic",
|
||||||
|
"newrelic",
|
||||||
|
"new_relic",
|
||||||
|
}, `NRAK-[a-z0-9]{27}`),
|
||||||
|
SecretGroup: 1,
|
||||||
|
Keywords: []string{
|
||||||
|
"NRAK",
|
||||||
|
},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("new-relic", "NRAK-"+secrets.NewSecret(alphaNumeric("27"))),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
|
|
||||||
|
func NewRelicUserKey() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
RuleID: "new-relic-user-api-id",
|
||||||
|
Description: "New Relic user API ID",
|
||||||
|
Regex: generateSemiGenericRegex([]string{
|
||||||
|
"new-relic",
|
||||||
|
"newrelic",
|
||||||
|
"new_relic",
|
||||||
|
}, alphaNumeric("64")),
|
||||||
|
SecretGroup: 1,
|
||||||
|
Keywords: []string{
|
||||||
|
"new-relic",
|
||||||
|
"newrelic",
|
||||||
|
"new_relic",
|
||||||
|
},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("new-relic", secrets.NewSecret(alphaNumeric("64"))),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
|
|
||||||
|
func NewRelicBrowserAPIKey() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
RuleID: "new-relic-browser-api-token",
|
||||||
|
Description: "New Relic ingest browser API token",
|
||||||
|
Regex: generateSemiGenericRegex([]string{
|
||||||
|
"new-relic",
|
||||||
|
"newrelic",
|
||||||
|
"new_relic",
|
||||||
|
}, `NRJS-[a-f0-9]{19}`),
|
||||||
|
SecretGroup: 1,
|
||||||
|
Keywords: []string{
|
||||||
|
"NRJS-",
|
||||||
|
},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("new-relic", "NRJS-"+secrets.NewSecret(hex("19"))),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
@@ -0,0 +1,25 @@
|
|||||||
|
package rules
|
||||||
|
|
||||||
|
import (
|
||||||
|
"github.com/zricethezav/gitleaks/v8/cmd/generate/secrets"
|
||||||
|
"github.com/zricethezav/gitleaks/v8/config"
|
||||||
|
)
|
||||||
|
|
||||||
|
func NPM() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
RuleID: "npm-access-token",
|
||||||
|
Description: "npm access token",
|
||||||
|
Regex: generateUniqueTokenRegex(`npm_[a-z0-9]{36}`),
|
||||||
|
SecretGroup: 1,
|
||||||
|
Keywords: []string{
|
||||||
|
"npm_",
|
||||||
|
},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("npmAccessToken", "npm_"+secrets.NewSecret(alphaNumeric("36"))),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
@@ -0,0 +1,29 @@
|
|||||||
|
package rules
|
||||||
|
|
||||||
|
import (
|
||||||
|
"github.com/zricethezav/gitleaks/v8/cmd/generate/secrets"
|
||||||
|
"github.com/zricethezav/gitleaks/v8/config"
|
||||||
|
)
|
||||||
|
|
||||||
|
func NytimesAccessToken() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
RuleID: "nytimes-access-token",
|
||||||
|
Description: "Nytimes Access Token",
|
||||||
|
Regex: generateSemiGenericRegex([]string{
|
||||||
|
"nytimes", "new-york-times,", "newyorktimes"},
|
||||||
|
alphaNumericExtended("32")),
|
||||||
|
SecretGroup: 1,
|
||||||
|
Keywords: []string{
|
||||||
|
"nytimes",
|
||||||
|
"new-york-times",
|
||||||
|
"newyorktimes",
|
||||||
|
},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("nytimes", secrets.NewSecret(alphaNumeric("32"))),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
@@ -0,0 +1,26 @@
|
|||||||
|
package rules
|
||||||
|
|
||||||
|
import (
|
||||||
|
"github.com/zricethezav/gitleaks/v8/cmd/generate/secrets"
|
||||||
|
"github.com/zricethezav/gitleaks/v8/config"
|
||||||
|
)
|
||||||
|
|
||||||
|
func OktaAccessToken() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
RuleID: "okta-access-token",
|
||||||
|
Description: "Okta Access Token",
|
||||||
|
Regex: generateSemiGenericRegex([]string{"okta"},
|
||||||
|
alphaNumericExtended("42")),
|
||||||
|
SecretGroup: 1,
|
||||||
|
Keywords: []string{
|
||||||
|
"okta",
|
||||||
|
},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("okta", secrets.NewSecret(alphaNumeric("42"))),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
@@ -0,0 +1,66 @@
|
|||||||
|
package rules
|
||||||
|
|
||||||
|
import (
|
||||||
|
"fmt"
|
||||||
|
|
||||||
|
"github.com/zricethezav/gitleaks/v8/cmd/generate/secrets"
|
||||||
|
"github.com/zricethezav/gitleaks/v8/config"
|
||||||
|
)
|
||||||
|
|
||||||
|
func PlaidAccessID() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
RuleID: "plaid-client-id",
|
||||||
|
Description: "Plaid Client ID",
|
||||||
|
Regex: generateSemiGenericRegex([]string{"plaid"}, alphaNumeric("24")),
|
||||||
|
SecretGroup: 1,
|
||||||
|
Keywords: []string{
|
||||||
|
"plaid",
|
||||||
|
},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("plaid", secrets.NewSecret(alphaNumeric("24"))),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
|
|
||||||
|
func PlaidSecretKey() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
RuleID: "plaid-secret-key",
|
||||||
|
Description: "Plaid Secret key",
|
||||||
|
Regex: generateSemiGenericRegex([]string{"plaid"}, alphaNumeric("30")),
|
||||||
|
SecretGroup: 1,
|
||||||
|
Keywords: []string{
|
||||||
|
"plaid",
|
||||||
|
},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("plaid", secrets.NewSecret(alphaNumeric("30"))),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
|
|
||||||
|
func PlaidAccessToken() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
RuleID: "plaid-api-token",
|
||||||
|
Description: "Plaid API Token",
|
||||||
|
Regex: generateSemiGenericRegex([]string{"plaid"},
|
||||||
|
fmt.Sprintf("access-(?:sandbox|development|production)-%s", hex8_4_4_4_12())),
|
||||||
|
SecretGroup: 1,
|
||||||
|
Keywords: []string{
|
||||||
|
"plaid",
|
||||||
|
},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("plaid", secrets.NewSecret(fmt.Sprintf("access-(?:sandbox|development|production)-%s", hex8_4_4_4_12()))),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
@@ -0,0 +1,69 @@
|
|||||||
|
package rules
|
||||||
|
|
||||||
|
import (
|
||||||
|
"github.com/zricethezav/gitleaks/v8/cmd/generate/secrets"
|
||||||
|
"github.com/zricethezav/gitleaks/v8/config"
|
||||||
|
)
|
||||||
|
|
||||||
|
func PlanetScalePassword() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
RuleID: "planetscale-password",
|
||||||
|
Description: "PlanetScale password",
|
||||||
|
Regex: generateUniqueTokenRegex(`pscale_pw_(?i)[a-z0-9=\-_\.]{32,64}`),
|
||||||
|
SecretGroup: 1,
|
||||||
|
Keywords: []string{
|
||||||
|
"pscale_pw_",
|
||||||
|
},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("planetScalePassword", "pscale_pw_"+secrets.NewSecret(alphaNumericExtended("32"))),
|
||||||
|
generateSampleSecret("planetScalePassword", "pscale_pw_"+secrets.NewSecret(alphaNumericExtended("43"))),
|
||||||
|
generateSampleSecret("planetScalePassword", "pscale_pw_"+secrets.NewSecret(alphaNumericExtended("64"))),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
|
|
||||||
|
func PlanetScaleAPIToken() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
RuleID: "planetscale-api-token",
|
||||||
|
Description: "PlanetScale API token",
|
||||||
|
Regex: generateUniqueTokenRegex(`pscale_tkn_(?i)[a-z0-9=\-_\.]{32,64}`),
|
||||||
|
SecretGroup: 1,
|
||||||
|
Keywords: []string{
|
||||||
|
"pscale_tkn_",
|
||||||
|
},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("planetScalePassword", "pscale_tkn_"+secrets.NewSecret(alphaNumericExtended("32"))),
|
||||||
|
generateSampleSecret("planetScalePassword", "pscale_tkn_"+secrets.NewSecret(alphaNumericExtended("43"))),
|
||||||
|
generateSampleSecret("planetScalePassword", "pscale_tkn_"+secrets.NewSecret(alphaNumericExtended("64"))),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
|
|
||||||
|
func PlanetScaleOAuthToken() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
RuleID: "planetscale-oauth-token",
|
||||||
|
Description: "PlanetScale OAuth token",
|
||||||
|
Regex: generateUniqueTokenRegex(`pscale_oauth_(?i)[a-z0-9=\-_\.]{32,64}`),
|
||||||
|
SecretGroup: 1,
|
||||||
|
Keywords: []string{
|
||||||
|
"pscale_oauth_",
|
||||||
|
},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("planetScalePassword", "pscale_oauth_"+secrets.NewSecret(alphaNumericExtended("32"))),
|
||||||
|
generateSampleSecret("planetScalePassword", "pscale_oauth_"+secrets.NewSecret(alphaNumericExtended("43"))),
|
||||||
|
generateSampleSecret("planetScalePassword", "pscale_oauth_"+secrets.NewSecret(alphaNumericExtended("64"))),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
@@ -0,0 +1,25 @@
|
|||||||
|
package rules
|
||||||
|
|
||||||
|
import (
|
||||||
|
"github.com/zricethezav/gitleaks/v8/cmd/generate/secrets"
|
||||||
|
"github.com/zricethezav/gitleaks/v8/config"
|
||||||
|
)
|
||||||
|
|
||||||
|
func PostManAPI() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
RuleID: "postman-api-token",
|
||||||
|
Description: "Postman API token",
|
||||||
|
Regex: generateUniqueTokenRegex(`PMAK-(?i)[a-f0-9]{24}\-[a-f0-9]{34}`),
|
||||||
|
SecretGroup: 1,
|
||||||
|
Keywords: []string{
|
||||||
|
"PMAK-",
|
||||||
|
},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("postmanAPItoken", "PMAK-"+secrets.NewSecret(hex("24"))+"-"+secrets.NewSecret(hex("34"))),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
@@ -0,0 +1,28 @@
|
|||||||
|
package rules
|
||||||
|
|
||||||
|
import (
|
||||||
|
"regexp"
|
||||||
|
|
||||||
|
"github.com/zricethezav/gitleaks/v8/config"
|
||||||
|
)
|
||||||
|
|
||||||
|
func PrivateKey() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
Description: "Private Key",
|
||||||
|
RuleID: "private-key",
|
||||||
|
Regex: regexp.MustCompile(`(?i)-----BEGIN[ A-Z0-9_-]{0,100}PRIVATE KEY-----[\s\S-]*KEY----`),
|
||||||
|
Keywords: []string{"-----BEGIN"},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{`-----BEGIN PRIVATE KEY-----
|
||||||
|
anything
|
||||||
|
-----END PRIVATE KEY-----`,
|
||||||
|
`-----BEGIN RSA PRIVATE KEY-----
|
||||||
|
abcdefghijklmnopqrstuvwxyz
|
||||||
|
-----END RSA PRIVATE KEY-----
|
||||||
|
`,
|
||||||
|
} // gitleaks:allow
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
@@ -0,0 +1,25 @@
|
|||||||
|
package rules
|
||||||
|
|
||||||
|
import (
|
||||||
|
"github.com/zricethezav/gitleaks/v8/cmd/generate/secrets"
|
||||||
|
"github.com/zricethezav/gitleaks/v8/config"
|
||||||
|
)
|
||||||
|
|
||||||
|
func PulumiAPIToken() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
RuleID: "pulumi-api-token",
|
||||||
|
Description: "Pulumi API token",
|
||||||
|
Regex: generateUniqueTokenRegex(`pul-[a-f0-9]{40}`),
|
||||||
|
SecretGroup: 1,
|
||||||
|
Keywords: []string{
|
||||||
|
"pul-",
|
||||||
|
},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("pulumi-api-token", "pul-"+secrets.NewSecret(hex("40"))),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
@@ -0,0 +1,26 @@
|
|||||||
|
package rules
|
||||||
|
|
||||||
|
import (
|
||||||
|
"regexp"
|
||||||
|
|
||||||
|
"github.com/zricethezav/gitleaks/v8/cmd/generate/secrets"
|
||||||
|
"github.com/zricethezav/gitleaks/v8/config"
|
||||||
|
)
|
||||||
|
|
||||||
|
func PyPiUploadToken() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
Description: "PyPI upload token",
|
||||||
|
RuleID: "pypi-upload-token",
|
||||||
|
Regex: regexp.MustCompile(
|
||||||
|
`pypi-AgEIcHlwaS5vcmc[A-Za-z0-9\-_]{50,1000}`),
|
||||||
|
Keywords: []string{
|
||||||
|
"pypi-AgEIcHlwaS5vcmc",
|
||||||
|
},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{"pypiToken := \"pypi-AgEIcHlwaS5vcmc" + secrets.NewSecret(hex("32")) +
|
||||||
|
secrets.NewSecret(hex("32")) + "\""}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
@@ -0,0 +1,27 @@
|
|||||||
|
package rules
|
||||||
|
|
||||||
|
import (
|
||||||
|
"github.com/zricethezav/gitleaks/v8/cmd/generate/secrets"
|
||||||
|
"github.com/zricethezav/gitleaks/v8/config"
|
||||||
|
)
|
||||||
|
|
||||||
|
func RapidAPIAccessToken() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
RuleID: "rapidapi-access-token",
|
||||||
|
Description: "RapidAPI Access Token",
|
||||||
|
Regex: generateSemiGenericRegex([]string{"rapidapi"},
|
||||||
|
alphaNumericExtendedShort("50")),
|
||||||
|
SecretGroup: 1,
|
||||||
|
Keywords: []string{
|
||||||
|
"rapidapi",
|
||||||
|
},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("rapidapi",
|
||||||
|
secrets.NewSecret(alphaNumericExtendedShort("50"))),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
@@ -0,0 +1,25 @@
|
|||||||
|
package rules
|
||||||
|
|
||||||
|
import (
|
||||||
|
"github.com/zricethezav/gitleaks/v8/cmd/generate/secrets"
|
||||||
|
"github.com/zricethezav/gitleaks/v8/config"
|
||||||
|
)
|
||||||
|
|
||||||
|
func RubyGemsAPIToken() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
RuleID: "rubygems-api-token",
|
||||||
|
Description: "Rubygem API token",
|
||||||
|
Regex: generateUniqueTokenRegex(`rubygems_[a-f0-9]{48}`),
|
||||||
|
SecretGroup: 1,
|
||||||
|
Keywords: []string{
|
||||||
|
"rubygems_",
|
||||||
|
},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("rubygemsAPIToken", "rubygems_"+secrets.NewSecret(hex("48"))),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
@@ -0,0 +1,110 @@
|
|||||||
|
package rules
|
||||||
|
|
||||||
|
import (
|
||||||
|
"fmt"
|
||||||
|
"regexp"
|
||||||
|
"strings"
|
||||||
|
|
||||||
|
"github.com/rs/zerolog/log"
|
||||||
|
"github.com/zricethezav/gitleaks/v8/config"
|
||||||
|
"github.com/zricethezav/gitleaks/v8/detect"
|
||||||
|
)
|
||||||
|
|
||||||
|
const (
|
||||||
|
// case insensitive prefix
|
||||||
|
caseInsensitive = `(?i)`
|
||||||
|
|
||||||
|
// identifier prefix (just an ignore group)
|
||||||
|
identifierPrefix = `(?:`
|
||||||
|
identifierSuffix = `)(?:[0-9a-z\-_\t .]{0,20})(?:[\s|']|[\s|"]){0,3}`
|
||||||
|
|
||||||
|
// commonly used assignment operators or function call
|
||||||
|
operator = `(?:=|>|:=|\|\|:|<=|=>|:)`
|
||||||
|
|
||||||
|
// boundaries for the secret
|
||||||
|
// \x60 = `
|
||||||
|
secretPrefixUnique = `\b(`
|
||||||
|
secretPrefix = `(?:'|\"|\s|=|\x60){0,5}(`
|
||||||
|
secretSuffix = `)(?:['|\"|\n|\r|\s|\x60|;]|$)`
|
||||||
|
)
|
||||||
|
|
||||||
|
func generateSemiGenericRegex(identifiers []string, secretRegex string) *regexp.Regexp {
|
||||||
|
var sb strings.Builder
|
||||||
|
sb.WriteString(caseInsensitive)
|
||||||
|
sb.WriteString(identifierPrefix)
|
||||||
|
sb.WriteString(strings.Join(identifiers, "|"))
|
||||||
|
sb.WriteString(identifierSuffix)
|
||||||
|
sb.WriteString(operator)
|
||||||
|
sb.WriteString(secretPrefix)
|
||||||
|
sb.WriteString(secretRegex)
|
||||||
|
sb.WriteString(secretSuffix)
|
||||||
|
return regexp.MustCompile(sb.String())
|
||||||
|
}
|
||||||
|
|
||||||
|
func generateUniqueTokenRegex(secretRegex string) *regexp.Regexp {
|
||||||
|
var sb strings.Builder
|
||||||
|
sb.WriteString(caseInsensitive)
|
||||||
|
sb.WriteString(secretPrefixUnique)
|
||||||
|
sb.WriteString(secretRegex)
|
||||||
|
sb.WriteString(secretSuffix)
|
||||||
|
return regexp.MustCompile(sb.String())
|
||||||
|
}
|
||||||
|
|
||||||
|
func generateSampleSecret(identifier string, secret string) string {
|
||||||
|
return fmt.Sprintf("%s_api_token = \"%s\"", identifier, secret)
|
||||||
|
}
|
||||||
|
|
||||||
|
func validate(r config.Rule, truePositives []string, falsePositives []string) *config.Rule {
|
||||||
|
// normalize keywords like in the config package
|
||||||
|
var keywords []string
|
||||||
|
for _, k := range r.Keywords {
|
||||||
|
keywords = append(keywords, strings.ToLower(k))
|
||||||
|
}
|
||||||
|
r.Keywords = keywords
|
||||||
|
|
||||||
|
rules := make(map[string]config.Rule)
|
||||||
|
rules[r.RuleID] = r
|
||||||
|
d := detect.NewDetector(config.Config{
|
||||||
|
Rules: rules,
|
||||||
|
Keywords: keywords,
|
||||||
|
})
|
||||||
|
for _, tp := range truePositives {
|
||||||
|
if len(d.DetectString(tp)) != 1 {
|
||||||
|
log.Fatal().Msgf("Failed to validate. For rule ID [%s], true positive [%s] was not detected by regexp [%s]", r.RuleID, tp, r.Regex)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
for _, fp := range falsePositives {
|
||||||
|
if len(d.DetectString(fp)) != 0 {
|
||||||
|
log.Fatal().Msgf("Failed to validate (fp) [%s]", r.RuleID)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return &r
|
||||||
|
}
|
||||||
|
|
||||||
|
func numeric(size string) string {
|
||||||
|
return fmt.Sprintf(`[0-9]{%s}`, size)
|
||||||
|
}
|
||||||
|
|
||||||
|
func hex(size string) string {
|
||||||
|
return fmt.Sprintf(`[a-f0-9]{%s}`, size)
|
||||||
|
}
|
||||||
|
|
||||||
|
func alphaNumeric(size string) string {
|
||||||
|
return fmt.Sprintf(`[a-z0-9]{%s}`, size)
|
||||||
|
}
|
||||||
|
|
||||||
|
func alphaNumericExtendedShort(size string) string {
|
||||||
|
return fmt.Sprintf(`[a-z0-9_-]{%s}`, size)
|
||||||
|
}
|
||||||
|
|
||||||
|
func alphaNumericExtended(size string) string {
|
||||||
|
return fmt.Sprintf(`[a-z0-9=_\-]{%s}`, size)
|
||||||
|
}
|
||||||
|
|
||||||
|
func alphaNumericExtendedLong(size string) string {
|
||||||
|
return fmt.Sprintf(`[a-z0-9\/=_\+\-]{%s}`, size)
|
||||||
|
}
|
||||||
|
|
||||||
|
func hex8_4_4_4_12() string {
|
||||||
|
return `[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}`
|
||||||
|
}
|
||||||
@@ -0,0 +1,44 @@
|
|||||||
|
package rules
|
||||||
|
|
||||||
|
import (
|
||||||
|
"github.com/zricethezav/gitleaks/v8/cmd/generate/secrets"
|
||||||
|
"github.com/zricethezav/gitleaks/v8/config"
|
||||||
|
)
|
||||||
|
|
||||||
|
func SendbirdAccessToken() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
RuleID: "sendbird-access-token",
|
||||||
|
Description: "Sendbird Access Token",
|
||||||
|
Regex: generateSemiGenericRegex([]string{"sendbird"}, hex("40")),
|
||||||
|
SecretGroup: 1,
|
||||||
|
Keywords: []string{
|
||||||
|
"sendbird",
|
||||||
|
},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("sendbird", secrets.NewSecret(hex("40"))),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
|
|
||||||
|
func SendbirdAccessID() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
RuleID: "sendbird-access-id",
|
||||||
|
Description: "Sendbird Access ID",
|
||||||
|
Regex: generateSemiGenericRegex([]string{"sendbird"}, hex8_4_4_4_12()),
|
||||||
|
SecretGroup: 1,
|
||||||
|
Keywords: []string{
|
||||||
|
"sendbird",
|
||||||
|
},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("sendbird", secrets.NewSecret(hex8_4_4_4_12())),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
@@ -0,0 +1,25 @@
|
|||||||
|
package rules
|
||||||
|
|
||||||
|
import (
|
||||||
|
"github.com/zricethezav/gitleaks/v8/cmd/generate/secrets"
|
||||||
|
"github.com/zricethezav/gitleaks/v8/config"
|
||||||
|
)
|
||||||
|
|
||||||
|
func SendGridAPIToken() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
RuleID: "sendgrid-api-token",
|
||||||
|
Description: "SendGrid API token",
|
||||||
|
Regex: generateUniqueTokenRegex(`SG\.(?i)[a-z0-9=_\-\.]{66}`),
|
||||||
|
SecretGroup: 1,
|
||||||
|
Keywords: []string{
|
||||||
|
"SG.",
|
||||||
|
},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("sengridAPIToken", "SG."+secrets.NewSecret(alphaNumericExtended("66"))),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
@@ -0,0 +1,25 @@
|
|||||||
|
package rules
|
||||||
|
|
||||||
|
import (
|
||||||
|
"github.com/zricethezav/gitleaks/v8/cmd/generate/secrets"
|
||||||
|
"github.com/zricethezav/gitleaks/v8/config"
|
||||||
|
)
|
||||||
|
|
||||||
|
func SendInBlueAPIToken() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
RuleID: "sendinblue-api-token",
|
||||||
|
Description: "Sendinblue API token",
|
||||||
|
Regex: generateUniqueTokenRegex(`xkeysib-[a-f0-9]{64}\-(?i)[a-z0-9]{16}`),
|
||||||
|
SecretGroup: 1,
|
||||||
|
Keywords: []string{
|
||||||
|
"xkeysib-",
|
||||||
|
},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("sendinblue", "xkeysib-"+secrets.NewSecret(hex("64"))+"-"+secrets.NewSecret(alphaNumeric("16"))),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
@@ -0,0 +1,25 @@
|
|||||||
|
package rules
|
||||||
|
|
||||||
|
import (
|
||||||
|
"github.com/zricethezav/gitleaks/v8/cmd/generate/secrets"
|
||||||
|
"github.com/zricethezav/gitleaks/v8/config"
|
||||||
|
)
|
||||||
|
|
||||||
|
func SentryAccessToken() *config.Rule {
|
||||||
|
// define rule
|
||||||
|
r := config.Rule{
|
||||||
|
RuleID: "sentry-access-token",
|
||||||
|
Description: "Sentry Access Token",
|
||||||
|
Regex: generateSemiGenericRegex([]string{"sentry"}, hex("64")),
|
||||||
|
SecretGroup: 1,
|
||||||
|
Keywords: []string{
|
||||||
|
"sentry",
|
||||||
|
},
|
||||||
|
}
|
||||||
|
|
||||||
|
// validate
|
||||||
|
tps := []string{
|
||||||
|
generateSampleSecret("sentry", secrets.NewSecret(hex("64"))),
|
||||||
|
}
|
||||||
|
return validate(r, tps, nil)
|
||||||
|
}
|
||||||
Loaded 100 of 1125 files, more files were not shown because too many files have changed in this diff.
Show more
Reference in new issue
Block a user