Skip to content

Making pcap handlers shared globally#946

Merged
ehsandeep merged 48 commits intodevfrom
feat-937-singleton
Mar 4, 2024
Merged

Making pcap handlers shared globally#946
ehsandeep merged 48 commits intodevfrom
feat-937-singleton

Conversation

@Mzack9999
Copy link
Copy Markdown
Member

@Mzack9999 Mzack9999 commented Jan 29, 2024

This PR implements the following changes:

@Mzack9999 Mzack9999 added the Type: Enhancement Most issues will probably ask for additions or changes. label Jan 29, 2024
@Mzack9999 Mzack9999 self-assigned this Jan 29, 2024
@Mzack9999 Mzack9999 marked this pull request as ready for review February 1, 2024 20:19
@Mzack9999
Copy link
Copy Markdown
Member Author

Mzack9999 commented Feb 2, 2024

  • Filter out traffic according to -iv
  • Change output behavior to stdout to print from new OnReceive callback instead of OnResponse (real-time results)

Copy link
Copy Markdown
Member

@ehsandeep ehsandeep left a comment

Choose a reason for hiding this comment

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

  • Source IP being scanned randomly
  • Panic upon CLT + C press
cat h1.txt
3d.hackerone.com
a.ns.hackerone.com
api.hackerone.com
b.ns.hackerone.com
design.hackerone.com
docs.hackerone.com
email.hackerone.com
events.hackerone.com
go.hackerone.com
gslink.hackerone.com
info.hackerone.com
links.hackerone.com
mta-sts.hackerone.com
mta-sts.forwarding.hackerone.com
mta-sts.managed.hackerone.com
ns.hackerone.com
o1.email.hackerone.com
o2.email.hackerone.com
o3.email.hackerone.com
resources.hackerone.com
support.hackerone.com
www.hackerone.com

sudo ./naabu -l h1.txt
sudo ./naabu -l h1.txt 

                  __
  ___  ___  ___ _/ /  __ __
 / _ \/ _ \/ _ \/ _ \/ // /
/_//_/\_,_/\_,_/_.__/\_,_/

        projectdiscovery.io

[INF] Current naabu version 2.2.1 (latest)
[INF] Running host discovery scan
[INF] Running SYN scan with root privileges
192.168.1.100:8888
a.ns.hackerone.com:53
api.hackerone.com:8443
docs.hackerone.com:8443
www.hackerone.com:8443
docs.hackerone.com:8080
192.168.1.100:8080
192.168.1.100:5432
192.168.1.100:8888
gslink.hackerone.com:80
gslink.hackerone.com:443
a.ns.hackerone.com:8080
api.hackerone.com:8443
a.ns.hackerone.com:53
a.ns.hackerone.com:8443
b.ns.hackerone.com:53
docs.hackerone.com:8443
www.hackerone.com:8443
docs.hackerone.com:8080
support.hackerone.com:80
support.hackerone.com:443
resources.hackerone.com:80
resources.hackerone.com:443
192.168.1.100:5000
192.168.1.100:8080
192.168.1.100:5432
api.hackerone.com:8080
a.ns.hackerone.com:8080
www.hackerone.com:8080
a.ns.hackerone.com:8443
b.ns.hackerone.com:8443
b.ns.hackerone.com:8080
b.ns.hackerone.com:53
192.168.1.100:5000
192.168.1.100:53
192.168.1.100:5000
192.168.1.100:8888
api.hackerone.com:8080
b.ns.hackerone.com:8443
www.hackerone.com:8080
b.ns.hackerone.com:8080
192.168.1.100:8080
192.168.1.100:5432
192.168.1.100:53
192.168.1.100:53
192.168.1.100:8080
192.168.1.100:5432
192.168.1.100:5000
gslink.hackerone.com:80
gslink.hackerone.com:443
support.hackerone.com:80
support.hackerone.com:443
resources.hackerone.com:80
resources.hackerone.com:443
192.168.1.100:53
192.168.1.100:8888
192.168.1.100:8888
192.168.1.100:8080
192.168.1.100:5000
192.168.1.100:53
192.168.1.100:5432
192.168.1.100:5000
192.168.1.100:5432
192.168.1.100:8888
192.168.1.100:8080
192.168.1.100:53
[INF] Found 3 ports on host a.ns.hackerone.com (162.159.0.31)
[INF] Found 2 ports on host api.hackerone.com (104.16.100.52)
[INF] Found 3 ports on host b.ns.hackerone.com (162.159.1.31)
[INF] Found 2 ports on host www.hackerone.com (104.16.99.52)
[INF] Found 2 ports on host gslink.hackerone.com (18.66.63.51)
[INF] Found 5 ports on host 192.168.1.100 (192.168.1.100)
[INF] Found 2 ports on host docs.hackerone.com (172.64.151.42)
[INF] Found 2 ports on host support.hackerone.com (44.197.122.152)
[INF] Found 2 ports on host resources.hackerone.com (3.98.63.202)
panic with CTRL+C
./naabu -l h1.txt 

                  __
  ___  ___  ___ _/ /  __ __
 / _ \/ _ \/ _ \/ _ \/ // /
/_//_/\_,_/\_,_/_.__/\_,_/

        projectdiscovery.io

[INF] Current naabu version 2.2.1 (latest)
cc^C[INF] CTRL+C pressed: Exiting
[INF] Creating resume file: /Users/geekboy/.config/naabu/resume.cfg
panic: runtime error: invalid memory address or nil pointer dereference
[signal SIGSEGV: segmentation violation code=0x2 addr=0x28 pc=0x10520a278]

goroutine 23 [running]:
github.com/projectdiscovery/ratelimit.(*Limiter).Stop(...)
    /Users/geekboy/go/pkg/mod/github.com/projectdiscovery/ratelimit@v0.0.25/ratelimit.go:85
github.com/projectdiscovery/naabu/v2/pkg/runner.(*Runner).Close(0x1400009dda0)
    /Users/geekboy/Github/naabu/v2/pkg/runner/runner.go:650 +0x88
main.main.func1()
    /Users/geekboy/Github/naabu/v2/cmd/naabu/main.go:35 +0x44
created by main.main in goroutine 1
    /Users/geekboy/Github/naabu/v2/cmd/naabu/main.go:24 +0x114

@Mzack9999 Mzack9999 requested a review from ehsandeep February 26, 2024 12:52
Copy link
Copy Markdown
Member

@ehsandeep ehsandeep left a comment

Choose a reason for hiding this comment

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

creating another follow-up issue for known improvements

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

Labels

Type: Enhancement Most issues will probably ask for additions or changes.

Projects

None yet

2 participants