Created
May 3, 2016 07:24
-
-
Save arebee/25dc6fa51375bc41c88d810ae5b98037 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Scans the 192.168.1.nnn hosts for http responses. | |
for ($i = 1; $i -ile 254; $i++) { | |
$testAddress = "192.168.1." + $i | |
$info = Test-NetConnection -ComputerName $testAddress -CommonTCPPort http -InformationLevel Quiet | |
if ($info -eq $true) | |
{ | |
write-host "$testAddress is listening on 80 for HTTP traffic" | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment