FileZilla source code analysis 1

Source: Internet
Author: User
Tags filezilla filezilla ftp filezilla ftp client

FileZillaIt is a fast and reliable FTP client and server-side open source code program with a variety of features and intuitive interfaces. This article analyzes the source code of FileZilla.

FileZilla is an open-source FTP server written in C ++. By analyzing its source code, you can master the design of C ++ network programming and high-concurrency servers.

FileZilla is a project on the and the home page is the article we want to study is: FileZilla Server 0_9_18, in fact FileZilla also includes client software.

After downloading and installing, select "Install source" to install the source code.

After the installation is complete, you can directly open the FileZilla server. sln that comes with the project. This is the vs project, which contains three projects,

FZS Interface: set and monitor the FTP server.

Service: This is part of the core FTP server.

GFtp: it cannot be opened. I don't know what it is for. Will foreigners be so careless? :)

Directly compiling is prone to errors. FileZilla depends on two third-party packages: zlib (compression algorithm package) and regexp (Regular Expression package)

Get zlib first, download

Undo it, generate the directory zlib123, and use. net 2003 to open zlib123 \ projects \ visualc6 \ zlib. dsw

Open generate | Configuration Manager, set the active solution configuration to DLL Release, compile and generate the zlib project, and then generate zlib1.lib and zlib1.dll under Win32_DLL_Release.

Then, regexp uses the boost third-party package, which has many common C ++ components ,:


After unlocking, in cmd,

Step 1: Compile bjm. This is the boost compiler.

Cd boost_000033_1 \ tools \ build \ jam_src

Build. bat

The bjam.exe file is generated in the current bin.ntx86directory.

Step 2: Compile boost

Cd boost_000033_1

Copy the just-generated bjam.exe file.

Set VC7_ROOT = "C: \ Program Files \ Microsoft Visual Studio. NET 2003 \ Vc7"

Bjam "-sTOOLS = vc7" install

This step takes a long time. At that time, we only used the regexp package in it. We should be able to compile only this package, but I did not study it carefully.

After compilation, the boost directory is generated under the root directory of the C drive. the. net project under this directory will be used.

In the. net project, add

Executable File: zlib123 \ projects \ visualc6 \ Win32_DLL_Release

Contains files: zlib123 directory and c: \ Boost \ include \ boost-1_33_1

Library File: zlib123 \ projects \ visualc6 \ Win32_DLL_Release and c: \ Boost \ lib

The FZS Interface project can be compiled successfully. After compilation, FileZilla Server Interface.exe is generated in the Debug directory.

When generating a Service project, you need to adjust the Project Settings:

Language settings: Open the project properties page and configure properties | General, select "use Unicode Character Set" as the character set, otherwise unicode must be used during compilation;

Link settings: Open the project properties page, configure properties | linker, and change zlib. lib to zlib1.lib (because zlib123 project generates zlib1.lib)

The following code is generated. When the Service project is generated, the "FileZilla Server FTP server" Service is automatically installed. You can also manually install the Service:

Cd FileZilla_Server \ Debug

"FileZilla server.exe" install auto

You can try this FTP Server and run FileZilla_Server \ interface \ Debug \ FileZilla Server Interface.exe. This is the configuration monitoring program of the FTP Server. add several users and set home dir, try again using the FTP client.

Through the complete description in this article, you should know the source code of FileZilla and hope to help you!

  1. FileZilla
  2. FileZilla: free server software
  3. New Version FileZilla bug fixes
  4. Key Vulnerability in FileZilla FTP client hard-coded password Index
  5. FileZilla Server

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.