FileZilla source code analysis 2

Source: Internet
Author: User
Tags ftp client 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.

<Type = "text/javascript"> <src = "http://pagead2.googlesyndication.com/pagead/show_ads.js" type = "text/javascript"> <type = "text/javascript"> <src = "http://pagead2.googlesyndication.com/pagead/show_ads.js" type = "text/javascript">

WM_FILEZILLA_SERVERMSG:

WParam indicates a large classification, that is, what type of message, and lParam is the additional information, which varies depending on wParam.

WParam has the following types:

FSM_STATUSMESSAGE:

Record the current activity, display the activity information in the admin window, and record it to the log file (you need to set the corresponding options). Open the admin window, the content displayed in the upper part is from.

LParam carries the t_statusmsg structure, which records the active user, ip, time, message, and so on.

For example:

(000001) 16:03:56-(not logged in) (127.0.0.1)> USER whg

(000001) 16:03:59-(not logged in) (127.0.0.1)> 331 Password required for whg

(000001) 16:04:05-(not logged in) (127.0.0.1)> PASS *

(000001) 16:04:11-robert (127.0.0.1)> 230 Logged on

FSM_CONNECTIONDATA:

This is a connection-related message, such as a new connection, a successful user login, and a user logout. The information is sent to the admin window, which is displayed in the lower half of the admin window, that is, ID, Account, IP, and so on.

LParam carries the t_connop structure. The op in the structure indicates a more detailed connection classification. The possible values include:

USERCONTROL_CONNOP_ADD

New users are connected (not logged on yet)

USERCONTROL_CONNOP_CHANGEUSER

Logon successful

USERCONTROL_CONNOP_REMOVE

The user exits, or is forcibly logged out due to time

USERCONTROL_CONNOP_TRANSFERINIT

Transmission starts or ends, that is, data communication with the client. If data is transmitted, the ls command also causes data transmission.

USERCONTROL_CONNOP_TRANSFEROFFSETS

Shows the transmission progress. For example, you need to display the current number of transmitted bytes and transmission rate to the admin window during file transmission.

All the information is displayed in the lower half of the admin window.

FSM_THREADCANQUIT:

These messages are sent when the system exits, and the thread ends when the system processes the message.

FSM_SEND:

The system sends this message as long as the data is sent, and the status bar in the admin window shows how much data the current user has sent.

FSM_RECV:

The system sends this message as long as the data is received, and the status bar in the admin window shows how much data the current user has received.

It can be seen that the messages processed by the CServer are only admin or status messages, which should be sent when the listen thread and accep process the corresponding ftp request. The real FTP processing is not here.

<Type = "text/javascript"> <src = "http://pagead2.googlesyndication.com/pagead/show_ads.js" type = "text/javascript">

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

  • FileZilla source code analysis 1
  • FileZilla
  • FileZilla: free server software
  • New Version FileZilla 3.3.1.0 bug fixes
  • Key Vulnerability in FileZilla FTP client hard-coded password Index
  • FileZilla Server

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: info-contact@alibabacloud.com 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.