Kevin-Robertson / Inveigh

.NET IPv4/IPv6 machine-in-the-middle tool for penetration testers
BSD 3-Clause "New" or "Revised" License
2.52k stars 440 forks source link

Shows "HTTP Capture Disabled Due To In Use Port 80" when actually listening on Port 8081 #8

Closed 6cyril closed 7 years ago

6cyril commented 7 years ago

Good day,

As titled, Invoke-Inveigh shows port 80 is listening while there is another service listening on port 0.0.0.0:8081. It happens to be lines on netstat that matches "0.0.0.0:8081" with searchstring "0.0.0.0:80". Same issue potentially appears in other netstat commands in the same project.

On line 555 of Inveigh.ps1 $HTTP_port_check = netstat -anp TCP | findstr 0.0.0.0:80

Suggest to update as below to grep the space at the end with findstr: netstat -anp TCP | findstr LISTENING | findstr /C:":80 " or netstat -anp TCP | findstr LISTENING | findstr /C:"0.0.0.0:80 "

Thanks Cyril

Kevin-Robertson commented 7 years ago

Thanks!, I'll get the checks fixed tonight.

Kevin-Robertson commented 7 years ago

I added in your netstat fixes. I also added the StartupChecks parameter to allow disabling all checks in the event that any of them get in the way. Thanks again!