Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

GitHub Detector Panic #2581

Closed
rgmz opened this issue Mar 16, 2024 · 0 comments · Fixed by #2583
Closed

GitHub Detector Panic #2581

rgmz opened this issue Mar 16, 2024 · 0 comments · Fixed by #2583
Labels

Comments

@rgmz
Copy link
Contributor

rgmz commented Mar 16, 2024

Please review the Community Note before submitting

TruffleHog Version

Trace Output

Noticed this while debugging #2580. Quickly writing it down.

2024-03-15T20:34:43-04:00       info-0  trufflehog      sentry flush failed     {"detector_worker_id": "SLf01", "timeout": 10}
2024-03-15T20:34:43-04:00       error   trufflehog      goroutine 1020 [running]:
runtime/debug.Stack()
        /home/gomez/sdk/go1.21.0/src/runtime/debug/stack.go:24 +0x5e
github.com/trufflesecurity/trufflehog/v3/pkg/common.Recover({0x3aa3f00, 0xc02f40c600})
        /tmp/trufflehog/pkg/common/recover.go:17 +0x58
panic({0x2ccc080?, 0x57a2450?})
        /home/gomez/sdk/go1.21.0/src/runtime/panic.go:914 +0x21f
github.com/trufflesecurity/trufflehog/v3/pkg/detectors/github/v1.Scanner.VerifyGithub({{{0x0, 0x0, 0x0}}}, {0x7f1fd8115358, 0xc02f40c600}, 0x40f4ba?, {0xc0278f93cf, 0x28})
        /tmp/trufflehog/pkg/detectors/github/v1/github_old.go:129 +0x3b8
github.com/trufflesecurity/trufflehog/v3/pkg/detectors/github/v2.Scanner.FromData({{{{0x0?, 0x3aa8dd0?, 0xc02f40c5a0?}}}}, {0x7f1fd8115358, 0xc02f40c600}, 0x1, {0xc021780000?, 0x3017140?, 0x0?})
        /tmp/trufflehog/pkg/detectors/github/v2/github.go:74 +0x385
github.com/trufflesecurity/trufflehog/v3/pkg/engine.(*Engine).detectChunk(0xc000662d80, {0x3aa3f00?, 0xc01f85f5f0?}, {{0x3a8cc40, 0xc0001206a8}, {{0xc021780000, 0x1dd, 0x3400}, {0x32541e6, 0x17}, ...}, ...})
        /tmp/trufflehog/pkg/engine/engine.go:808 +0x172
github.com/trufflesecurity/trufflehog/v3/pkg/engine.(*Engine).detectChunks(...)
        /tmp/trufflehog/pkg/engine/engine.go:795
github.com/trufflesecurity/trufflehog/v3/pkg/engine.(*Engine).startWorkers.func2()
        /tmp/trufflehog/pkg/engine/engine.go:504 +0x1f5
created by github.com/trufflesecurity/trufflehog/v3/pkg/engine.(*Engine).startWorkers in goroutine 1
        /tmp/trufflehog/pkg/engine/engine.go:500 +0x2af
        {"detector_worker_id": "59vPq", "timeout": 10, "recover": "runtime error: invalid memory address or nil pointer dereference", "error": "panic"}

Expected Behavior

Actual Behavior

Steps to Reproduce

  1. Go to '...'
  2. Click on '....'
  3. Scroll down to '....'
  4. See error

Environment

  • OS: [e.g. iOS]
  • Version [e.g. 22]

Additional Context

References

  • #0000
@rgmz rgmz added the bug label Mar 16, 2024
@rgmz rgmz mentioned this issue Mar 16, 2024
2 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Development

Successfully merging a pull request may close this issue.

1 participant