List of questions
Related questions
Question 332 - PT0-002 discussion
Given the following code:
$p = (80, 110, 25)
$network = (192.168.0)
$range = 1 .. 254
$ErrorActionPreference = 'silentlycontinue'
$Foreach ($add in $range)
$Foreach ($x in $p)
{ {$ip = '{0} . {1} -F $network, $add'
If (Test-Connection -BufferSize 32 -Count 1 -quiet -ComputerName $ip)
{$socket = new-object System.Net. Sockets. TcpClient (&ip, $x)
If ($socket. Connected) { $ip $p open'
$socket. Close () }
}
}}
Which of the following tasks could be accomplished with the script?
A.
Reverse shell
B.
Ping sweep
C.
File download
D.
Port scan
Your answer:
0 comments
Sorted by
Leave a comment first