Closed concaf closed 8 years ago
Since nc -z is not being supported anymore, this can be implemented using nmap.
nc -z
nmap
nmap -Pn ...
nmap ... -oX ...
xmllint ...
state=
Then using the return value, the code proceeds.
Sorry @containscafeine but @dustymabe implemented curl which would be a bit easier :(
Since
nc -z
is not being supported anymore, this can be implemented usingnmap
.nmap -Pn ...
is scanning for the open portsnmap ... -oX ...
outputs in XML formatxmllint ...
parses the XML output fromnmap
and shows shows the output ofstate=
from ` ...Then using the return value, the code proceeds.