-
Notifications
You must be signed in to change notification settings - Fork 1.5k
add RSECloud #1604
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
add RSECloud #1604
Conversation
WalkthroughThe changes introduce a new passive subdomain enumeration source, Changes
Sequence Diagram(s)sequenceDiagram
participant User
participant PassiveSources
participant RSECloudSource
participant RSECloudAPI
User->>PassiveSources: Enumerate subdomains for domain
PassiveSources->>RSECloudSource: Run(domain, session)
loop For each mode ("active", "passive")
RSECloudSource->>RSECloudAPI: GET /api/v1/subdomains/{mode}?domain={domain}&page={n}
RSECloudAPI-->>RSECloudSource: JSON response (subdomains, pagination info)
RSECloudSource->>RSECloudSource: Emit subdomains, handle pagination
end
RSECloudSource-->>PassiveSources: Results channel (subdomains, errors)
Assessment against linked issues
Poem
📜 Recent review detailsConfiguration used: CodeRabbit UI 📒 Files selected for processing (1)
🚧 Files skipped from review as they are similar to previous changes (1)
⏰ Context from checks skipped due to timeout of 90000ms (1)
✨ Finishing Touches
🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
SupportNeed help? Create a ticket on our support page for assistance with any issues or questions. Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 2
🧹 Nitpick comments (5)
v2/pkg/passive/sources.go (2)
42-43: Keep import list alphabetically sorted to avoid noisy diffs laterThe new
rsecloudimport breaks the existing alphabetical ordering of the source imports. Consider re-ordering to maintain a deterministic diff footprint.
85-86: Registration order is drifting from α-order; align for easier grepping
rsecloudis inserted mid-block; keepingAllSourcesalphabetically sorted helps quick visual scans and reduces merge conflicts with parallel PRs touching the list.- &rapiddns.Source{}, - &redhuntlabs.Source{}, - // &riddler.Source{}, // failing due to cloudfront protection - &robtex.Source{}, - &rsecloud.Source{}, - &securitytrails.Source{}, + &rapiddns.Source{}, + &redhuntlabs.Source{}, + // &riddler.Source{}, // failing due to cloudfront protection + &robtex.Source{}, + &rsecloud.Source{}, + &securitytrails.Source{},v2/pkg/subscraping/sources/rsecloud/rsecloud.go (3)
42-48:IsDefault()==truebut silently skipped when no key – risk of confusing UXBy default this source is selected, yet if no API key is supplied you just set
skipped=trueand return.
Users might wonder why the default set yields fewer results without any warning. Consider:
- emitting an explicit warning via
gologger(consistent with other key-based sources), or- setting
IsDefault()tofalse.
48-54:Content-Typeheader is superfluous for a GET requestThe RSECloud API does not require a body for these GET calls; you can drop the header to avoid misleading proxy/debug traces.
71-74: Potential duplicate emissions between “active” and “passive” datasetsA subdomain may appear in both endpoints, leading to duplicate results downstream. Consider de-duplication (e.g., a
map[string]struct{}) before pushing to the channel to keep result streams lean.
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (3)
v2/pkg/passive/sources.go(2 hunks)v2/pkg/passive/sources_test.go(2 hunks)v2/pkg/subscraping/sources/rsecloud/rsecloud.go(1 hunks)
🧰 Additional context used
🧬 Code Graph Analysis (1)
v2/pkg/subscraping/sources/rsecloud/rsecloud.go (2)
v2/pkg/subscraping/types.go (2)
Session(71-78)Statistics(29-34)v2/pkg/subscraping/utils.go (1)
PickRandom(12-20)
⏰ Context from checks skipped due to timeout of 90000ms (2)
- GitHub Check: Analyze (go)
- GitHub Check: release-test
🔇 Additional comments (1)
v2/pkg/passive/sources_test.go (1)
41-45: Good test updateThe expectations correctly include the new source; thanks for maintaining coverage.
|
LGTM ! |
closes #1565
Summary by CodeRabbit