Method, device, equipment, storage medium and program product for file transmission

CN119814766BActive Publication Date: 2026-07-21CHINA MOBILE INTERNET CO LTD +1
View PDF 2 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
CHINA MOBILE INTERNET CO LTD
Filing Date
2024-12-24
Publication Date
2026-07-21

Smart Images

  • Figure CN119814766B_ABST
    Figure CN119814766B_ABST
Patent Text Reader

Abstract

The application discloses a file transmission method, device, equipment, storage medium and program product, and is applied to an authentication server. The specific technical scheme comprises the following steps: receiving an identity authentication request sent by a terminal, wherein the identity authentication request carries user identity information and a to-be-transmitted file; querying authentication information corresponding to the user identity information in a database; calculating a check parameter corresponding to the user identity information based on the authentication information and a preset authentication algorithm; authenticating the terminal based on the check parameter; and transmitting the to-be-transmitted file in the case that the terminal is authenticated successfully. In this way, the data encryption speed can be improved, and thus the data transmission efficiency is improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application belongs to the field of data transmission technology, and in particular relates to a method, apparatus, device, storage medium and program product for file transmission. Background Technology

[0002] With the explosive growth of data, terminal storage resources are insufficient to support storing all user data. To store user data, users can utilize cloud storage to back up data on their terminals, and users can upload and download files based on cloud storage.

[0003] Specifically, users can select the file to be uploaded in the cloud drive application (App) and then click the upload button to upload the file. Similarly, when downloading a file, users can select the file to be downloaded in the cloud drive storage space and then click the download button to download the file.

[0004] However, after receiving file download and upload requests from users, the cloud disk server directly downloads and uploads the files, thus failing to guarantee data security during the file transfer process. Summary of the Invention

[0005] This application provides a method, apparatus, device, and storage medium for file transfer. These improvements can increase data encryption speed, thereby enhancing data transmission efficiency.

[0006] In a first aspect, embodiments of this application provide a file transfer method applied to a proxy server, the method comprising:

[0007] The terminal receives an authentication request, which carries user identity information and a file to be transmitted.

[0008] The authentication information corresponding to the user's identity information was retrieved from the database.

[0009] Based on the authentication information and the preset authentication algorithm, calculate the verification parameters corresponding to the user identity information;

[0010] The terminal is authenticated based on the verification parameters;

[0011] If the terminal is successfully authenticated, the file to be transmitted is transmitted.

[0012] In one possible implementation, before retrieving the authentication information corresponding to the user's identity information from the database, the method further includes:

[0013] The terminal sends a user identity identifier, a user password, and a first parameter; the first parameter is generated by the terminal based on the user password and a first random number.

[0014] Determine whether the database contains the user's identity identifier;

[0015] If the user identity identifier is not included in the database, generate pseudo-identity information for the user corresponding to the user identity identifier;

[0016] Generate a second random number;

[0017] The database stores the correspondence between the second random number, the first parameter, the user pseudo-identity information, and the user identity identifier.

[0018] In one possible implementation, after storing the correspondence between the second random number, the first parameter, the user pseudo-identity information, and the user identity identifier in the database, the method further includes:

[0019] Generate a second parameter and a third parameter based on the first parameter and the second random number;

[0020] The terminal sends the second parameter, the third parameter, the user pseudo-identity information, and the cluster identifier of the authentication server cluster in the proxy server to the terminal, so that the terminal can calculate a fourth parameter based on the user identity identifier, the user password, and the first random number, calculate a first verification parameter based on the first parameter and the second parameter, calculate a second verification parameter based on the user identity identifier, and calculate a third verification parameter based on the user pseudo-identity information, the cluster identifier, the first parameter, the second parameter, and the user identity identifier.

[0021] In one possible implementation, the authentication information includes a user identity identifier, a first random number, and a first parameter; the user identity information includes user pseudo-identity information, a cluster identifier, a first verification parameter, a second verification parameter, and a third verification parameter; the step of calculating the verification parameters corresponding to the identity authentication request based on the authentication information and a preset authentication algorithm includes:

[0022] The first verification parameter is calculated based on the user pseudo-identity information, the first verification parameter, the second verification parameter, the cluster identifier, the third random number, the first parameter, and the user identity identifier;

[0023] The second verification parameter is calculated based on the pseudo-identity information of the proxy server.

[0024] The third verification parameter is calculated based on the user pseudo-identity information, the first verification parameter, the second verification parameter, the cluster identifier, the third random number, and the first parameter;

[0025] Based on the user pseudo-identity information, the second verification parameter, the third verification parameter, the second verification parameter, the user identity identifier, the first verification parameter, the third random number, the first parameter, and the cluster identifier, the fourth verification parameter is calculated.

[0026] Authenticating the terminal based on the verification parameters includes:

[0027] The terminal is authenticated based on the first verification parameter, the second verification parameter, the third verification parameter, and the fourth verification parameter.

[0028] In one possible implementation, the proxy server includes an authentication server; before retrieving the authentication information corresponding to the user's identity information from the database, the method further includes:

[0029] Receive the authentication server identifier, the cluster identifier of the cluster to which the authentication server belongs, and the private key corresponding to the authentication server from the authentication server;

[0030] A shared key is generated based on the proxy server identifier, the private key, and the authentication server identifier;

[0031] The shared key and the proxy server identifier are sent to the authentication server for the authentication server to generate a third random number, a fourth random number, and server pseudo-identity information corresponding to the proxy server.

[0032] The system receives the proxy server identifier, the shared key, the cluster identifier, the third random number, the fourth random number, and the server pseudo-identity information sent by the authentication server.

[0033] In one possible implementation, authenticating the terminal based on the verification parameters includes:

[0034] Obtain the pseudo-identity information of the server corresponding to the proxy server;

[0035] Determine whether the database contains the server's pseudo-identity information;

[0036] If the database includes the server pseudo-identity information, the target verification parameter is calculated based on the server pseudo-identity information, the first verification parameter, the second verification parameter, the third verification parameter, the first parameter, the second random number, the fifth random number, the shared key, and the cluster identifier.

[0037] The step of transmitting the file to be transmitted after the terminal authentication is successful includes:

[0038] If the target verification parameter and the fourth verification parameter are the same, the file to be transmitted is transmitted.

[0039] In one possible implementation, the file to be transmitted includes a content identifier to be transmitted and preset index parameters; the transmission of the file to be transmitted includes:

[0040] The hash value of each data block in the content to be transmitted is calculated based on the preset index parameters.

[0041] For each data block, the hash value of the data block is used to calculate the content similarity between the data block and other data blocks in the content to be transmitted;

[0042] Delete data blocks whose content similarity is greater than a preset threshold to obtain the target transmission content;

[0043] The target transmitted content is stored in the cloud disk storage space.

[0044] Secondly, embodiments of this application provide a file transfer method applied to a terminal, the method comprising:

[0045] Obtain user identity information and the file to be transferred;

[0046] An authentication request carrying the user's identity information and the file to be transmitted is sent to the proxy server. The authentication request is used to instruct the proxy server to obtain the authentication information corresponding to the user's identity information from the database. Based on the authentication information and a preset authentication algorithm, the proxy server calculates the verification parameters corresponding to the user's identity information. The proxy server authenticates the terminal based on the verification parameters. If the proxy server successfully authenticates the terminal, the proxy server transmits the file to be transmitted.

[0047] In one possible implementation, before obtaining the user identity information and the file to be transferred, the method further includes:

[0048] Obtain user identification and user password;

[0049] Calculate the hash value of the user password and the first random number to obtain the first parameter;

[0050] The proxy server sends the first parameter, the user identity identifier, and the user password to the proxy server so that the proxy server can determine whether the user identity identifier is not included in the database, generate user pseudo identity information corresponding to the user identity identifier, and generate a second random number. The correspondence between the second random number, the first parameter, the user pseudo identity information, and the user identity identifier is stored in the database.

[0051] The proxy server receives a second parameter, a third parameter, the user's pseudo-identity information, and the cluster identifier of the cluster to which the authentication server in the proxy server belongs. The second parameter and the third parameter are generated by the proxy server based on the first parameter and the second random number.

[0052] The first verification parameter is calculated based on the first parameter and the second parameter;

[0053] The second verification parameter is calculated based on the user's identity identifier;

[0054] The third verification parameter is calculated based on the user pseudo-identity information, the cluster identifier, the first parameter, the second parameter, and the user identity identifier;

[0055] The user pseudo-identity information, the cluster identifier, the first verification parameter, the second verification parameter, and the third verification parameter are used as the user identity information.

[0056] Thirdly, embodiments of this application provide a file transfer apparatus applied to a proxy server, the apparatus comprising:

[0057] The receiving module is used to receive an authentication request sent by the terminal, wherein the authentication request carries user identity information and a file to be transmitted;

[0058] The query module is used to retrieve the authentication information corresponding to the user's identity information from the database;

[0059] The calculation module is used to calculate the verification parameters corresponding to the user identity information based on the authentication information and the preset authentication algorithm;

[0060] The authentication module is used to authenticate the terminal based on the verification parameters;

[0061] The transmission module is used to transmit the file to be transmitted when the terminal is successfully authenticated.

[0062] Fourthly, embodiments of this application provide a file transfer apparatus applied to a terminal, the apparatus comprising:

[0063] The acquisition module is used to acquire user identity information and the file to be transferred;

[0064] The sending module is used to send an authentication request carrying the user's identity information and the file to be transmitted to the authentication server. The authentication request is used to instruct the authentication server to obtain the authentication information corresponding to the user's identity information from the database, calculate the verification parameters corresponding to the user's identity information based on the authentication information and a preset authentication algorithm, and send a verification request carrying the verification parameters to the proxy server. The verification request is used to instruct the proxy server to authenticate the terminal based on the verification parameters.

[0065] Fifthly, embodiments of this application provide an electronic device, the device comprising: a processor and a memory storing computer program instructions;

[0066] When the processor executes the computer program instructions, it implements the file transfer method as described in any one of the first aspects.

[0067] Sixthly, embodiments of this application provide a computer-readable storage medium storing computer program instructions, which, when executed by a processor, implement the file transfer method as described in any one of the first aspects.

[0068] In a seventh aspect, embodiments of this application provide a computer program product in which instructions, when executed by a processor of an electronic device, cause the electronic device to perform the file transfer method as described in any one of the first aspects.

[0069] This application discloses a file transfer method, apparatus, device, storage medium, and program product. After receiving an authentication request from a terminal, the proxy server searches its local database for corresponding authentication information based on the user's identity information carried in the authentication request. The proxy server calculates corresponding verification parameters based on the authentication information. After authenticating the terminal based on these verification parameters, the proxy server transfers the file to be transferred if authentication is successful. Thus, by carrying both user identity information and the file to be transferred in the authentication request, the proxy server can pre-authenticate the user locally based on the user's identity information and transfer the file if authentication is successful. The security of the file to be transferred is verified before it is stored on the cloud drive, thereby improving the security of data transmission. Attached Figure Description

[0070] To more clearly illustrate the technical solutions of the embodiments of this application, the accompanying drawings used in the embodiments of this application will be briefly introduced below. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.

[0071] Figure 1 This is an exemplary schematic diagram of a file access and upload method provided in the prior art;

[0072] Figure 2 This is an exemplary schematic diagram of a method for accessing and downloading files in the prior art;

[0073] Figure 3 This is a schematic diagram of the structure of a file transfer system provided in an embodiment of this application;

[0074] Figure 4 This is a flowchart illustrating a file transfer method applied to a proxy server, as provided in an embodiment of this application.

[0075] Figure 5 This is a flowchart illustrating a terminal registration method provided in an embodiment of this application;

[0076] Figure 6 This is a flowchart illustrating a server registration method provided in an embodiment of this application;

[0077] Figure 7 This is an exemplary schematic diagram of a server and terminal registration method provided in an embodiment of this application;

[0078] Figure 8 This is a flowchart illustrating a file transfer method applied to a terminal, as provided in an embodiment of this application.

[0079] Figure 9 This is a flowchart illustrating a method for obtaining user identity information provided in an embodiment of this application;

[0080] Figure 10 This is an exemplary schematic diagram of a terminal authentication method provided in an embodiment of this application;

[0081] Figure 11 This is an exemplary schematic diagram of a file transfer method provided in an embodiment of this application;

[0082] Figure 12 This is a schematic diagram of a file transfer device applied to an authentication server, provided in an embodiment of this application.

[0083] Figure 13 This is a schematic diagram of a file transfer device applied to a terminal, provided in an embodiment of this application;

[0084] Figure 14 This is a schematic diagram of the structure of an electronic device provided in another embodiment of this application. Detailed Implementation

[0085] The features and exemplary embodiments of various aspects of this application will be described in detail below. To make the objectives, technical solutions, and advantages of this application clearer, the application will be further described in detail below with reference to the accompanying drawings and specific embodiments. It should be understood that the specific embodiments described herein are only intended to explain this application and not to limit it. For those skilled in the art, this application can be implemented without some of these specific details. The following description of the embodiments is merely to provide a better understanding of this application by illustrating examples.

[0086] It should be noted that, in this document, relational terms such as "first" and "second" are used merely to distinguish one entity or operation from another, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Furthermore, the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such a process, method, article, or apparatus. Without further limitations, an element defined by the phrase "comprising..." does not exclude the presence of additional identical elements in the process, method, article, or apparatus that includes said element.

[0087] Currently, during the process of users backing up data using cloud storage, such as Figure 1 As shown, users can click the "+" on the homepage of the cloud drive app. The cloud drive app will then redirect to the local transfer list, which displays the data stored in the local storage space. Users can then select the file to be uploaded from the local transfer list and click the "Upload" button to upload the file.

[0088] Correspondingly, users can also download files using the "+" icon on the cloud drive app's homepage. Specifically, as follows... Figure 2 As shown, users can click the "+" on the homepage of the cloud drive app. The cloud drive app will then redirect to the transfer list in response to the user's action. Users can choose between the local transfer list and the cloud drive transfer list. The cloud drive transfer list displays the data stored in the cloud drive storage space. Users can then select the file to be downloaded from the cloud drive transfer list and click the "Download" button to download the file.

[0089] However, during the file upload and download process described above, the cloud drive's proxy server does not authenticate the user's identity, thus failing to guarantee the security of file transfer. Furthermore, while the proxy server can perform a full backup of the files selected by the user for upload, these backups may include files with identical content. This results in a waste of cloud drive storage resources.

[0090] To address the problems existing in the prior art, embodiments of this application provide a method, apparatus, device, storage medium, and program product for file transfer. The file transfer method is applied to a proxy server, wherein the proxy server is used to complete file upload and download. An authentication server is embedded within the proxy server, and the proxy server can utilize the authentication services provided by the authentication server to complete the authentication of the terminal login user's identity. For example... Figure 3 As shown, Figure 3 This is an exemplary schematic diagram of a file transfer system provided in an embodiment of this application. In actual implementation, the authentication server can be embedded in a proxy server or act as a standalone third-party authentication server.

[0091] The system consists of a terminal connected to an authentication server, and an authentication server connected to a proxy server. Both the terminal and the proxy server register with the authentication server. Upon receiving an authentication request from the terminal, the proxy server uses the authentication server to authenticate the terminal. If authentication is successful, file transfer is initiated.

[0092] Specifically, the methods for file transfer using a proxy server are as follows: Figure 4 As shown, the method includes:

[0093] S401, Receive the authentication request sent by the terminal.

[0094] The authentication request includes the user's identity information and the file to be transmitted.

[0095] Specifically, after a user selects a file to be transferred in the cloud drive app, the terminal responds to the user's operation by obtaining the identifier of the file to be transferred and the user's identity information, such as the user's login account.

[0096] S402. Query the authentication information corresponding to the user's identity information in the database.

[0097] The authentication information is used to encrypt the user's identity information to obtain the verification parameters corresponding to the user's identity information.

[0098] S303. Based on the authentication information and the preset authentication algorithm, calculate the verification parameters corresponding to the user's identity information.

[0099] S404. Authenticate the terminal based on the verification parameters.

[0100] Understandably, the authentication server's database stores user identity information and corresponding first authentication information. The authentication server uses the first authentication information and user identity information to calculate verification parameters. Subsequently, the proxy server uses the user identity information stored in its local database and the corresponding second authentication parameters to calculate the destination verification parameters. If the destination verification parameters match the aforementioned verification parameters, the authentication results from the authentication server and the proxy server are consistent, thus confirming that the terminal has been successfully authenticated.

[0101] S405. If the terminal authentication is successful, the file to be transmitted shall be transmitted.

[0102] Using the above method, after receiving an authentication request from a terminal, the proxy server searches its local database for corresponding authentication information based on the user's identity information carried in the request. The proxy server calculates the corresponding verification parameters based on the authentication information. After authenticating the terminal based on these verification parameters, the proxy server transmits the file to be transmitted if authentication is successful. Thus, by including both user identity information and the file to be transmitted in the authentication request, the proxy server can pre-authenticate the user based on the user's identity information and transmit the file if authentication is successful. The security of the file to be transmitted is verified before it is stored on the cloud disk, thereby improving the security of data transmission.

[0103] It should be noted that before the proxy server authenticates the terminal, the proxy server needs to complete the user registration and authentication server registration respectively, and then the proxy server authenticates the user's identity through the authentication server.

[0104] The following combination Figure 5 This application introduces a user registration method provided in its embodiments, such as... Figure 5 As shown, before step S402 above, where the authentication information corresponding to the user's identity information is retrieved from the database, the method includes:

[0105] S501, Receive the user identity identifier, user password and first parameter sent by the receiving terminal.

[0106] The first parameter is generated by the terminal based on the user password and the first random number. The first parameter can be obtained by the terminal calculating the hash value of the user password and the first random number, specifically, it can be expressed as Formula 1:

[0107] A1=h(PW U ∥R1) Formula 1

[0108] Where A1 represents the first parameter, PWU R1 represents the user's password, and R2 represents the first random number. The first parameter is used to register the user with the authentication server.

[0109] In one example, the authentication server embedded in the proxy server uses a random number generation algorithm to generate the first random number. It should be noted that the method described above for generating random numbers is only an example; in actual implementations, the methods for generating random numbers are not limited to this.

[0110] S502. Determine whether the database contains user identity identifiers.

[0111] This database is the database corresponding to the authentication server, and it is used to store the user identity identifiers of registered users.

[0112] S503. If the database does not contain the user identity identifier, generate pseudo-identity information corresponding to the user identity identifier.

[0113] Understandably, if the database does not contain the user's identity identifier, it means that the user corresponding to the current user's identity identifier has not yet registered. Therefore, the authentication server embedded in the proxy server uses a pseudo-random number generation algorithm to generate a pseudo-random number corresponding to the user's identity identifier, uses this pseudo-random number as the pseudo-identity information of the user corresponding to the user's identity identifier, and stores the correspondence between the user's identity identifier and the pseudo-identity information in the database of the authentication server.

[0114] S504. Generate a second random number.

[0115] S505. Store the correspondence between the second random number, the first parameter, the user pseudo-identity information, and the user identity identifier in the database.

[0116] Using the method provided in this application embodiment, after receiving the user identity identifier, user password and first parameter sent by the terminal, the proxy server generates user pseudo-identity information corresponding to the user identity identifier if the user identity identifier is not stored in the local database. The proxy server then stores the correspondence between the second random number, the first parameter, the user pseudo-identity information and the user identity identifier in the database. In this way, the registration of the user identity identifier in the authentication server is completed, so that the authentication server can subsequently authenticate the user identity based on the database, ensuring the security of file transmission.

[0117] The following combination Figure 6 This application describes a server registration method provided in its embodiments, such as... Figure 6 As shown, before step S402 above, where the authentication information corresponding to the user's identity information is retrieved from the database, the method includes:

[0118] S601: Receive the authentication server identifier, the cluster identifier of the cluster to which the authentication server belongs, and the private key corresponding to the authentication server sent by the authentication server.

[0119] Each authentication server can generate its own corresponding authentication server identifier and private key. It should be noted that the method for generating the authentication server identifier and private key is not limited in this embodiment.

[0120] To ensure terminal authentication speed, this application can deploy multiple authentication servers, forming an authentication server cluster. Authentication servers within the same cluster can serve as backup servers for each other. When the computing resources of an authentication server embedded in a proxy server are insufficient, the proxy server can call upon other authentication servers in the cluster to perform terminal authentication. To distinguish different authentication server clusters, each cluster corresponds to a cluster identifier.

[0121] S602. Generate a shared key based on the proxy server identifier, private key, and authentication server identifier.

[0122] Specifically, the proxy server calculates the shared key using the following formula 2:

[0123] GS c =h(SID) i |∣SK G |∣NID j ) Formula 2

[0124] Among them, GS C SID represents the shared secret key. i Indicates the proxy server identifier, SK G Represents the private key, NID j This indicates the authentication server identifier.

[0125] S603. Send the shared key and the proxy server identifier to the authentication server so that the authentication server can generate a third random number, a fourth random number, and the server pseudo-identity information corresponding to the proxy server.

[0126] In this process, after receiving the shared key and the proxy server identifier, the authentication server uses a pseudo-random number algorithm to generate pseudo-identity information for the server.

[0127] Each authentication server cluster shares a database that stores the correspondence between proxy server identifiers, server pseudo-identity information, authentication server identifiers, and third-party random numbers.

[0128] S604. Receive the proxy server identifier, shared key, cluster identifier, third random number, fourth random number and server pseudo identity information sent by the authentication server.

[0129] In this process, the proxy server uses the proxy server identifier, shared key, cluster identifier, third random number, fourth random number and server pseudo identity information to authenticate the terminal. The specific authentication method will be described in detail in subsequent embodiments.

[0130] Using the method provided in this application, after generating a corresponding authentication server identifier and private key, the authentication server sends the authentication server identifier and private key to the proxy server. The proxy server can generate a shared key based on the private key and the authentication server identifier. After the authentication server obtains the shared key corresponding to the proxy server, it can establish a correspondence between the proxy server identifier, the server pseudo-identity information, the authentication server identifier, and the third random number. The proxy server identifier, the server pseudo-identity information, the authentication server identifier, and the third random number can be used for subsequent user authentication. Thus, during the user authentication process, the authentication server can simultaneously refer to the proxy server identifier, the server pseudo-identity information, the authentication server identifier, and the third random number to verify the legitimacy of the corresponding proxy server, thereby further ensuring data security.

[0131] The following combination Figure 7 This section describes the complete process of terminal registration and authentication server registration, such as... Figure 7 As shown, the method includes:

[0132] S701. The authentication server generates an authentication server identifier and a private key, and determines a one-way hash function.

[0133] The specific methods for generating the authentication server identifier and private key are described in the above embodiments and will not be repeated here.

[0134] S702, The proxy server generates a proxy server identifier and a shared key.

[0135] S703, The proxy server sends the proxy server identifier and shared key to the authentication server.

[0136] S704. The authentication server generates random numbers R1 and R2, server pseudo-identity information, and stores the correspondence between the proxy server identifier, server pseudo-identity information, authentication server identifier, and hash values ​​of R1 and R2.

[0137] Wherein, R1 is the third random number in the above embodiments, and R2 is the fourth random number in the above embodiments. It should be noted that the embodiments of this application do not impose specific limitations on the method of generating random numbers.

[0138] S705, the authentication server sends the proxy server identifier, shared key, cluster identifier, R1, R2 and server pseudo-identity identifier to the proxy server.

[0139] It should be noted that S701 to S705 refer to the registration process of the aforementioned server.

[0140] S706, The terminal determines the user's identity, password, and R3, and calculates A1.

[0141] In this context, R3 is the first random number in the above embodiment, and A1 is the first parameter in the above embodiment. Specifically, the method for calculating the first parameter is described in the relevant description in the above embodiment.

[0142] S707: The terminal sends the user's identity identifier and password to the authentication server.

[0143] S708. The authentication server checks whether the database contains the user's identity identifier. If the database does not contain the user's identity identifier, it generates false identity information for the user and calculates A2 and A3.

[0144] Where A2 is the second parameter and A3 is the third parameter. The specific method for calculating the second and third parameters based on user identity information is as follows:

[0145] The second parameter is calculated using Formula 3:

[0146]

[0147] Among them, PID i R4 is the user's identity information, and AuID is the fourth randomly generated random number. i SK serves as the cluster identifier. G This is the private key for the authentication server.

[0148] The third parameter is calculated using Formula 4:

[0149]

[0150] Among them, UID i Used as a user identifier.

[0151] S709, the authentication server sends A2, A3, user pseudo-identity information and cluster identifier to the terminal.

[0152] S710, terminal computing A4, storage A2, A3, A4, user pseudo-identity information and cluster identifier.

[0153] A4 is the fourth parameter.

[0154] The fourth parameter is calculated using Formula 5:

[0155]

[0156] Among them, PWU This is the user's password.

[0157] Using the method provided in this application, after generating the corresponding authentication server identifier and private key, the authentication server sends the authentication server identifier and private key to the proxy server. The proxy server can generate a shared key based on the private key and the authentication server identifier. After the authentication server obtains the shared key corresponding to the proxy server, it can establish a correspondence between the proxy server identifier, server pseudo-identity information, authentication server identifier, and a third random number. The proxy server identifier, server pseudo-identity information, authentication server identifier, and third random number can be used for subsequent user authentication. Thus, during the authentication process, the authentication server can simultaneously refer to the proxy server identifier, server pseudo-identity information, authentication server identifier, and third random number to verify the legitimacy of the corresponding proxy server, thereby further ensuring data security. Furthermore, after receiving the user's identity identifier and password sent by the terminal, the authentication server generates second and third parameters corresponding to the user's identity identifier and sends these parameters to the terminal. This allows the terminal to store the correspondence between the second, third, and fourth parameters and the user's identity identifier locally, facilitating subsequent user authentication using the second, third, and fourth parameters.

[0158] After the proxy server completes user registration, its local database stores the correspondence between the second random number, the first parameter, the user's pseudo-identity information, and the user's identity identifier. Subsequently, when a user sends an authentication request, the proxy server can use the database to complete the user's authentication. Therefore, after step S505 above, which involves storing the correspondence between the second random number, the first parameter, the user's pseudo-identity information, and the user's identity identifier in the database, the method further includes:

[0159] The second and third parameters are generated based on the first parameter and the second random number.

[0160] Specifically, the methods for generating the second and third parameters are described in the relevant descriptions of the above embodiments, and will not be repeated here.

[0161] Send the second parameter, the third parameter, the user's pseudo-identity information, and the cluster identifier of the authentication server cluster in the proxy server to the terminal.

[0162] Specifically, after receiving the second parameter, the third parameter, the user pseudo-identity information, and the cluster identifier of the authentication server cluster in the proxy server, the terminal calculates the fourth parameter based on the user identity identifier, the user password, and the first random number; calculates the first verification parameter based on the first and second parameters; calculates the second verification parameter based on the user identity identifier; and calculates the third verification parameter based on the user pseudo-identity information, the cluster identifier, the first parameter, the second parameter, and the user identity identifier.

[0163] Using the method provided in the embodiments of this application, the authentication server embedded in the proxy server sends the second parameter and the third parameter to the terminal, so that the terminal can store the correspondence between the second parameter, the third parameter, the fourth parameter and the user identity identifier locally, which facilitates the subsequent authentication of the user identity using the second parameter, the third parameter and the fourth parameter.

[0164] Based on the user identity information calculated by the aforementioned terminal, the proxy server, after obtaining the user pseudo-identity information, cluster identifier, first verification parameter, second verification parameter, and third verification parameter from the user identity information, searches for the corresponding authentication information in the database. The authentication information includes the aforementioned user identity identifier, first random number, and first parameter. Then, it uses the user identity information and authentication information to calculate the verification parameters. Specifically, for S403 above, calculating the verification parameters corresponding to the user identity information based on the authentication information and the preset authentication algorithm can be implemented as follows:

[0165] Step 1: Calculate the first verification parameter based on the user's pseudo-identity information, the first verification parameter, the second verification parameter, the cluster identifier, the third random number, the first parameter, and the user's identity identifier.

[0166] Specifically, the authentication server searches its local database for the fourth random number, the first parameter, and the user's identity identifier corresponding to the aforementioned user's identity information. It then calculates the fifth parameter, specifically according to Formula 6:

[0167] A5 = h(PID) i ∥R4∥AuID i ∥SK G ) Formula 6

[0168] Where A5 represents the fifth parameter, PID i Indicates user pseudo-identity information, SK G This is the private key for the authentication server.

[0169] The fifth random number is obtained by calculating according to formula 7:

[0170]

[0171] R5 is the fifth random number.

[0172] Based on the fifth random number and the fifth parameter, the authentication server determines the proxy server corresponding to the cloud storage app, specifically by calculating the proxy server identifier according to formulas 8 and 9:

[0173]

[0174] in, Indicates intermediate parameters, R6 is the sixth randomly generated random number, B4 is the fourth verification parameter, and SID. i B2 is the proxy server identifier, and B2 is the second verification parameter.

[0175] Having obtained the proxy server identifier, the authentication server calculates the first verification parameter:

[0176] GS C =h(SID) i ∥SK G ∥NID j ) Formula 10

[0177] B4 = h(GS) C ∥AuID i ) Formula 11

[0178]

[0179] Where C1 represents the first check parameter, GS C For shared keys, NID j This is the identifier for the authentication server.

[0180] The method for the terminal to calculate the first verification parameter, the second verification parameter, and the third verification parameter will be described in detail in subsequent embodiments.

[0181] Step 2: Calculate the second verification parameter based on the proxy server's pseudo-identity information.

[0182] Specifically, the second verification parameter is calculated according to formula 13:

[0183]

[0184] C2 represents the second check parameter.

[0185] Step 3: Calculate the third verification parameter based on the user's pseudo-identity information, the first verification parameter, the second verification parameter, the cluster identifier, the third random number, and the first parameter.

[0186] Specifically, the third verification parameter is calculated according to formula 14:

[0187]

[0188] C3 represents the third check parameter.

[0189] Step 4: Calculate the fourth verification parameter based on the user pseudo-identity information, the second verification parameter, the third verification parameter, the second verification parameter, the user identity identifier, the first verification parameter, the third random number, the first parameter, and the cluster identifier.

[0190] Specifically, the third verification parameter is calculated according to formula 15:

[0191]

[0192] C4 represents the fourth check parameter.

[0193] Accordingly, terminal authentication is performed based on verification parameters, including:

[0194] The terminal is authenticated based on the first verification parameter, the second verification parameter, the third verification parameter, and the fourth verification parameter.

[0195] Using the method provided in this application, the terminal first calculates the user's identity identifier using information stored in its local database, and then sends the calculation result to a proxy server. The proxy server then calculates the user's identity. By comparing the terminal's calculation result with its own, the proxy server can authenticate the terminal. Furthermore, because the terminal sends pseudo-identity information to the proxy server during data transmission, the leakage of user identity information is avoided, thereby improving the security of data transmission.

[0196] Furthermore, after calculating the first to fourth verification parameters, the authentication server in the proxy server constructs a verification message set and sends the verification message set to the proxy server. Based on the calculated target verification parameters, the proxy server uses the verification parameters to authenticate the terminal. Specifically, this can be implemented as follows:

[0197] Obtain the pseudo-identity information of the proxy server.

[0198] Determine whether the database contains false server identity information.

[0199] When the database includes server pseudo-identity information, the target verification parameter is calculated based on the server pseudo-identity information, the first verification parameter, the second verification parameter, the third verification parameter, the first parameter, the second random number, the fifth random number, the shared key, and the cluster identifier.

[0200] It should be noted that if the database does not contain the server's pseudo-identity information, the proxy server will determine that the terminal's identity authentication has failed and will refuse the user's request to upload files to the cloud drive.

[0201] Specifically, the target verification parameters are calculated as follows: The target verification parameters are obtained according to formulas 16 to 19:

[0202] B4 = h(GS) C ∥AuID i ) Formula 16

[0203]

[0204] in, This refers to the target verification parameters.

[0205] If the terminal authentication is successful, the file to be transmitted will be transmitted, including:

[0206] If the target check parameter and the fourth check parameter are the same, the file to be transferred will be transferred.

[0207] Using the method provided in this application embodiment, the authentication server calculates the verification message set, and the proxy server continues to authenticate the verification message set using the locally stored authentication messages, that is, the user identity information is encrypted before authentication, thereby improving the accuracy of the authentication results and the security of the data, thus ensuring the security of file transmission.

[0208] Based on the same concept, embodiments of this application also provide a file transfer method, which is applied to a terminal, such as... Figure 8 As shown, it specifically includes:

[0209] S801, Obtain user identity information and the file to be transferred.

[0210] S802. Send an authentication request carrying user identity information and the file to be transferred to the proxy server.

[0211] The identity authentication request is used to instruct the proxy server to obtain the authentication information corresponding to the user's identity information from the database, calculate the verification parameters corresponding to the user's identity information based on the authentication information and the preset authentication algorithm, authenticate the terminal based on the verification parameters, and transmit the file to be transmitted if the proxy server successfully authenticates the terminal.

[0212] Using the method provided in this application, after obtaining user identity information and the file to be transferred, the terminal sends an authentication request carrying the user identity information and the file to be transferred to the proxy server. Upon receiving the authentication request, the proxy server searches its local database for corresponding authentication information based on the user identity information carried in the authentication request. The proxy server can calculate the user's identity based on the authentication information to obtain corresponding verification parameters. After authenticating the terminal based on these verification parameters, the proxy server transfers the file to be transferred if the authentication is successful. Thus, by carrying both user identity information and the file to be transferred in the authentication request, the proxy server can pre-authenticate the user locally based on the user identity information, and transfer the file to be transferred only if the authentication is successful. The security of the file to be transferred is verified before it is stored on the cloud disk, thereby improving the security of data transmission.

[0213] The following combination Figure 9 Introducing the terminal registration process, such as Figure 9 As shown, the method includes:

[0214] S901. Obtain user identity and user password.

[0215] S902. Calculate the hash value of the user password and the first random number to obtain the first parameter.

[0216] S903. Send the first parameter, user identity identifier and user password to the proxy server so that the proxy server can determine whether the user identity identifier is not included in the database, generate user pseudo identity information corresponding to the user identity identifier, generate a second random number, and store the correspondence between the second random number, the first parameter, the user pseudo identity information and the user identity identifier in the database.

[0217] S904: Receive the second parameter, the third parameter, the user pseudo-identity information, and the cluster identifier of the authentication server cluster in the proxy server sent by the proxy server.

[0218] The second and third parameters are generated by the proxy server based on the first parameter and the second random number.

[0219] S905. The first verification parameter is calculated based on the first parameter and the second parameter.

[0220] Specifically, the first verification parameter is calculated according to the following formula:

[0221]

[0222] Where A2 is the second parameter, R5 is the fifth random number, and B1 is the first verification parameter.

[0223] S906. The second verification parameter is calculated based on the user's identity identifier.

[0224] Specifically, the method for calculating the second verification parameter is as follows:

[0225]

[0226] UID1 is the user's identity identifier, and B2 is the second verification parameter.

[0227] S907. The third verification parameter is calculated based on the user's pseudo-identity information, cluster identifier, first parameter, second parameter and user identity identifier.

[0228] Specifically, the method for calculating the third verification parameter is as follows:

[0229] B3 = h(PID) i ∥AuID i ∥SID i ∥A5∥UID i ∥R5) Formula 22

[0230] Where SID1 is the authentication server identifier, and PID is the PID. i AuID is a pseudo-identity information for users. i This serves as the cluster identifier.

[0231] S908, Use the user's pseudo-identity information, cluster identifier, first verification parameter, second verification parameter, and third verification parameter as the user's identity information.

[0232] Using the method provided in this application, after the terminal completes registration, it locally stores user pseudo-identity information, cluster identifier, second parameter, and third parameter. Subsequently, when the terminal obtains the user's identity identifier and password, it can encrypt the user's identity identifier and password according to the aforementioned user pseudo-identity information, cluster identifier, second parameter, and third parameter, and send the encrypted information to the proxy server. This allows the proxy server to authenticate the terminal using the encrypted information, thereby ensuring the security of user information during the authentication process.

[0233] The following combination Figure 10 This section describes the complete process of authentication server authenticating a terminal, such as... Figure 10 As shown, the method includes:

[0234] S1001. The terminal obtains the user's identity and password input by the user, and calculates R3 and A1.

[0235] S1002, The terminal sends the user's pseudo-identity information, cluster identifier, B1, B2 and B3 to the authentication server.

[0236] The terminal locally stores the correspondence between user pseudo-identity information and cluster identifier. After obtaining the user identity identifier and user password, the terminal calculates B1, B2 and B3 according to the user identity identifier and user password. B1, B2 and B3 are the verification message sets constructed by the terminal. The authentication server can complete the terminal authentication based on B1, B2 and B3.

[0237] After calculating B1, B2, and B3, the terminal constructs a verification message set and sends it to the authentication server. This verification message set includes the user's pseudo-identity information, cluster identifier, and B1, B2, and B3.

[0238] S1003, the authentication server calculates B5, C1, C2, C3 and C4.

[0239] Specifically, the method by which the authentication server calculates B5, C1, C2, C3, and C4 is described in the relevant embodiments above.

[0240] S1004, The authentication server sends server pseudo-identity information, B5, C1, C2, C3 and C4 to the proxy server.

[0241] S1005. The proxy server determines whether the storage space contains the server's pseudo identity information. If not, the authentication terminal's identity authentication fails, and the user's file upload is rejected.

[0242] S1006. If included, calculate the target verification parameter. If the target verification parameter is the same as C4, the terminal identity authentication passes.

[0243] Specifically, the method for calculating the target verification parameters is described in the relevant embodiments above, and will not be repeated here.

[0244] Using the method provided in this application embodiment, the authentication server first authenticates the terminal and calculates the verification parameters based on the verification message set sent by the terminal. Based on the calculated verification parameters, the proxy server uses the locally stored authentication messages to authenticate the verification parameters, that is, it encrypts and authenticates the user identity information, thereby improving the accuracy of the authentication result and the security of the user identity information. Furthermore, data transmission is performed when the authentication is successful, ensuring the security of file transmission.

[0245] If the authentication server successfully authenticates the terminal, to conserve cloud disk storage resources, the proxy server can also perform deduplication on the uploaded content when uploading the file to be transferred. Specifically, the file to be transferred includes a content identifier and preset indicator parameters. Based on this, for the above S405, when the terminal authentication is successful, the transfer of the file to be transferred can be implemented as follows:

[0246] Step A: Calculate the hash value of each data block in the content to be transmitted based on the preset index parameters.

[0247] The proxy server can first calculate the size of the content to be transmitted based on preset index parameters, then determine the number of categories of the content to be transmitted based on the size of the content to be transmitted, then determine the hash value of the preset fixed data character length based on the number of categories, and finally calculate the overall hash value of the content to be transmitted.

[0248] Specifically, the size of the content to be transmitted can be calculated using formula 23:

[0249]

[0250] Where m represents the size of the content to be transmitted, s represents the number of contents to be transmitted, which can be determined directly based on the number of content identifiers; that is, the number of contents to be transmitted is determined by the number of different content identifiers. y q represents the length of the data string y in the content to be transmitted; y λ represents the frequency of y in the content to be transmitted; λ represents the critical value of the amount of content to be transmitted.

[0251] The number of categories of content to be transmitted is calculated using Formula 24:

[0252]

[0253] Where e represents the number of categories of content to be transmitted. When the data redundancy threshold is p y At that time, data with high access rates are categorized into different categories.

[0254] The hash value N corresponding to the preset fixed data string length of the content to be transmitted is calculated according to Formula 25:

[0255]

[0256] Where g represents the preset adjustment factor for the data redundancy threshold, and the value of g can be set according to actual business needs.

[0257] The hash value of the content to be transmitted is calculated using formula 26:

[0258]

[0259] Where D is the hash value of the content to be transmitted, and K (Q) This represents the data content stored on the cloud drive, where S represents the preset weighting coefficient. C represents the similarity between the content to be transferred and the data content stored on the cloud drive.

[0260] Step B: For each data block, use the hash value of the data block to calculate the content similarity between the data block and other data blocks in the content to be transmitted.

[0261] Specifically, the content similarity of data blocks can be calculated using formula 27:

[0262]

[0263] Among them, Z y W represents the internal discrete values ​​of the data in the file to be transmitted; y The preset weights represent the internal discrete values.

[0264] Specifically, the internal discrete values ​​of the data in the file to be transmitted can be calculated based on the range or coefficient of variation of the data in the file to be transmitted. This application embodiment does not limit the method for calculating the internal discrete values.

[0265] Step C: Delete data blocks with content similarity greater than a preset threshold to obtain the target transmission content.

[0266] Step D: Store the target content in the cloud disk storage space.

[0267] Using the method provided in this application embodiment, for each data block of the content to be transmitted, redundant data blocks, i.e. data blocks with duplicate data content, can be identified by calculating the similarity of hash values ​​between each data block. Therefore, the data blocks with duplicate data content are deleted, thereby ensuring a reduction in the amount of data in the transmitted file, thereby improving data transmission efficiency and saving cloud disk storage resources.

[0268] Furthermore, after the proxy server receives the file to be transferred uploaded by the terminal, it can add the data of the file to be transferred to the existing data in the proxy server's existing data file. Specifically, this can be implemented as follows:

[0269] The proxy server first determines the version and timestamp of the file to be transferred.

[0270] Specifically, it can be represented as: MD i →SN i :D ins (DBL new ,TS new );

[0271] Among them, MD i →SN i This indicates that the file to be transferred is sent from the terminal to the proxy server. (TS) new Indicates the timestamp of the user sending the authentication request; DBL new This indicates the content of the file to be transferred. (D) ins This is an operation identifier for transferring the file to be transferred. This operation identifier is used to indicate that the data of the file to be transferred will be added to the existing data of the existing data file on the proxy server.

[0272] The proxy server then determines the specific content of the file to be transferred based on the version and timestamp mentioned above.

[0273] Specifically, it can be represented as: MD i →SN i :D ins (D File ,b,DBL new ,TS new ),σ new ;

[0274] Where, σ new This represents the content identifier of the file to be transmitted, and can also be used as the name of the data block corresponding to the file to be transmitted. File This indicates the version of the file to be transferred. 'b' indicates the data block number.

[0275] Finally, the proxy server updates the version of the file in the cloud disk storage space based on the specific content of the file to be transferred, and determines the tag set.

[0276] Specifically, it can be expressed as:

[0277] Among them, TAG new This represents the tag set after the file to be transferred has been uploaded; D FileNew This represents the content of the newly generated cloud drive file; n db This indicates the amount of data in the cloud drive after the content is uploaded; Sig sk The signature key that indicates the new version of the content stored on the cloud drive.

[0278] Accordingly, when a user downloads a file from the cloud storage space, the terminal responds to the file identifier corresponding to the data file clicked by the user and sends a file download request to the proxy server. After receiving the file download request, the proxy server sends an authentication request to the authentication server. If the authentication server successfully authenticates the terminal, the proxy server retrieves the corresponding data file from the cloud storage space based on the file identifier.

[0279] It should be noted that during the file download process, the proxy server does not need to deduplicate the downloaded content, nor does it need to update the data in the cloud storage space.

[0280] The following combination Figure 11 This application describes a file transfer method provided in its embodiments, such as... Figure 11 As shown, Figure 11 The file upload process is illustrated in the example, specifically including:

[0281] S1101. The user logs into the cloud drive app on the client, clicks the upload icon on the cloud drive app's homepage, and sends a file upload request to the proxy server corresponding to the cloud drive app.

[0282] S1102. After receiving the file upload request sent by the terminal, the proxy server sends an authentication request to the authentication server so that the authentication server can assist the proxy server in authenticating the terminal.

[0283] S1103. After the terminal identity authentication is successful, the proxy server performs deduplication processing on the content to be uploaded based on the content identifier of the content to be uploaded.

[0284] S1104. After deduplicating the content to be uploaded, upload the file to the cloud drive and update the cloud drive content according to the preset method.

[0285] Using the method provided in this application, after receiving a file upload request from a terminal, the proxy server can call the authentication server to authenticate the terminal, ensuring the legitimacy of the terminal and the security of data transmission. Furthermore, if the terminal authentication is successful, the proxy server can also perform deduplication on the content identifier of the content to be uploaded, thereby saving cloud disk storage resources.

[0286] Based on the same concept, embodiments of this application provide a file transfer apparatus applied to a proxy server, such as... Figure 12 As shown, the device includes:

[0287] The receiving module 1201 is used to receive an authentication request sent by the terminal, wherein the authentication request carries user identity information and a file to be transmitted;

[0288] The query module 1202 is used to query the authentication information corresponding to the user identity information in the database;

[0289] The calculation module 1203 is used to calculate the verification parameters corresponding to the user identity information based on the authentication information and the preset authentication algorithm.

[0290] Authentication module 1204 is used to authenticate the terminal based on the verification parameters;

[0291] The transmission module 1205 is used to transmit the file to be transmitted when the terminal is successfully authenticated.

[0292] In one possible implementation, the device further includes:

[0293] The receiving module 1201 is further configured to receive a user identity identifier, a user password, and a first parameter sent by the terminal; the first parameter is generated by the terminal based on the user password and a first random number.

[0294] The determination module is used to determine whether the database includes the user identity identifier;

[0295] The generation module is used to generate pseudo-identity information of the user identity corresponding to the user identity if the user identity is not included in the database.

[0296] The generation module is also used to generate a second random number;

[0297] The storage module is used to store the correspondence between the second random number, the first parameter, the user pseudo-identity information, and the user identity identifier in the database.

[0298] In one possible implementation, the device further includes:

[0299] The generation module is also used to generate a second parameter and a third parameter based on the first parameter and the second random number;

[0300] The sending module is configured to send the second parameter, the third parameter, the user pseudo-identity information, and the cluster identifier of the authentication server cluster in the proxy server to the terminal, so that the terminal can calculate a fourth parameter based on the user identity identifier, the user password, and the first random number, calculate a first verification parameter based on the first parameter and the second parameter, calculate a second verification parameter based on the user identity identifier, and calculate a third verification parameter based on the user pseudo-identity information, the cluster identifier, the first parameter, the second parameter, and the user identity identifier.

[0301] In one possible implementation, the authentication information includes a user identity identifier, a first random number, and a first parameter; the user identity information includes user pseudo-identity information, a cluster identifier, a first verification parameter, a second verification parameter, and a third verification parameter; the calculation module 1203 is specifically used for:

[0302] The first verification parameter is calculated based on the user pseudo-identity information, the first verification parameter, the second verification parameter, the cluster identifier, the third random number, the first parameter, and the user identity identifier;

[0303] The second verification parameter is calculated based on the pseudo-identity information of the proxy server.

[0304] The third verification parameter is calculated based on the user pseudo-identity information, the first verification parameter, the second verification parameter, the cluster identifier, the third random number, and the first parameter;

[0305] Based on the user pseudo-identity information, the second verification parameter, the third verification parameter, the second verification parameter, the user identity identifier, the first verification parameter, the third random number, the first parameter, and the cluster identifier, the fourth verification parameter is calculated.

[0306] Authentication module 1204 is specifically used for:

[0307] The terminal is authenticated based on the first verification parameter, the second verification parameter, the third verification parameter, and the fourth verification parameter.

[0308] In one possible implementation, the proxy server includes an authentication server; the receiving module 1201 is further configured to receive the authentication server identifier, the cluster identifier of the cluster to which the authentication server belongs, and the private key corresponding to the authentication server sent by the authentication server.

[0309] The generation module is also used to generate a shared key based on the proxy server identifier, the private key, and the authentication server identifier;

[0310] The sending module is also used to send the shared key and the proxy server identifier to the authentication server, so that the authentication server can generate a third random number, a fourth random number and server pseudo-identity information corresponding to the proxy server;

[0311] The receiving module 1201 is further configured to receive the proxy server identifier, the shared key, the cluster identifier, the third random number, the fourth random number, and the server pseudo-identity information sent by the authentication server.

[0312] In one possible implementation, authentication module 1204 is specifically used for:

[0313] Obtain the pseudo-identity information of the server corresponding to the proxy server;

[0314] Determine whether the database contains the server's pseudo-identity information;

[0315] If the database includes the server pseudo-identity information, the target verification parameter is calculated based on the server pseudo-identity information, the first verification parameter, the second verification parameter, the third verification parameter, the first parameter, the second random number, the fifth random number, the shared key, and the cluster identifier.

[0316] The step of transmitting the file to be transmitted after the terminal authentication is successful includes:

[0317] If the target verification parameter and the fourth verification parameter are the same, the file to be transmitted is transmitted.

[0318] In one possible implementation, the file to be transmitted includes a content identifier and preset index parameters; the transmission module 1205 is used for:

[0319] The hash value of each data block in the content to be transmitted is calculated based on the preset index parameters.

[0320] For each data block, the hash value of the data block is used to calculate the content similarity between the data block and other data blocks in the content to be transmitted;

[0321] Delete data blocks whose content similarity is greater than a preset threshold to obtain the target transmission content;

[0322] The target transmitted content is stored in the cloud disk storage space.

[0323] It should be noted that the device for file transfer is the same as the method for file transfer applied to the authentication server described above. All implementation methods in the above method embodiments are applicable to the embodiments of this device and can achieve the same technical effect.

[0324] Based on the same concept, this application provides a file transfer device applied to a terminal, such as... Figure 13 As shown, the device includes:

[0325] Module 1301 is used to obtain user identity information and the file to be transferred;

[0326] The sending module 1302 is used to send an authentication request carrying the user's identity information and the file to be transmitted to the authentication server. The authentication request is used to instruct the authentication server to obtain the authentication information corresponding to the user's identity information from the database, calculate the verification parameters corresponding to the user's identity information based on the authentication information and a preset authentication algorithm, and send a verification request carrying the verification parameters to the proxy server. The verification request is used to instruct the proxy server to authenticate the terminal based on the verification parameters.

[0327] In one possible implementation, the device further includes:

[0328] The acquisition module 1301 is also used to acquire user identity information and user password;

[0329] The calculation module is used to calculate the hash value of the user password and the first random number to obtain the first parameter;

[0330] The sending module 1302 is further configured to send the first parameter, the user identity identifier, and the user password to the proxy server, so that the proxy server can determine that if the user identity identifier is not included in the database, generate user pseudo-identity information corresponding to the user identity identifier, and generate a second random number, and store the correspondence between the second random number, the first parameter, the user pseudo-identity information, and the user identity identifier in the database;

[0331] The receiving module is used to receive the second parameter, the third parameter, the user pseudo-identity information, and the cluster identifier of the cluster to which the authentication server in the proxy server belongs, all sent by the proxy server. The second parameter and the third parameter are generated by the proxy server based on the first parameter and the second random number.

[0332] The calculation module is further configured to calculate a first verification parameter based on the first parameter and the second parameter; calculate a second verification parameter based on the user identity identifier; and calculate a third verification parameter based on the user pseudo-identity information, the cluster identifier, the first parameter, the second parameter, and the user identity identifier.

[0333] The determination module is used to use the user pseudo-identity information, the cluster identifier, the first verification parameter, the second verification parameter, and the third verification parameter as the user identity information.

[0334] It should be noted that the device for file transfer is the same as the method for file transfer applied to the terminal described above. All implementation methods in the above method embodiments are applicable to the embodiments of this device and can achieve the same technical effect.

[0335] Figure 14 A schematic diagram of the hardware structure of the electronic device provided in an embodiment of this application is shown.

[0336] An electronic device may include a processor 1401 and a memory 1402 storing computer program instructions.

[0337] Specifically, the processor 1401 may include a central processing unit (CPU), an application-specific integrated circuit (ASIC), or one or more integrated circuits that can be configured to implement the embodiments of this application.

[0338] Memory 1402 may include mass storage for data or instructions. For example, and not limitingly, memory 1402 may include a hard disk drive (HDD), floppy disk drive, flash memory, optical disk, magneto-optical disk, magnetic tape, or Universal Serial Bus (USB) drive, or a combination of two or more of these. Where appropriate, memory 1402 may include removable or non-removable (or fixed) media. Where appropriate, memory 1402 may be internal or external to the integrated gateway disaster recovery device. In a particular embodiment, memory 1402 is non-volatile solid-state memory.

[0339] Memory may include read-only memory (ROM), random access memory (RAM), disk storage media devices, optical storage media devices, flash memory devices, and electrical, optical, or other physical / tangible memory storage devices. Therefore, typically, memory includes one or more tangible (non-transitory) computer-readable storage media (e.g., memory devices) encoded with software including computer-executable instructions, and when the software is executed (e.g., by one or more processors), it is operable to perform the operations described with reference to the methods according to one aspect of this disclosure.

[0340] The processor 121401 implements any of the file transfer methods described in the above embodiments by reading and executing computer program instructions stored in the memory 1402.

[0341] In one example, the electronic device may also include a communication interface 1403 and a bus 1404. For example, Figure 14 As shown, the processor 1401, memory 1402, and communication interface 1203 are connected through bus 1404 and complete communication with each other.

[0342] The communication interface 1403 is mainly used to realize communication between various modules, devices, units and / or equipment in the embodiments of this application.

[0343] Bus 1404 includes hardware, software, or both, that couples components of an electronic device together. For example, and not limitingly, the bus may include an Accelerated Graphics Port (AGP) or other graphics bus, an Enhanced Industry Standard Architecture (EISA) bus, a Front Side Bus (FSB), HyperTransport (HT) interconnect, an Industry Standard Architecture (ISA) bus, an Infinite Bandwidth Interconnect, a Low Pin Count (LPC) bus, a memory bus, a Microchannel Architecture (MCA) bus, a Peripheral Component Interconnect (PCI) bus, a PCI-Express (PCI-X) bus, a Serial Advanced Technology Attachment (SATA) bus, a Video Electronics Standards Association Local (VLB) bus, or other suitable buses, or combinations of two or more of these. Where appropriate, bus 1404 may include one or more buses. Although specific buses are described and illustrated in embodiments of this application, any suitable bus or interconnect is contemplated herein.

[0344] Furthermore, in conjunction with the file transfer methods described in the above embodiments, this application embodiment can provide a computer storage medium for implementation. This computer storage medium stores computer program instructions; when these computer program instructions are executed by a processor, they implement any of the file transfer methods described in the above embodiments.

[0345] In conjunction with the file transfer methods in the above embodiments, this application embodiment can provide a computer program product, in which the instructions in the computer program product, when executed by the processor of an electronic device, cause the electronic device to perform any of the file transfer methods in the above embodiments.

[0346] It should be clarified that this application is not limited to the specific configurations and processes described above and shown in the figures. For the sake of brevity, detailed descriptions of known methods are omitted here. In the above embodiments, several specific steps are described and shown as examples. However, the method process of this application is not limited to the specific steps described and shown. Those skilled in the art can make various changes, modifications, and additions, or change the order of steps, after understanding the spirit of this application.

[0347] The functional blocks shown in the above-described structural diagram can be implemented as hardware, software, firmware, or a combination thereof. When implemented in hardware, they can be, for example, electronic circuits, application-specific integrated circuits (ASICs), appropriate firmware, plug-ins, function cards, etc. When implemented in software, the elements of this application are programs or code segments used to perform the required tasks. Programs or code segments can be stored on a machine-readable medium or transmitted over a transmission medium or communication link via data signals carried on a carrier wave. "Machine-readable medium" can include any medium capable of storing or transmitting information. Examples of machine-readable media include electronic circuits, semiconductor memory devices, ROM, flash memory, erasable ROM (EROM), floppy disks, CD-ROMs, optical disks, hard disks, fiber optic media, radio frequency (RF) links, etc. Code segments can be downloaded via computer networks such as the Internet, intranets, etc.

[0348] It should also be noted that the exemplary embodiments mentioned in this application describe methods or systems based on a series of steps or apparatus. However, this application is not limited to the order of the above steps; that is, the steps can be performed in the order mentioned in the embodiments, or in a different order, or several steps can be performed simultaneously.

[0349] The aspects of this disclosure have been described above with reference to flowchart illustrations and / or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of this disclosure. It should be understood that each block in the flowchart illustrations and / or block diagrams, and combinations of blocks in the flowchart illustrations and / or block diagrams, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, or other programmable data processing apparatus to produce a machine such that these instructions, executable via the processor of the computer or other programmable data processing apparatus, enable the implementation of the functions / actions specified in one or more blocks of the flowchart illustrations and / or block diagrams. Such a processor can be, but is not limited to, a general-purpose processor, a special-purpose processor, a special application processor, or a field-programmable logic circuit. It is also understood that each block in the block diagrams and / or flowcharts, and combinations of blocks in the block diagrams and / or flowcharts, can also be implemented by special-purpose hardware performing the specified functions or actions, or can be implemented by a combination of special-purpose hardware and computer instructions.

[0350] The above description is merely a specific implementation of this application. Those skilled in the art will clearly understand that, for the sake of convenience and brevity, the specific working processes of the systems, modules, and units described above can be referred to the corresponding processes in the foregoing method embodiments, and will not be repeated here. It should be understood that the protection scope of this application is not limited thereto. Any person skilled in the art can easily conceive of various equivalent modifications or substitutions within the technical scope disclosed in this application, and these modifications or substitutions should all be covered within the protection scope of this application.

Claims

1. A method for file transfer, characterized in that, Applied to a proxy server, the method includes: The terminal receives an authentication request, which carries user identity information and a file to be transmitted. The authentication information corresponding to the user identity information is retrieved from the database; the authentication information includes a user identity identifier, a first random number, and a first parameter; the user identity information includes user pseudo-identity information, a cluster identifier, a first verification parameter, a second verification parameter, and a third verification parameter; the first parameter is generated by the terminal based on the user password and the first random number; the cluster identifier is the identifier of the cluster to which the authentication server in the proxy server belongs; The first verification parameter is calculated based on the user pseudo-identity information, the first verification parameter, the second verification parameter, the cluster identifier, the third random number, the first parameter, and the user identity identifier; The second verification parameter is calculated based on the pseudo-identity information of the proxy server. The third verification parameter is calculated based on the user pseudo-identity information, the first verification parameter, the second verification parameter, the cluster identifier, the third random number, and the first parameter; Based on the user pseudo-identity information, the second verification parameter, the third verification parameter, the second verification parameter, the user identity identifier, the first verification parameter, the third random number, the first parameter, and the cluster identifier, the fourth verification parameter is calculated. Obtain the pseudo-identity information of the server corresponding to the proxy server; Determine whether the database contains the server's pseudo-identity information; If the database includes the server pseudo-identity information, the target verification parameter is calculated based on the server pseudo-identity information, the first verification parameter, the second verification parameter, the third verification parameter, the first parameter, the second random number, the fifth random number, the shared key, and the cluster identifier. If the target verification parameter and the fourth verification parameter are the same, the file to be transmitted is transmitted.

2. The method according to claim 1, characterized in that, Before retrieving the authentication information corresponding to the user's identity information from the database, the method further includes: Receive the user identity identifier, user password and the first parameter sent by the terminal; Determine whether the database contains the user's identity identifier; If the user identity identifier is not included in the database, generate the user pseudo-identity information corresponding to the user identity identifier; Generate the second random number; The database stores the correspondence between the second random number, the first parameter, the user pseudo-identity information, and the user identity identifier.

3. The method according to claim 2, characterized in that, After storing the correspondence between the second random number, the first parameter, the user pseudo-identity information, and the user identity identifier in the database, the method further includes: Generate a second parameter and a third parameter based on the first parameter and the second random number; The terminal sends the second parameter, the third parameter, the user pseudo-identity information, and the cluster identifier of the authentication server cluster in the proxy server to the terminal, so that the terminal can calculate a fourth parameter based on the user identity identifier, the user password, and the first random number, calculate a first verification parameter based on the first parameter and the second parameter, calculate a second verification parameter based on the user identity identifier, and calculate a third verification parameter based on the user pseudo-identity information, the cluster identifier, the first parameter, the second parameter, and the user identity identifier.

4. The method according to claim 1, characterized in that, The proxy server includes an authentication server; Before retrieving the authentication information corresponding to the user's identity information from the database, the method further includes: Receive the authentication server identifier, the cluster identifier of the cluster to which the authentication server belongs, and the private key corresponding to the authentication server from the authentication server; A shared key is generated based on the proxy server identifier, the private key, and the authentication server identifier; The shared key and the proxy server identifier are sent to the authentication server for the authentication server to generate the third random number, the fourth random number, and the server pseudo-identity information corresponding to the proxy server. The system receives the proxy server identifier, the shared key, the cluster identifier, the third random number, the fourth random number, and the server pseudo-identity information sent by the authentication server.

5. The method according to claim 1, characterized in that, The file to be transmitted includes a content identifier and preset index parameters; the transmission of the file to be transmitted includes: The hash value of each data block in the content to be transmitted is calculated based on the preset index parameters. For each data block, the hash value of the data block is used to calculate the content similarity between the data block and other data blocks in the content to be transmitted; Delete data blocks whose content similarity is greater than a preset threshold to obtain the target transmission content; The target transmitted content is stored in the cloud disk storage space.

6. A method for file transfer, characterized in that, Applied to a terminal, the method includes: Obtain user identity information and the file to be transferred; An authentication request carrying the user's identity information and the file to be transferred is sent to the proxy server. The authentication request instructs the proxy server to retrieve authentication information corresponding to the user's identity information from the database. The authentication information includes a user identity identifier, a first random number, and a first parameter. The user identity information includes user pseudo-identity information, a cluster identifier, a first verification parameter, a second verification parameter, and a third verification parameter. The first parameter is generated by the terminal based on the user password and the first random number. The cluster identifier is the identifier of the cluster to which the authentication server in the proxy server belongs. A first verification parameter is calculated based on the user pseudo-identity information, the first verification parameter, the second verification parameter, the cluster identifier, the third random number, the first parameter, and the user identity identifier. A second verification parameter is calculated based on the proxy server's server pseudo-identity information. A third verification parameter is calculated based on the user pseudo-identity information, the first verification parameter, and the first verification parameter. The second verification parameter, the cluster identifier, the third random number, and the first parameter are used to calculate the third verification parameter; based on the user pseudo-identity information, the second verification parameter, the third verification parameter, the second verification parameter, the user identity identifier, the first verification parameter, the third random number, the first parameter, and the cluster identifier, the fourth verification parameter is calculated; the server pseudo-identity information corresponding to the proxy server is obtained; it is determined whether the database includes the server pseudo-identity information; if the database includes the server pseudo-identity information, the target verification parameter is calculated based on the server pseudo-identity information, the first verification parameter, the second verification parameter, the third verification parameter, the first parameter, the second random number, the fifth random number, the shared key, and the cluster identifier; if the target verification parameter and the fourth verification parameter are the same, the file to be transmitted is transmitted.

7. The method according to claim 6, characterized in that, Before obtaining user identity information and the file to be transferred, the method further includes: Obtain user identification and user password; Calculate the hash value of the user password and the first random number to obtain the first parameter; The proxy server sends the first parameter, the user identity identifier, and the user password to the proxy server so that the proxy server can determine whether the user identity identifier is not included in the database, generate user pseudo identity information corresponding to the user identity identifier, and generate a second random number. The correspondence between the second random number, the first parameter, the user pseudo identity information, and the user identity identifier is stored in the database. The proxy server receives a second parameter, a third parameter, the user's pseudo-identity information, and the cluster identifier of the cluster to which the authentication server in the proxy server belongs. The second parameter and the third parameter are generated by the proxy server based on the first parameter and the second random number. The first verification parameter is calculated based on the first parameter and the second parameter; The second verification parameter is calculated based on the user's identity identifier; The third verification parameter is calculated based on the user pseudo-identity information, the cluster identifier, the first parameter, the second parameter, and the user identity identifier; The user pseudo-identity information, the cluster identifier, the first verification parameter, the second verification parameter, and the third verification parameter are used as the user identity information.

8. A file transfer device, characterized in that, Applied to a proxy server, the device includes: The receiving module is used to receive an authentication request sent by the terminal, wherein the authentication request carries user identity information and a file to be transmitted; The query module is used to query the authentication information corresponding to the user identity information in the database; the authentication information includes a user identity identifier, a first random number, and a first parameter; the user identity information includes user pseudo-identity information, a cluster identifier, a first verification parameter, a second verification parameter, and a third verification parameter; the first parameter is generated by the terminal based on the user password and the first random number; the cluster identifier is the identifier of the cluster to which the authentication server in the proxy server belongs; The calculation module is used to calculate the first verification parameter based on the user pseudo-identity information, the first verification parameter, the second verification parameter, the cluster identifier, the third random number, the first parameter, and the user identity identifier; The calculation module is also used to calculate the second verification parameter based on the server pseudo-identity information of the proxy server; The calculation module is further configured to calculate a third verification parameter based on the user pseudo-identity information, the first verification parameter, the second verification parameter, the cluster identifier, the third random number, and the first parameter; The calculation module is further configured to calculate a fourth verification parameter based on the user pseudo-identity information, the second verification parameter, the third verification parameter, the second verification parameter, the user identity identifier, the first verification parameter, the third random number, the first parameter, and the cluster identifier; The acquisition module is used to acquire the pseudo-identity information of the server corresponding to the proxy server; The judgment module is used to determine whether the database contains the server's pseudo-identity information; The calculation module is further configured to, when the database includes the server pseudo-identity information, calculate the target verification parameter based on the server pseudo-identity information, the first verification parameter, the second verification parameter, the third verification parameter, the first parameter, the second random number, the fifth random number, the shared key, and the cluster identifier. The transmission module is used to transmit the file to be transmitted when the target verification parameter and the fourth verification parameter are the same.

9. A file transfer device, characterized in that, Applied to a terminal, the device includes: The acquisition module is used to acquire user identity information and the file to be transferred; The sending module is configured to send an authentication request carrying the user's identity information and the file to be transmitted to the proxy server. The authentication request instructs the proxy server to retrieve authentication information corresponding to the user's identity information from the database. The authentication information includes a user identity identifier, a first random number, and a first parameter. The user identity information includes user pseudo-identity information, a cluster identifier, a first verification parameter, a second verification parameter, and a third verification parameter. The first parameter is generated by the terminal based on the user's password and the first random number. The cluster identifier is the identifier of the cluster to which the authentication server in the proxy server belongs. The first verification parameter is calculated based on the user pseudo-identity information, the first verification parameter, the second verification parameter, the cluster identifier, the third random number, the first parameter, and the user identity identifier. The second verification parameter is calculated based on the proxy server's server pseudo-identity information. The third verification parameter is calculated based on the user pseudo-identity information, the first verification parameter, the second verification parameter, the third random number, the first parameter, and the user identity identifier. The third verification parameter is calculated using the authentication parameter, the second verification parameter, the cluster identifier, the third random number, and the first parameter. A fourth verification parameter is calculated based on the user pseudo-identity information, the second verification parameter, the third verification parameter, the second verification parameter, the user identity identifier, the first verification parameter, the third random number, the first parameter, and the cluster identifier. The server pseudo-identity information corresponding to the proxy server is obtained. It is determined whether the database includes the server pseudo-identity information. If the database includes the server pseudo-identity information, a target verification parameter is calculated based on the server pseudo-identity information, the first verification parameter, the second verification parameter, the third verification parameter, the first parameter, the second random number, the fifth random number, the shared key, and the cluster identifier. If the target verification parameter and the fourth verification parameter are the same, the file to be transmitted is transmitted.

10. An electronic device, characterized in that, The device includes: a processor and a memory storing computer program instructions; When the processor executes the computer program instructions, it implements the file transfer method as described in any one of claims 1-5 or 6-7.

11. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores computer program instructions that, when executed by a processor, implement the file transfer method as described in any one of claims 1-5 or 6-7.

12. A computer program product, characterized in that, When the instructions in the computer program product are executed by the processor of the electronic device, the electronic device causes the electronic device to perform the file transfer method as described in any one of claims 1-5 or 6-7.