how to see and close ports windows 10 code example
Example: how to shutdown port in windows
netstat -ano | findstr < Port Number >
taskkill /F /PID < Process Id >
netstat -ano | findstr < Port Number >
taskkill /F /PID < Process Id >