17.5. Handling FTP Transactions

It is a little known fact that System.Net.WebClient can handle FTP connections too. Most people mean HTTP transactions when they refer to the Web, and in a sense, that makes the WebClient name a bit misleading. The FTP support this class offers is limited in that it only supports passive FTP connection. Passive FTP mode is the default for many clients; it means that the client connects to the server and is then given a new address and port to connect to. Active mode, where the server connects back to the client, is not supported by the WebClient class. FTP is an ancient protocol, and it has been long known to have some security issues. For one thing, the credentials are sent with no encryption over the network, ...

Get Pro Windows PowerShell 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.