Skip to content

Added --checks arg#34

Open
kz0ltan wants to merge 7 commits into
cisagov:developfrom
kz0ltan:develop
Open

Added --checks arg#34
kz0ltan wants to merge 7 commits into
cisagov:developfrom
kz0ltan:develop

Conversation

@kz0ltan

@kz0ltan kz0ltan commented Nov 20, 2021

Copy link
Copy Markdown

Added --checks arg

Description

--checks can be used to select check methods to use for cdn detection

💭 Motivation and context

Certain checks can slow the detection process down unnecessarily (depending on the pipeline of course). This way, those can be disabled.

🧪 Testing

Just use the --checks argument to select the check methods needed:
--checks= Select detection types; possible values:
cname (c), HTTP headers (h), nameservers (n),
whois data (w). Default: "chnw"

✅ Checklist

  • This PR has an informative and human-readable title.
  • Changes are limited to a single goal - eschew scope creep!
  • All relevant type-of-change labels have been added.
  • I have read the CONTRIBUTING document.
  • These code changes follow cisagov code standards.
  • All relevant repo and/or project documentation has been updated
    to reflect the changes in this PR.
  • Tests have been added and/or modified to cover the changes in this PR.
  • All new and existing tests pass.

…rs; collect all headers from previous responses, before redirections

@Pascal-0x90 Pascal-0x90 left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Along with my comments, this branch also needs to be updated to merge in the current state of cisagov:develop branch.


def ip(self, dom: Domain) -> List[int]:
"""Determine IP addresses the domain resolves to."""
dom_list: List[str] = [dom.url, "www." + dom.url]

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

My main motivation was to add www. for domains which don't directly answer to their domain name but instead they will listen to www.domain.com. Is there a reason why you wanted to remove "www." ?

I have also thought about pairing in a light subdomain enumerator using like google but I think that's too big of a scope.

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

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

Adding www might add another host; I expect the user to provide all the hosts they want to test as an input, and avoid adding hostnames implicitly (without the user actually knowing about it).
I agree, subdomain enumeration is out of scope for this tool.

Comment thread src/findcdn/cdnEngine/detectCDN/cdn_check.py
Comment thread src/findcdn/cdnEngine/detectCDN/cdn_check.py
@kz0ltan

kz0ltan commented Dec 3, 2023

Copy link
Copy Markdown
Author

I'm not sure what the type-of-change labels mean in the checklist, could you point me to an explanation?

Should I wait for this instead of messing with this pull request?

@kz0ltan kz0ltan requested a review from Pascal-0x90 December 3, 2023 06:29
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.

2 participants