#PowerShell
به تعدا packets های ارسالی توجه کنید
مربوط به ویدیو آخر کانال
$ipAddress = "192.168.141.145" # Replace with the target IP address
$ports = @(80, 443, 21, 22, 53 , 389 , 2049 , 135 , 137 , 25 , 162 , 139 , 445 , 161, 500, 80 , 443) # Define the ports to scan
foreach ($port in $ports) {
$tcpClient = New-Object System.Net.Sockets.TcpClient
try {
$tcpClient.ConnectAsync($ipAddress, $port).Wait(100) # 100 ms timeout
if ($tcpClient.Connected) {
Write-Host "Port $port is OPEN on $ipAddress"
}
} catch {
Write-Host "Port $port is CLOSED or unreachable on $ipAddress"
} finally {
if ($tcpClient.Connected) {
$tcpClient.Close()
}
}
}
@RedTeamAPT
به تعدا packets های ارسالی توجه کنید
مربوط به ویدیو آخر کانال
$ipAddress = "192.168.141.145" # Replace with the target IP address
$ports = @(80, 443, 21, 22, 53 , 389 , 2049 , 135 , 137 , 25 , 162 , 139 , 445 , 161, 500, 80 , 443) # Define the ports to scan
foreach ($port in $ports) {
$tcpClient = New-Object System.Net.Sockets.TcpClient
try {
$tcpClient.ConnectAsync($ipAddress, $port).Wait(100) # 100 ms timeout
if ($tcpClient.Connected) {
Write-Host "Port $port is OPEN on $ipAddress"
}
} catch {
Write-Host "Port $port is CLOSED or unreachable on $ipAddress"
} finally {
if ($tcpClient.Connected) {
$tcpClient.Close()
}
}
}
@RedTeamAPT