using Powershell with harbour App to check SMB
Posted: Thu Jun 16, 2022 7:58 am
hi,
i want to "check" SMB Setting with Powershell
and want to get Result of Powershell
so how get Powershell Result into harbour App
i want to "check" SMB Setting with Powershell
Code: Select all
Get-SmbServerConfiguration i also want check which Port ( 139 / 445 ) is "listening"EnableOplocks : True
EnableSMB1Protocol : False
EnableSMB2Protocol : True
Code: Select all
Get-NetTCPConnection -LocalPort 139,445 -ea 0 | select Local*, Remote*, State, @{n="ProcessName";e={(Get-Process -Id $_.OwningProcess).ProcessName}} | ft -Autoif both NetBIOS over TCP/IP and directly hosted SMB over TCP/IP are available (that is, if ports 445 and 139 are both listening), Windows tries both options at the same time ...LocalAddress LocalPort RemoteAddress RemotePort State ProcessName
------------ --------- ------------- ---------- ----- -----------
:: 445 :: 0 Listen System
so how get Powershell Result into harbour App