当前位置:网站首页>FTP服務與配置
FTP服務與配置
2022-07-24 02:59:00 【吉吉吉吉吉吉吉吉吉吉】
目錄
一、FTP概述
FTP(File Transfer Protocal,文本傳輸協議)時典型的C/S架構的應用層協議,需要由服務端軟件、客戶端軟件兩個部分共同實現文件傳輸功能。FTP客戶端和服務端之間的連接是可靠的,面向連接的,為數據的傳輸提供了可靠的保證。
TCP協議:20,21端口
二、FTP服務的兩種模式
FTP是一種文件傳輸協議,它支持兩種模式,一種方式叫做Standard(也就是Active,主動),一種是Passive(也就是PASV,被動)。Standard模式是FTP的客戶端發送PORT命令到FTP Server。Passive模式是FTP的客戶端發送PASV命令到FTP Server
1、Standard模式
FTP客戶端首先和FTP Server的TCP21端口建立連接,通過這個通道發送命令,客戶端需要接收數據的時候在這個通道上發送PORT命令。PORT命令包含了客戶端用什麼端口接收數據。在傳送數據的時候,服務端通過自己的TCP20端口發送數據。FTP Server必須和客戶端建立一個新的連接用來傳送數據。
2、Passive模式
在建立控制通道的時候和Standard模式類似,當客戶端通過這個通道發送PASV命令的時候,FTP Server打開一個比特於1024和5000之間的隨機端口並且通知客戶端在這個端口上傳送數據的請求,然後FTP Server將通過這個端口進行數據的傳送,這個時候FTP Server不再需要建立一個新的和客戶端之間的連接。
三、搭建和配置FTP服務
1、實驗環境
服務器:CentOS7系統 ip:192.168.226.131
客戶端:Win10系統 ip:192.168.226.160
關閉防火牆;臨時關閉全面防護

安裝vsftpd軟件

開啟vsftp服務並查看端口

2、匿名用戶訪問
修改配置文件


給予訪問目錄最大權限

3、測試
在/var/ftp/pub下創建一個文件1.txt

①打開win10命令行,進入到192.168.44.140,pub目錄下出現1.txt文件

②下載文件

這是文件就已經在本地下載好了

边栏推荐
- Reading notes: self cultivation of programmers - Chapter 3
- C language actual combat guessing game
- SSM family financial management personal financial management system accounting system
- Ugui source code analysis - stencilmaterial
- SSM家庭理财个人理财管理系统记账系统
- Fasterrcnn sample code test 1: make anchor_ generator = None
- 攻防世界WEB练习区(webshell、command_execution、simple_js)
- 【英雄哥七月集训】第 23天: 字典树
- Only beautiful ones can be opened
- og seo
猜你喜欢

Programmers can't JVM? Ashes Engineer: all waiting to be eliminated! This is a must skill!

Make life full of happiness

攻防世界WEB練習區(view_source、get_post、robots)

SSM's technical forum includes front and back offices

Hcip --- BGP comprehensive experiment

UIE: 信息抽取的大一统模型

Detailed explanation of wechat official account online customer service access methods and functions

Reading notes: self cultivation of programmers - Chapter 3

微信公众号在线客服接入发方法和功能详解

PMP preparation experience | good habits, good process, good results
随机推荐
JVM initial
kettle
Zone d'entraînement Web d'attaque et de défense (View source, get Post, robots)
SSM家庭理财个人理财管理系统记账系统
日常杂谈(一)
ssm的求职招聘系统兼职应聘求职
The next stop of data visualization platform | gifts from domestic open source data visualization datart "super iron powder"
Unity 消息推送
Go log package
Rules for generating 13 digit barcode EAN-13 Code: the thirteenth digit is the verification code obtained by calculating the first twelve digits.
Is it safe to open an account for Xiaobai stock? Can I apply online?
SSM based blog system [with background management]
Audio processing based on time-frequency diagram matlab
JVM initial
Custom log annotation, request fetching
攻防世界WEB练习区(weak_auth、simple_php、xff_referer)
C language exercises
关于Aries框架增删改查-查Demo
Summernote rich text editor
Wonderful! The description of meituan Octo distributed service management system is too clear