Skip to content

Conversation

Vinayakp2001
Copy link

@Vinayakp2001 Vinayakp2001 commented Oct 7, 2025

Introduces -ais/--all-input-scope flag that treats all input targets as explicit scope roots for the entire crawling session.

Features:

  • Supports CLI, file, and stdin input methods
  • Prevents conflicts with -fs flag (validation error)
  • Takes precedence over -ns flag when both specified
  • Compatible with existing -cs/-cos regex filters
  • Maintains backward compatibility

Fixes #1383

Summary by CodeRabbit

  • New Features
    • Added --js-interactions (-jsi) to click JavaScript-enabled elements and uncover hidden URLs during crawling.
    • Added --all-input-scope (-ais) to treat all input targets as explicit scope roots for the entire session.
    • Added validation and messaging: prevents combining -ais with non-“rdn” field scope; when both -ais and no-scope are set, -ais takes precedence with an informational notice.

Introduces -ais/--all-input-scope flag that treats all input targets
as explicit scope roots for the entire crawling session.

Features:
- Supports CLI, file, and stdin input methods
- Prevents conflicts with -fs flag (validation error)
- Takes precedence over -ns flag when both specified
- Compatible with existing -cs/-cos regex filters
- Maintains backward compatibility

Fixes projectdiscovery#1383
Copy link
Contributor

coderabbitai bot commented Oct 7, 2025

Pre-merge checks and finishing touches

❌ Failed checks (1 warning)
Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 50.00% which is insufficient. The required threshold is 80.00%. You can run @coderabbitai generate docstrings to improve docstring coverage.
✅ Passed checks (2 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title Check ✅ Passed The title succinctly highlights the primary change of the pull request by naming the new “-ais” flag and its purpose in enabling all-input-scope functionality, directly reflecting the PR’s main objective without extraneous detail.
✨ Finishing touches
  • 📝 Generate docstrings
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 0

🧹 Nitpick comments (1)
internal/runner/options.go (1)

28-38: Document rationale for restricting -ais to the default -fs="rdn"
No existing comments or documentation explain why -ais cannot be combined with custom field‐scopes. If intentional, add a brief explanation in internal/runner/options.go and the README.

📜 Review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 00f90fb and e4c68b5.

📒 Files selected for processing (3)
  • cmd/katana/main.go (1 hunks)
  • internal/runner/options.go (1 hunks)
  • pkg/types/options.go (2 hunks)
🔇 Additional comments (4)
pkg/types/options.go (2)

35-36: LGTM!

The AllInputScope field addition is clear and aligns with the PR objectives for implementing the -ais flag functionality.


151-152: Verify if JavaScriptInteractions belongs in this PR.

The JavaScriptInteractions field is not mentioned in the PR summary (title: "Add -ais flag for all-input-scope functionality"). This suggests it may be unrelated scope creep or part of a different feature.

Please confirm whether this field should be included in PR #1433 or if it belongs to a separate change.

cmd/katana/main.go (2)

195-195: LGTM!

The -ais/--all-input-scope flag is correctly:

  • Placed in the Scope group
  • Mapped to options.AllInputScope
  • Documented with a clear description matching the PR objectives

187-187: Verify if js-interactions flag belongs in this PR.

Similar to the field addition in pkg/types/options.go, the --js-interactions flag is not mentioned in PR #1433's summary. This appears to be unrelated to the -ais flag functionality.

Please confirm whether this flag should be included in this PR or moved to a separate pull request focused on JavaScript interaction functionality.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant