forked from kellymusk/Aframp-backend
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path.gitleaks.toml
More file actions
59 lines (51 loc) · 1.49 KB
/
Copy path.gitleaks.toml
File metadata and controls
59 lines (51 loc) · 1.49 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
# Gitleaks configuration for Aframp backend secrets detection.
# Scans all committed code and git history for accidentally committed secrets.
title = "Aframp Backend Gitleaks Config"
[extend]
# Extend the default gitleaks ruleset
useDefault = true
[[rules]]
id = "aframp-database-url"
description = "Aframp database connection string with credentials"
regex = '''postgres://[^:]+:[^@]+@'''
tags = ["database", "credentials"]
severity = "CRITICAL"
[[rules]]
id = "aframp-redis-url"
description = "Redis connection string with credentials"
regex = '''redis://:[^@]+@'''
tags = ["cache", "credentials"]
severity = "HIGH"
[[rules]]
id = "aframp-stellar-secret"
description = "Stellar account secret key (starts with S)"
regex = '''S[A-Z2-7]{55}'''
tags = ["blockchain", "private-key"]
severity = "CRITICAL"
[[rules]]
id = "aframp-jwt-secret"
description = "JWT signing secret"
regex = '''(?i)(jwt[_-]?secret|jwt[_-]?key)\s*[=:]\s*["\']?[A-Za-z0-9+/]{32,}'''
tags = ["auth", "secret"]
severity = "CRITICAL"
[[rules]]
id = "aframp-api-key"
description = "Aframp API key pattern"
regex = '''afr_[a-zA-Z0-9]{32,}'''
tags = ["api-key"]
severity = "HIGH"
[allowlist]
description = "Allowlisted patterns that are not real secrets"
regexes = [
# Test/example values
'''postgres://postgres:postgres@localhost''',
'''redis://127\.0\.0\.1''',
# Placeholder values in documentation
'''your[_-]?secret[_-]?here''',
'''<your[_-]?api[_-]?key>''',
]
paths = [
".env.example",
"docs/",
"examples/",
]