Conversation
Co-authored-by: firefart <105281+firefart@users.noreply.github.com>
There was a problem hiding this comment.
🟡 Changes recommended
The updated success-handling logic invokes discovery callbacks before the discoverOnSuccess guard (then discards results), which is inconsistent with the surrounding control flow and comment intent.
Once you've addressed the issues Copilot identified, you can request another Copilot review.
Pull request overview
This PR updates Gobuster’s user-facing documentation and tweaks the core discovery-on-success flow in libgobuster, alongside a small CLI validation error-message improvement.
Changes:
- Documented pattern replacement, discover-pattern generation, and wordlist offset usage in the README.
- Adjusted how success-triggered “discovery” words are computed/handled in the main processing loop.
- Refined the
wordlist-offsetvalidation error message for clarity.
File summaries
| File | Description |
|---|---|
| README.md | Adds examples for --pattern, --discover-pattern, and --wordlist-offset usage. |
| libgobuster/libgobuster.go | Modifies the success-handling branch to change when discovery callbacks/pattern generation are invoked. |
| cli/options.go | Updates the wordlist-offset negative-value error message wording. |
Review details
- Files reviewed: 3/3 changed files
- Comments generated: 1
- Review effort level: Lite
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
| // Call the success callback for every successful result so generated | ||
| // recursive targets are still processed even when the originating guess | ||
| // was created with discoverOnSuccess disabled. | ||
| discoverWords := g.plugin.AdditionalSuccessWords(successGuess.word) | ||
| patternDiscoverWords := g.processDiscoverPatterns(successGuess.word) | ||
| if !successGuess.discoverOnSuccess { | ||
| break | ||
| } |
There was a problem hiding this comment.
Addressed in 4bd5cbf: the discoverOnSuccess guard now precedes both discovery callbacks.
Co-authored-by: firefart <105281+firefart@users.noreply.github.com>
Co-authored-by: firefart <105281+firefart@users.noreply.github.com>
Pull request created by AI Agent