sarif_simple.sarif 7.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302
  1. {
  2. "$schema": "https://json.schemastore.org/sarif-2.1.0.json",
  3. "version": "2.1.0",
  4. "runs": [
  5. {
  6. "tool": {
  7. "driver": {
  8. "name": "gitleaks",
  9. "semanticVersion": "v8.0.0",
  10. "informationUri": "https://github.com/gitleaks/gitleaks",
  11. "rules": [
  12. {
  13. "id": "aws-access-key",
  14. "name": "AWS Access Key",
  15. "shortDescription": {
  16. "text": "(A3T[A-Z0-9]|AKIA|AGPA|AIDA|AROA|AIPA|ANPA|ANVA|ASIA)[A-Z0-9]{16}"
  17. }
  18. },
  19. {
  20. "id": "aws-secret-key",
  21. "name": "AWS Secret Key",
  22. "shortDescription": {
  23. "text": "(?i)aws_(.{0,20})?=?.[\\'\\\"0-9a-zA-Z\\/+]{40}"
  24. }
  25. },
  26. {
  27. "id": "aws-mws-key",
  28. "name": "AWS MWS key",
  29. "shortDescription": {
  30. "text": "amzn\\.mws\\.[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}"
  31. }
  32. },
  33. {
  34. "id": "facebook-secret-key",
  35. "name": "Facebook Secret Key",
  36. "shortDescription": {
  37. "text": "(?i)(facebook|fb)(.{0,20})?(?-i)['\\\"][0-9a-f]{32}['\\\"]"
  38. }
  39. },
  40. {
  41. "id": "facebook-client-id",
  42. "name": "Facebook Client ID",
  43. "shortDescription": {
  44. "text": "(?i)(facebook|fb)(.{0,20})?['\\\"][0-9]{13,17}['\\\"]"
  45. }
  46. },
  47. {
  48. "id": "twitter-secret-key",
  49. "name": "Twitter Secret Key",
  50. "shortDescription": {
  51. "text": "(?i)twitter(.{0,20})?['\\\"][0-9a-z]{35,44}['\\\"]"
  52. }
  53. },
  54. {
  55. "id": "twitter-client-id",
  56. "name": "Twitter Client ID",
  57. "shortDescription": {
  58. "text": "(?i)twitter(.{0,20})?['\\\"][0-9a-z]{18,25}['\\\"]"
  59. }
  60. },
  61. {
  62. "id": "github-pat",
  63. "name": "Github Personal Access Token",
  64. "shortDescription": {
  65. "text": "ghp_[0-9a-zA-Z]{36}"
  66. }
  67. },
  68. {
  69. "id": "github-oauth",
  70. "name": "Github OAuth Access Token",
  71. "shortDescription": {
  72. "text": "gho_[0-9a-zA-Z]{36}"
  73. }
  74. },
  75. {
  76. "id": "github-app",
  77. "name": "Github App Token",
  78. "shortDescription": {
  79. "text": "(ghu|ghs)_[0-9a-zA-Z]{36}"
  80. }
  81. },
  82. {
  83. "id": "github-refresh",
  84. "name": "Github Refresh Token",
  85. "shortDescription": {
  86. "text": "ghr_[0-9a-zA-Z]{76}"
  87. }
  88. },
  89. {
  90. "id": "linkedin-client",
  91. "name": "LinkedIn Client ID",
  92. "shortDescription": {
  93. "text": "(?i)linkedin(.{0,20})?(?-i)[0-9a-z]{12}"
  94. }
  95. },
  96. {
  97. "id": "linkedin-secret",
  98. "name": "LinkedIn Secret Key",
  99. "shortDescription": {
  100. "text": "(?i)linkedin(.{0,20})?[0-9a-z]{16}"
  101. }
  102. },
  103. {
  104. "id": "slack",
  105. "name": "Slack",
  106. "shortDescription": {
  107. "text": "xox[baprs]-([0-9a-zA-Z]{10,48})?"
  108. }
  109. },
  110. {
  111. "id": "apkey",
  112. "name": "Asymmetric Private Key",
  113. "shortDescription": {
  114. "text": "-----BEGIN ((EC|PGP|DSA|RSA|OPENSSH) )?PRIVATE KEY( BLOCK)?-----"
  115. }
  116. },
  117. {
  118. "id": "google",
  119. "name": "Google (GCP) Service Account",
  120. "shortDescription": {
  121. "text": "\"type\": \"service_account\""
  122. }
  123. },
  124. {
  125. "id": "google",
  126. "name": "Google (GCP) Service Account",
  127. "shortDescription": {
  128. "text": "\"type\": \"service_account\""
  129. }
  130. },
  131. {
  132. "id": "heroku",
  133. "name": "Heroku API key",
  134. "shortDescription": {
  135. "text": "(?i)heroku(.{0,20})?[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}"
  136. }
  137. },
  138. {
  139. "id": "mailchimp",
  140. "name": "MailChimp API key",
  141. "shortDescription": {
  142. "text": "(?i)(mailchimp|mc)(.{0,20})?[0-9a-f]{32}-us[0-9]{1,2}"
  143. }
  144. },
  145. {
  146. "id": "mailgun",
  147. "name": "Mailgun API key",
  148. "shortDescription": {
  149. "text": "((?i)(mailgun|mg)(.{0,20})?)?key-[0-9a-z]{32}"
  150. }
  151. },
  152. {
  153. "id": "paypal",
  154. "name": "PayPal Braintree access token",
  155. "shortDescription": {
  156. "text": "access_token\\$production\\$[0-9a-z]{16}\\$[0-9a-f]{32}"
  157. }
  158. },
  159. {
  160. "id": "piacatic",
  161. "name": "Picatic API key",
  162. "shortDescription": {
  163. "text": "sk_live_[0-9a-z]{32}"
  164. }
  165. },
  166. {
  167. "id": "sendgrid",
  168. "name": "SendGrid API Key",
  169. "shortDescription": {
  170. "text": "SG\\.[\\w_]{16,32}\\.[\\w_]{16,64}"
  171. }
  172. },
  173. {
  174. "id": "sidekiq-secret",
  175. "name": "Sidekiq Secret",
  176. "shortDescription": {
  177. "text": "(?i)(?:BUNDLE_ENTERPRISE__CONTRIBSYS__COM|BUNDLE_GEMS__CONTRIBSYS__COM)(?:[0-9a-z\\-_\\t .]{0,20})(?:[\\s|']|[\\s|\"]){0,3}(?:=|\u003e|:=|\\|\\|:|\u003c=|=\u003e|:)(?:'|\\\"|\\s|=|\\x60){0,5}([a-f0-9]{8}:[a-f0-9]{8})(?:['|\\\"|\\n|\\r|\\s|\\x60|;]|$)"
  178. }
  179. },
  180. {
  181. "id": "sidekiq-sensitive-url",
  182. "name": "Sidekiq Sensitive URL",
  183. "shortDescription": {
  184. "text": "(?i)\\b(http(?:s??):\\/\\/)([a-f0-9]{8}:[a-f0-9]{8})@(?:gems.contribsys.com|enterprise.contribsys.com)(?:[\\/|\\#|\\?|:]|$)"
  185. }
  186. },
  187. {
  188. "id": "slack-webhook",
  189. "name": "Slack Webhook",
  190. "shortDescription": {
  191. "text": "https://hooks.slack.com/services/T[a-zA-Z0-9_]{8}/B[a-zA-Z0-9_]{8,12}/[a-zA-Z0-9_]{24}"
  192. }
  193. },
  194. {
  195. "id": "stripe",
  196. "name": "Stripe API key",
  197. "shortDescription": {
  198. "text": "(?i)stripe(.{0,20})?[sr]k_live_[0-9a-zA-Z]{24}"
  199. }
  200. },
  201. {
  202. "id": "square",
  203. "name": "Square access token",
  204. "shortDescription": {
  205. "text": "sq0atp-[0-9A-Za-z\\-_]{22}"
  206. }
  207. },
  208. {
  209. "id": "square-oauth",
  210. "name": "Square OAuth secret",
  211. "shortDescription": {
  212. "text": "sq0csp-[0-9A-Za-z\\-_]{43}"
  213. }
  214. },
  215. {
  216. "id": "twilio",
  217. "name": "Twilio API key",
  218. "shortDescription": {
  219. "text": "(?i)twilio(.{0,20})?SK[0-9a-f]{32}"
  220. }
  221. },
  222. {
  223. "id": "dynatrace",
  224. "name": "Dynatrace ttoken",
  225. "shortDescription": {
  226. "text": "dt0[a-zA-Z]{1}[0-9]{2}\\.[A-Z0-9]{24}\\.[A-Z0-9]{64}"
  227. }
  228. },
  229. {
  230. "id": "shopify",
  231. "name": "Shopify shared secret",
  232. "shortDescription": {
  233. "text": "shpss_[a-fA-F0-9]{32}"
  234. }
  235. },
  236. {
  237. "id": "shopify-access",
  238. "name": "Shopify access token",
  239. "shortDescription": {
  240. "text": "shpat_[a-fA-F0-9]{32}"
  241. }
  242. },
  243. {
  244. "id": "shopify-custom",
  245. "name": "Shopify custom app access token",
  246. "shortDescription": {
  247. "text": "shpca_[a-fA-F0-9]{32}"
  248. }
  249. },
  250. {
  251. "id": "shopify-private",
  252. "name": "Shopify private app access token",
  253. "shortDescription": {
  254. "text": "shppa_[a-fA-F0-9]{32}"
  255. }
  256. },
  257. {
  258. "id": "pypi",
  259. "name": "PyPI upload token",
  260. "shortDescription": {
  261. "text": "pypi-AgEIcHlwaS5vcmc[A-Za-z0-9-_]{50,1000}"
  262. }
  263. }
  264. ]
  265. }
  266. },
  267. "results": [
  268. {
  269. "message": {
  270. "text": "test-rule has detected secret for file auth.py at commit 0000000000000000."
  271. },
  272. "ruleId": "test-rule",
  273. "locations": [
  274. {
  275. "physicalLocation": {
  276. "artifactLocation": {
  277. "uri": "auth.py"
  278. },
  279. "region": {
  280. "startLine": 1,
  281. "startColumn": 1,
  282. "endLine": 2,
  283. "endColumn": 2,
  284. "snippet": {
  285. "text": "a secret"
  286. }
  287. }
  288. }
  289. }
  290. ],
  291. "partialFingerprints": {
  292. "commitSha": "0000000000000000",
  293. "email": "johndoe@gmail.com",
  294. "author": "John Doe",
  295. "date": "10-19-2003",
  296. "commitMessage": "opps"
  297. }
  298. }
  299. ]
  300. }
  301. ]
  302. }