Once the listener is started, it's now ready to serve the client's request.įirst we shall discuss a little bit about FTP implementation. Then according to the settings, the FTP and HTTP listener will be started. As soon as the application starts first of all, the " Settings.dat" will be decrypted and loaded into memory. Let us now get deep into the implementation. Their are lot such petty interesting methods implemented in the application. This method uses a very silly way of encrypting data but it is more than enough to protect a file from manual access. The above method takes a byte array as input parameter and then processes each byte and then finally returns the encrypted byte array back. Adding exception to the firewall had been automated with the custom action in the installer.Ī method from InstallerService.cs is as follows:Ĭopy Code static byte Crypt(byte Buffer) So, for the application to work properly, the firewall must be configured to add an exception to the application. Generally when a listener is started, the firewall installed in the system blocks the application from receiving any incoming connections. Most of us know that for FTP server programming, we need to listen on some ports (21) using a listener class. Let us first see some of the basic and interesting methods. There is an another way which we can use instead of Windows service which is Windows Scheduled task, but the disadvantage with this is that the scheduled task might had been disabled in some systems and is not the fully automated way of doing things. Here you may ask why use a Windows Service as the application can be started directly? The reason is the Windows service starts as soon as Windows is started and any process started by a Windows service has full access over the system which enables access to all the files and folders. Once the application is started, the process ends by itself as there is no work to do with the process. Concept/Code Behind AdvancedFTPServerĪs soon windows starts up, a service named AdvFtpSvr starts and it executes FTP Server.exe from the installed path. This enables to allow others to use your system with restrictions for certain actions and specific path. You can add new Users by setting their root paths remotely. This enables control over the application from remote machines. But this provides a simple, user friendly web interface, where you can connect from a remote machine through a browser. But those applications do not provide the facility to control the server remotely and some provide this facility by installing the required software in the remote machine which may not be possible all the times. Their are lots of FTP server applications that are available free of cost. NET which enables full control over the application from remote locations. Now the FTP server starts and I will be able to access my files and folders from anywhere. So I can ask any body at home to switch on the system through a call. I always come across situations like I will be outside home and I may need some files or reference materials from my system.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |