tcp connection script
This commit is contained in:
parent
e7a30f68b2
commit
6a9e572fe2
17
tcpcon.bat
Normal file
17
tcpcon.bat
Normal file
@ -0,0 +1,17 @@
|
||||
@echo off
|
||||
|
||||
:loop
|
||||
cls
|
||||
echo Monitoring TCP Connections...
|
||||
echo.
|
||||
set /p option="Enter 'a' for all TCP connections or 'e' for established connections: "
|
||||
if "%option%"=="a" (
|
||||
netstat -an | findstr /c:"TCP" /c:"Active Connections"
|
||||
) else if "%option%"=="e" (
|
||||
netstat -an | findstr /c:"ESTABLISHED"
|
||||
)else (
|
||||
echo Invalid option. Please try again.
|
||||
)
|
||||
timeout /t 5 > nul
|
||||
goto loop
|
||||
|
Loading…
Reference in New Issue
Block a user