Skip to content

Commit 4ab50eb

Browse files
committed
feat: integrate tok secret detection into hawk's pipeline via direct import
hawk now calls tok.DefaultSecretDetector().RedactSecrets() in the post-response pipeline, adding tok's 27 secret patterns on top of hawk's own OutputRedactor patterns. Double-layer secret protection.
1 parent 73881ea commit 4ab50eb

1 file changed

Lines changed: 3 additions & 1 deletion

File tree

engine/integration.go

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ import (
77
"time"
88

99
"github.com/GrayCodeAI/eyrie/client"
10+
"github.com/GrayCodeAI/tok"
1011
)
1112

1213
// ---------------------------------------------------------------------------
@@ -349,8 +350,9 @@ func (p *IntegrationPipeline) PostResponse(response string, messages []client.Ey
349350
// 3. Detect file mentions
350351
result.MentionedFiles = p.FileMentionDetector.DetectMentions(result.FormattedResponse)
351352

352-
// 4. Redact secrets from output
353+
// 4. Redact secrets from output (hawk's patterns + tok's 27 patterns)
353354
result.FormattedResponse = p.OutputRedactor.Redact(result.FormattedResponse)
355+
result.FormattedResponse = tok.DefaultSecretDetector().RedactSecrets(result.FormattedResponse)
354356

355357
// 5. Update timeline
356358
p.Timeline.AddEvent("response", "", map[string]string{

0 commit comments

Comments
 (0)