This commit is contained in:
Jian Cao 2024-10-30 16:06:36 -07:00
Родитель 45da2ae395
Коммит fbe7caa33e
1 изменённых файлов: 2 добавлений и 2 удалений

Просмотреть файл

@ -615,9 +615,9 @@ function New-LDAPSIdentitySource {
catch {
throw "The FQDN $($ResultUrl.Host) failed to do a reverse DNS lookup. $_"
}
# check whether a specific port (or range of ports) on a target host is open or closed
# check whether a specific port (or range of ports) on a target ip address is open or closed
try {
$Command = 'nc -nvz ' + $ResultUrl.Host + ' ' + $ResultUrl.Port
$Command = 'nc -nvz ' + $IPAddress + ' ' + $ResultUrl.Port
$SSHRes = Invoke-SSHCommand -Command $Command -SSHSession $SSH_Sessions['VC'].Value
if ($SSHRes.ExitStatus -ne 0) { throw "$SSHRes" }
}