ReadMe.txt
上传用户:guantou168
上传日期:2015-06-25
资源大小:74k
文件大小:3k
- Here is the skinny on this FTP server.
- This is the only true multiuser FTP server available on Planet Source Code. Some of the other examples did a fine job handling winsock commands but failed at providing multitasking. The result was while a file was being transfered every other activity was blocked. This code creates a separate thread for each logged on client and makes sure incoming requests are not blocked. Since the VB6 development environment can not handle multiple threads, you must compile the program and run the executable in order to take advantage to it's multithreaded capabilities. The threads also increased performance. For example initially on our 100 base T network file downloads averaged about 10k a second because a timer (set to 5 ms) was used to push the blocks out. On a separate thread we increased the transfer speed to up to 2000 k per second or better.
- Our need was for a basic file transfer engine and not necessarily a full blown ftp server. We have implemented most of the major ftp commands except for PASV. If anyone does this we would appreciate the code. We basically ignored most of the setup, security, logging, and user interface elements of the project because they weren't important to us. It really needs some work on the security interface(it doesn't work at all, you have to edit the burro.ini file directly to grant/deny privileges to a directory. Could also change it to give a client a home directory with access to anything lower in the directory structure, but nothing above his home directory. Another thing that would be important in a complete FTP server would be a process that keeps track of each clients idle time and logs off the laggards.
- I guess this project could qualified as advanced since it engulfs both winsocks and threads. It is not a tutorial and is not commented as a teaching tool. You are own your own and it is yours to do with as you want. No warranty, no support, no consulting. Basically the main thread listens on port 21, receives all messages for the server through the hidden form frmProcess, handles logon and disconnect functions directly and passes all other ftp commands to the object it creates (Jenny of class Balk) for each client. Each Jenny runs on a separate thread. Every command sent to the client object is delayed by a timer function that gives control back to the main thread before the command is executed. When the client logs off the object and it's thread are destroyed. All the testing done was with the ftp client that comes with Windows NT 4.0.
- Some of our names are whimiscal and unprofessional. We call the project Burro because initially the analogy was it's a beast of burden for moving packets around. The analogy still works because the code was stubborn to get working. After we got the threading working it still worked because it was really hauling ass. A Jenny is a type of burro. Goofy stuff so change it before you show it off to the a pointy haired boss.
- Have fun with this it is great way to learn about the nuances of winsocks and threads.
- This project modified Jay Bray's (another inspiration for the burro analogy) ftp server. Most of the multitasking code came straight out of VB Books Online.
- troyston@paperlessnow.com