-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathprovn.yml
More file actions
145 lines (133 loc) · 4.62 KB
/
Copy pathprovn.yml
File metadata and controls
145 lines (133 loc) · 4.62 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
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
# provn.yml — Provn Security Policy
# Place in repo root to configure scanning behavior
version: "1.0"
# enforce: block commits with threats
# warn: show warnings but allow commits
# shadow: log only, never block (testing mode)
mode: enforce
# Scan only these file extensions (empty = scan all)
include_extensions: []
# Skip these directories
exclude_dirs:
- node_modules
- .git
- dist
- build
- __pycache__
- .venv
- target
# Skip these files
exclude_files:
- "*.lock"
- "*.min.js"
- "*.map"
# Risk tier configuration
# T0: Critical — hard block, no bypass allowed
# T1: High — block, bypass with signed reason
# T2: Medium — warn, developer decides
# T3: Low — log only
tiers:
T0:
block: true
bypass_allowed: false
examples: "Private keys, database passwords, cloud credentials"
T1:
block: true
bypass_allowed: true
approvers_required: 0
examples: "API keys, system prompts, model configs"
T2:
block: false
warn: true
examples: "High-entropy strings, potential IP patterns"
T3:
block: false
warn: false
log: true
examples: "Informational findings, low-confidence matches"
# ─────────────────────────────────────────────────────────────────────────────
# Remote allowlist
# Only allow commits when the git remote origin matches one of these patterns.
# Supports * wildcard. Empty list = allow all remotes (default).
# Uncomment and customise to prevent source code from leaving your org.
# ─────────────────────────────────────────────────────────────────────────────
# allowed_remotes:
# - "git@github.com:mycompany/*"
# - "https://github.com/mycompany/*"
# - "git@gitlab.mycompany.com:*"
# ─────────────────────────────────────────────────────────────────────────────
# Layer configuration
layers:
regex:
enabled: true
# Uses built-in Gitleaks-compatible patterns + any custom_patterns below
# Custom user-defined patterns — checked after built-in patterns.
# Add regex rules to catch proprietary code, internal imports, copyright violations, etc.
# Uncomment examples below or add your own.
# custom_patterns:
# # Catch internal package imports leaking into public repos
# - name: internal_import
# pattern: 'from corp_internal\.'
# tier: T1
# confidence: 0.90
# description: "Internal package reference — do not commit to public repos"
#
# # Catch copyright / confidential markers
# - name: confidential_header
# pattern: '(?i)CONFIDENTIAL|PROPRIETARY|DO NOT DISTRIBUTE'
# tier: T1
# confidence: 0.85
# description: "File marked confidential — review before committing"
#
# # Catch hardcoded model configs (like the Anthropic/claw-code incident)
# - name: model_config_leak
# pattern: '(?i)(system_prompt|base_url|model_id)\s*=\s*["\x27][^"x27]{40,}'
# tier: T1
# confidence: 0.80
# description: "Possible model configuration leak"
entropy:
enabled: true
threshold: 4.5
min_length: 20
ast:
enabled: true
languages: ["python", "typescript", "javascript"]
# Variables tracked for taint analysis
sensitive_vars:
- system_prompt
- api_key
- secret
- password
- token
- private_key
- credentials
semantic:
enabled: true
# Only triggered when Layer 1/2 confidence is ambiguous (0.4-0.8)
model: "provn-gemma4-e2b-q4km.gguf"
endpoint: "http://localhost:8080"
timeout_ms: 2000
# If model unavailable, fall back to Layer 1/2 result
fallback: "layer1"
# Auto-redaction
redaction:
enabled: true
strategy: "token_replacement"
# Show preview before applying
preview: true
# Prefix for replacement tokens
token_prefix: "PROVN_REDACTED_"
# Audit logging
audit:
enabled: true
path: ".provn/audit.jsonl"
# HMAC key for chain integrity (auto-generated on first run)
hmac_key_path: ".provn/hmac.key"
# Ed25519 key for bypass signing
signing_key_path: ".provn/signing.key"
# Inline annotations
annotations:
# Add "# provn:allow" to skip a specific line
allow_comment: "provn:allow"
# Add "# provn:skip-file" to skip entire file
skip_file_comment: "provn:skip-file"