Chapter 4. TCP port communications with PowerShell
Boe Prox
PowerShell can be a powerful network troubleshooting tool thanks to its reach back into the .NET framework. In this chapter I’ll take you through some of the more useful .NET classes that you can harness to help with your network troubleshooting and with building some fun scripts. By the end of the chapter you’ll know how to create a port scanner to check for open ports on your network, send and receive data between ports, create formatted packets to send a Lightweight Directory Access Protocol (LDAP) request to a domain controller, and process the return packets to emulate the same type of output from another command-line interface (CLI) tool, portqry.exe. You’ll also learn about creating ...
Get PowerShell Deep Dives now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.