Operating system: Introduction to SFTP related knowledge

Operating system: Introduction to SFTP related knowledge

Today I will share with you some knowledge about SFTP, I hope it will be helpful to you!

1. What is SFTP?

SFTP (SSH File Transfer Protocol) is a secure file transfer protocol based on SSH (Secure Shell). Using the SFTP protocol can provide a secure network encryption algorithm during file transfer, thereby ensuring the secure transmission of data. In the Linux operating system, the default port of SFTP is 22. The transmission provides a password and key authentication mechanism, which can effectively prevent threats and public technology during the transmission process.

2. SFTP Composition

Server: The host where the SFTP service is installed, usually a Linux server. Windows servers can also install the SFTP service through software, such as freeSSHd software. Client: The client that installs the software to access the SFTP server, such as XFTP, WinSCP, FileZilla, FlashFXP and other clients.

3. SFTP verification connection method

  • Account and password verification: Use account ID and password for verification, and the credentials are encrypted during the verification process.
  • SSH key authentication: Authentication is performed using an SSH password.
  • Account password + SSH key mixed verification: Both verifications must be met before a connection can be made.

4. Common SFTP commands

4.1 Login

 #Password login
sftp -P 22 [email protected]
#Key login
sftp -P 22 -i ~/.ssh/id_rsa [email protected]

4.2 Basic Operations of SFTP Shell

 #Current working directory:
pwd
#View the files in the current directory:
ls
ls -la
# Change directory:
cd
#Local working directory:
lpwd
#View the files in the local working directory:
lls
#Switch the local working directory:
lcd dirname

4.3 Download server files to local

 #Download the server file to local
get remote_file_name
#Rename
get remote_file_name local_file_name
#recursion
get -r some_directory_name
#Keep the original file attributes and date
get -Pr some_directory_name

4.4 Upload local files to remote server

 #Upload local files to the remote server
put localFile
#recursion
put -r local_directory_name

<<:  Do you know two common communication methods of Vue?

>>:  By the end of 2021, my country will have 10.1 5G base stations per 10,000 people

Recommend

New enterprise video conferencing strategies must go beyond meetings

Today’s workflows are increasingly digital, and v...

Let's talk about HTTP/3, QUIC, how do they work?

Why do we need HTTP/3? One important reason is to...

Differences between Single Mode Fiber and Multimode Fiber

What is Fiber Optic? Fiber optics is a type of ne...

5G speed may be slower than 4G?

In 2020, as the first year of 5G, 5G network cons...

Trip.com QUIC high availability and performance improvements

First, the QUIC multi-process deployment architec...

Improving operational efficiency of cloud NFV infrastructure

Mobile data traffic will grow more than 10 times ...

What impact will the Internet of Things have on corporate business?

Nowadays, whether people like it or not, the Inte...

5G will play a key role in driving semiconductor market growth

According to foreign media reports, the much-anti...

What other issues do we need to address to grow our business?

Consumers in today's world are more "fic...