Skip to content

Allow small scans without erroring#839

Merged
phillip-stephens merged 3 commits intomainfrom
cap-max-threads-for-small-number-of-ips
Mar 25, 2024
Merged

Allow small scans without erroring#839
phillip-stephens merged 3 commits intomainfrom
cap-max-threads-for-small-number-of-ips

Conversation

@zakird
Copy link
Member

@zakird zakird commented Mar 23, 2024

If you try to scan only a very small number of IPs, this will immediately error because the number of CPU cores is larger than the number of targets. This caps the number of threads at the number of targets scanned.

@zakird zakird requested a review from phillip-stephens March 23, 2024 22:41
@zakird zakird added this to the ZMap 4.1 milestone Mar 23, 2024
Copy link
Contributor

@phillip-stephens phillip-stephens left a comment

Choose a reason for hiding this comment

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

LGTM, this will be a nice fix! Always forget to add the -T 1 when scanning a single IP, probably should have taken that to mean I should fix it 😄.

I'll merge after tests pass.

@phillip-stephens phillip-stephens merged commit 85cbd53 into main Mar 25, 2024
@phillip-stephens phillip-stephens deleted the cap-max-threads-for-small-number-of-ips branch March 25, 2024 17:23
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