Closed hackerpain closed 3 years ago
Describe the bug I couldn't investigate the cause yet, but the program panics and doesn't work while trying to scan CIDR ranges.
To Reproduce Steps to reproduce the behavior:
gowitness scan --cidr 204.15.20.0/22
Getting error -
panic: unable to redefine 'p' shorthand in "scan" flagset: it's already used for "ports" flag goroutine 1 [running]: github.com/spf13/pflag.(*FlagSet).AddFlag(0xc0001ba800, 0xc000239680) /root/go/src/github.com/spf13/pflag/flag.go:881 +0x6f0 github.com/spf13/pflag.(*FlagSet).AddFlagSet.func1(0xc000239680) /root/go/src/github.com/spf13/pflag/flag.go:894 +0xa8 github.com/spf13/pflag.(*FlagSet).VisitAll(0xc0001bad00, 0xc0000e5b28) /root/go/src/github.com/spf13/pflag/flag.go:297 +0x94 github.com/spf13/pflag.(*FlagSet).AddFlagSet(0xc0001ba800, 0xc0001bad00) /root/go/src/github.com/spf13/pflag/flag.go:892 +0x58 github.com/spf13/cobra.(*Command).mergePersistentFlags(0x1269140) /root/go/src/github.com/spf13/cobra/command.go:1642 +0x92 github.com/spf13/cobra.stripFlags(0xc00021a400, 0x2, 0x2, 0x1269140, 0x0, 0x2, 0x0) /root/go/src/github.com/spf13/cobra/command.go:562 +0x5a github.com/spf13/cobra.(*Command).Find.func1(0x1269140, 0xc00021a400, 0x2, 0x2, 0x4, 0xc00021a400, 0x2, 0x2) /root/go/src/github.com/spf13/cobra/command.go:621 +0x5c github.com/spf13/cobra.(*Command).Find.func1(0x1268ea0, 0xc0000be010, 0x3, 0x3, 0xac2e05, 0xd28480, 0xc0001d3000, 0x8) /root/go/src/github.com/spf13/cobra/command.go:629 +0x11e github.com/spf13/cobra.(*Command).Find(0x1268ea0, 0xc0000be010, 0x3, 0x3, 0x2, 0xc00025c000, 0x88, 0xc0001d0580, 0xc0000e5e30, 0xac27a5) ....
Expected behavior A clear and concise description of what you expected to happen.
Screenshots If applicable, add screenshots to help explain your problem.
Version Information:
Additional context Add any other context about the problem here.
Dupe of #72
Describe the bug I couldn't investigate the cause yet, but the program panics and doesn't work while trying to scan CIDR ranges.
To Reproduce Steps to reproduce the behavior:
gowitness scan --cidr 204.15.20.0/22
Getting error -
Expected behavior A clear and concise description of what you expected to happen.
Screenshots If applicable, add screenshots to help explain your problem.
Version Information:
Additional context Add any other context about the problem here.