gitleaks.toml 2.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687
  1. title = "sample gitleaks config"
  2. # This is a sample config file for gitleaks. You can configure gitleaks what to search for and what to whitelist.
  3. # The output you are seeing here is the default gitleaks config. If GITLEAKS_CONFIG environment variable
  4. # is set, gitleaks will load configurations from that path. If option --config-path is set, gitleaks will load
  5. # configurations from that path. Gitleaks does not whitelist anything by default.
  6. [[rules]]
  7. description = "AWS Key"
  8. regex = '''AKIA[0-9A-Z]{16}'''
  9. tags = ["key", "AWS"]
  10. [[rules]]
  11. description = "PKCS8"
  12. regex = '''-----BEGIN PRIVATE KEY-----'''
  13. tags = ["key", "PKCS8"]
  14. [[rules]]
  15. description = "RSA"
  16. regex = '''-----BEGIN RSA PRIVATE KEY-----'''
  17. tags = ["key", "RSA"]
  18. [[rules]]
  19. description = "SSH"
  20. regex = '''-----BEGIN OPENSSH PRIVATE KEY-----'''
  21. tags = ["key", "SSH"]
  22. [[rules]]
  23. description = "PGP"
  24. regex = '''-----BEGIN PGP PRIVATE KEY BLOCK-----'''
  25. tags = ["key", "PGP"]
  26. [[rules]]
  27. description = "Facebook"
  28. regex = '''(?i)facebook(.{0,4})?['\"][0-9a-f]{32}['\"]'''
  29. tags = ["key", "Facebook"]
  30. [[rules]]
  31. description = "Twitter"
  32. regex = '''(?i)twitter(.{0,4})?['\"][0-9a-zA-Z]{35,44}['\"]'''
  33. tags = ["key", "Twitter"]
  34. [[rules]]
  35. description = "Github"
  36. regex = '''(?i)github(.{0,4})?['\"][0-9a-zA-Z]{35,40}['\"]'''
  37. tags = ["key", "Github"]
  38. [[rules]]
  39. description = "Slack"
  40. regex = '''xox[baprs]-([0-9a-zA-Z]{10,48})?'''
  41. tags = ["key", "Slack"]
  42. [whitelist]
  43. files = [
  44. "(.*?)(jpg|gif|doc|pdf|bin)$"
  45. ]
  46. #commits = [
  47. # "whitelisted-commit1",
  48. # "whitelisted-commit2",
  49. #]
  50. #repos = [
  51. # "whitelisted-repo"
  52. #]
  53. # Additional Examples
  54. # [[rules]]
  55. # description = "Generic Key"
  56. # regex = '''(?i)key(.{0,6})?(:|=|=>|:=)'''
  57. # entropies = ["4.1-4.3"]
  58. # entropyROI = "line"
  59. # tags = ["key"]
  60. # severity = "8"
  61. #
  62. # [[rules]]
  63. # description = "Generic Key"
  64. # regex = '''(?i)key(.{0,6})?(:|=|=>|:=)'''
  65. # entropies = ["4.1-4.3"]
  66. # filetypes = [".gee"]
  67. # entropyROI = "line"
  68. # tags = ["key"]
  69. # severity = "medium"
  70. #
  71. # [[rules]]
  72. # description = "Any go file"
  73. # filetypes = [".go"]
  74. # tags = ["go files"]
  75. # severity = "low"