开发者

Mapping FTP and SFTP as Network Drive in Windows programmatically (Network redirector)

开发者 https://www.devze.com 2023-04-06 07:00 出处:网络
I have been assigned an internal task that i need to write a Windows App in C# that, when user input their username and password, Windows magically map the FTP or SFTP folder as a network drive.

I have been assigned an internal task that i need to write a Windows App in C# that, when user input their username and password, Windows magically map the FTP or SFTP folder as a network drive.

I have go through some research and seems "Network Redirector" is the answer of my question.

I am not very familiar with windows thingies, can anyone tell me i开发者_Go百科f this is the right direction? Or you have better clues?

Thanks.


You need to create a virtual file system backed by FTP or SFTP server. This can be done using our Callback File System library (FTP or SFTP part can be accomplished using our other product, SecureBlackbox). There also exists Dokan library, which attempts to mimic FUSE on Windows and create a virtual disk.

If you can go with an end-user solution, we implemented free SFTP Net Drive application that uses our Callback File System and maps SFTP server to a virtual drive.


WebDrive maps a network drive to FTP and SFTP servers and supports FTP over SSL. There is an API that lets you programmatically map and unmap the drive. Supported commands are detailed in the WebDrive help file. Go to the "Advanced Topics" section and look at the topics on "Automating Connections" as well as the "Scripting and Batch Files" section.


There is already a free tool called FtpUse for mapping FTP directories to a drive letter via command line. It does not support SFTP. Maybe this is simplest approach to mount a FTP resource programmatically.

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号