CN112463749A - File sharing method, device, medium and electronic equipment - Google Patents

File sharing method, device, medium and electronic equipment Download PDF

Info

Publication number
CN112463749A
CN112463749A CN202011411726.6A CN202011411726A CN112463749A CN 112463749 A CN112463749 A CN 112463749A CN 202011411726 A CN202011411726 A CN 202011411726A CN 112463749 A CN112463749 A CN 112463749A
Authority
CN
China
Prior art keywords
form data
hash value
password
target user
login information
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202011411726.6A
Other languages
Chinese (zh)
Inventor
逯义东
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Ping An Puhui Enterprise Management Co Ltd
Original Assignee
Ping An Puhui Enterprise Management Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Ping An Puhui Enterprise Management Co Ltd filed Critical Ping An Puhui Enterprise Management Co Ltd
Priority to CN202011411726.6A priority Critical patent/CN112463749A/en
Publication of CN112463749A publication Critical patent/CN112463749A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/10File systems; File servers
    • G06F16/17Details of further file system functions
    • G06F16/176Support for shared access to files; File sharing support
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F21/00Security arrangements for protecting computers, components thereof, programs or data against unauthorised activity
    • G06F21/60Protecting data
    • G06F21/62Protecting access to data via a platform, e.g. using keys or access control rules
    • G06F21/6218Protecting access to data via a platform, e.g. using keys or access control rules to a system of files or objects, e.g. local or distributed file system or database
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F21/00Security arrangements for protecting computers, components thereof, programs or data against unauthorised activity
    • G06F21/60Protecting data
    • G06F21/64Protecting data integrity, e.g. using checksums, certificates or signatures

Abstract

The disclosure relates to the field of identity authentication, and discloses a file sharing method, a file sharing device, a file sharing medium and electronic equipment. The method comprises the following steps: acquiring first login information and a first password from a target user; executing the step of generating a hash value based on the first login information to obtain a first hash value; acquiring second login information from a target user; executing the step of generating a hash value based on the second login information and the additional character string to obtain a second hash value; if the first hash value is consistent with the second hash value, pushing a password verification entry to the terminal where the target user is located; acquiring a second password sent by the target user through the password authentication entrance; and if the second password is consistent with the first password, generating a file sharing link or providing an entrance for extracting network file resources for the target user. Under the method, the file sharing safety can be improved, the data safety is ensured, and the hidden danger of data leakage is reduced.

Description

File sharing method, device, medium and electronic equipment
Technical Field
The present disclosure relates to the field of identity authentication technologies, and in particular, to a file sharing method, apparatus, medium, and electronic device.
Background
In the related art, files inside enterprises or personal files are not encrypted, or the encryption mode is too simple and easy to crack, so that the risk of file leakage is caused in the process of external sharing and internal sharing.
Disclosure of Invention
In the technical field of identity authentication, to solve the above technical problems, an object of the present disclosure is to provide a file sharing method, apparatus, medium, and electronic device.
According to an aspect of the present disclosure, there is provided a file sharing method, the method including:
acquiring first login information and a first password from a target user;
executing a hash value generating step based on the first login information to obtain a first hash value, wherein the hash value generating step comprises: generating form data corresponding to login information, wherein each form data comprises a data name and a parameter value corresponding to the data name; sorting the form data according to a preset rule based on data names included in the form data; splicing the sorted form data and the additional character strings to obtain spliced form data; performing hash operation on the spliced form data to obtain a hash value;
acquiring second login information from a target user;
executing the step of generating the hash value based on the second login information and the additional character string to obtain a second hash value;
if the first hash value is consistent with the second hash value, pushing a password verification entry to the terminal where the target user is located;
acquiring a second password sent by the target user through the password authentication entrance;
and if the second password is consistent with the first password, generating a file sharing link or providing an entrance for extracting network file resources for the target user.
According to another aspect of the present disclosure, there is provided a file sharing apparatus, the apparatus including:
the first acquisition module is configured to acquire first login information and a first password from a target user;
a first execution module configured to execute a hash value generation step based on the first login information, resulting in a first hash value, the hash value generation step comprising: generating form data corresponding to login information, wherein each form data comprises a data name and a parameter value corresponding to the data name; sorting the form data according to a preset rule based on data names included in the form data; splicing the sorted form data and the additional character strings to obtain spliced form data; performing hash operation on the spliced form data to obtain a hash value;
the second acquisition module is configured to acquire second login information from the target user;
a second execution module configured to execute the step of generating a hash value based on the second login information and the additional character string, resulting in a second hash value;
the pushing module is configured to push a password verification entry to the terminal where the target user is located if the first hash value is consistent with the second hash value;
a third obtaining module configured to obtain a second password sent by the target user through the password authentication entry;
and the generating and providing module is configured to generate a file sharing link or provide an entrance for extracting network file resources to the target user if the second password is consistent with the first password.
According to another aspect of the present disclosure, there is provided a computer-readable storage medium storing computer-readable instructions which, when executed by a computer, cause the computer to perform the method as described above.
According to another aspect of the present disclosure, there is provided an electronic apparatus including:
a processor;
a memory having computer readable instructions stored thereon which, when executed by the processor, implement the method as previously described.
The technical scheme provided by the embodiment of the disclosure can have the following beneficial effects:
the file sharing method provided by the disclosure comprises the following steps: acquiring first login information and a first password from a target user; executing a hash value generating step based on the first login information to obtain a first hash value, wherein the hash value generating step comprises: generating form data corresponding to login information, wherein each form data comprises a data name and a parameter value corresponding to the data name; sorting the form data according to a preset rule based on data names included in the form data; splicing the sorted form data and the additional character strings to obtain spliced form data; performing hash operation on the spliced form data to obtain a hash value; acquiring second login information from a target user; executing the step of generating the hash value based on the second login information and the additional character string to obtain a second hash value; if the first hash value is consistent with the second hash value, pushing a password verification entry to the terminal where the target user is located; acquiring a second password sent by the target user through the password authentication entrance; and if the second password is consistent with the first password, generating a file sharing link or providing an entrance for extracting network file resources for the target user.
Under the method, identity verification is carried out on a target user by utilizing two steps of generating the hash value, and secondary verification is carried out on the target user by utilizing the password on the basis, and the two verification processes can be used for a link for sharing files by utilizing the file sharing link and can also be used for acquiring network file resources according to the file sharing link, so that the security during file sharing is effectively improved, the data safety is ensured, and the hidden danger of data leakage is reduced.
It is to be understood that both the foregoing general description and the following detailed description are exemplary and explanatory only and are not restrictive of the invention, as claimed.
Drawings
The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the invention and together with the description, serve to explain the principles of the invention.
FIG. 1 is a system architecture diagram illustrating a method of file sharing in accordance with an exemplary embodiment;
FIG. 2 is a flow diagram illustrating a method of file sharing in accordance with an exemplary embodiment;
FIG. 3 is a flow diagram of the step of generating a hash value according to one embodiment shown in the embodiment of FIG. 2;
FIG. 4 is a detailed flowchart of step 320 according to one embodiment shown in the FIG. 3 embodiment;
FIG. 5 is a block diagram illustrating a file sharing arrangement in accordance with an exemplary embodiment;
fig. 6 is a block diagram illustrating an example of an electronic device implementing the file sharing method according to an example embodiment;
fig. 7 illustrates a computer-readable storage medium implementing the file sharing method according to an exemplary embodiment.
Detailed Description
Reference will now be made in detail to the exemplary embodiments, examples of which are illustrated in the accompanying drawings. When the following description refers to the accompanying drawings, like numbers in different drawings represent the same or similar elements unless otherwise indicated. The embodiments described in the following exemplary embodiments do not represent all embodiments consistent with the present invention. Rather, they are merely examples of apparatus and methods consistent with certain aspects of the invention, as detailed in the appended claims.
Furthermore, the drawings are merely schematic illustrations of the present disclosure and are not necessarily drawn to scale. The same reference numerals in the drawings denote the same or similar parts, and thus their repetitive description will be omitted. Some of the block diagrams shown in the figures are functional entities and do not necessarily correspond to physically or logically separate entities.
The present disclosure first provides a file sharing method. The file sharing refers to a process of providing various file extraction entries to others through a network, and extracting files from the extraction entries by others. The format of the files herein may be arbitrary, including but not limited to text files, video files, image files, executable files, and the like. In a traditional mode, a file sharer directly provides a file extraction entry for a file demander in the file sharing process, and the mode has potential safety hazards for both the file sharer and the file demander, for example, a lawbreaker may pretend to share files which are not to be shared outwards by the file sharer, and the lawbreaker may pretend to be the file demander to acquire files which are not to be shared by the lawbreaker and the like.
The implementation terminal of the present disclosure may be any device having computing, processing, and communication functions, which may be connected to an external device for receiving or sending data, and specifically may be a portable mobile device, such as a smart phone, a tablet computer, a notebook computer, a pda (personal Digital assistant), or the like, or may be a fixed device, such as a computer device, a field terminal, a desktop computer, a server, a workstation, or the like, or may be a set of multiple devices, such as a physical infrastructure of cloud computing or a server cluster.
Optionally, the implementation terminal of the present disclosure may be a server or a physical infrastructure of cloud computing.
Fig. 1 is a schematic diagram of a system architecture of a file sharing method according to an exemplary embodiment. As shown in fig. 1, the system architecture includes a server 110 and a user terminal 120. The user terminal 120 is connected to the server 110 through a wired or wireless communication link, so that the user terminal 120 can transmit data to the server 110 and also can receive data from the server 110, and the server 110 is an implementation terminal in this embodiment. When the file sharing method provided by the present disclosure is applied to the system architecture shown in fig. 1, a specific process may be as follows: first, a target user registers an account on the server 110 through the user terminal 120 and via a communication link, and submits first login information and a first password in the form of a form; then, the server 110 will execute the step of generating a hash value based on the first login information, generate and store the first hash value; then, the target user may upload a file to the server 110 for storage by using the user terminal 120; when the target user wants to share the file stored in the server 110 to another person, the target user needs to submit the second login information to the server 110 through the user terminal 120 again; then, the server 110 generates a second hash value by using the second login information, and compares the second hash value with the first hash value; in the case that the second hash value is consistent with the first hash value, the server 110 will push a password authentication entry to the user terminal 120; the user terminal 120 submits the second password to the server 110 through the password authentication portal; finally, when the server 110 determines that the second password is consistent with the first password, a file sharing link is generated and pushed to the user terminal 120.
It is worth mentioning that fig. 1 is only one embodiment of the present disclosure. Although the embodiment of fig. 1 shows the implementation terminal as a server, in a specific application, the implementation terminal of the present disclosure may be various terminals or devices as described above; although in the above description of the specific process, the application scenario of the embodiment shown in fig. 1 is defined as a process of verifying the user identity to generate the file sharing link, in an actual scenario, the embodiment shown in fig. 1 may also be applied to a process of verifying the user identity before the user extracts the file. The embodiments of the present disclosure are not limited in this respect, and the scope of the present disclosure should not be limited thereby.
Fig. 2 is a flow diagram illustrating a file sharing method according to an example embodiment. This embodiment may be executed by a server, as shown in fig. 2, and includes the following steps:
step 210, obtaining first login information and a first password from a target user.
The first login information and the first password may be information generated at the time of user registration or provided by the user.
The first login information may include information such as a user name, a login password, a user IP address, etc., and the first password may be data of the same type as the login password, for example, the first password and the login password may both include english letters, numbers, characters, etc.
Step 220, executing the step of generating the hash value based on the first login information to obtain a first hash value.
Fig. 3 is a flowchart of the step of generating a hash value according to one embodiment shown in the embodiment of fig. 2. The specific steps related to the step of generating the hash value may be shown in fig. 3, please refer to fig. 3, where the step of generating the hash value specifically includes:
at step 310, form data corresponding to the login information is generated.
Each item of the form data comprises a data name and a parameter value corresponding to the data name.
The first login information and the first password can be submitted by a target user at a user side in a form mode, and form data can be correspondingly generated by the execution terminal of the disclosure after the first login information is submitted to the execution terminal of the disclosure.
For example, the first login information includes a user name of zhangsan, and the finally generated form data corresponding to the user name of zhangsan may be "username zhangsan".
And step 320, sorting the form data according to a preset rule based on the data name included in the form data.
In one embodiment, the sorting the items of form data according to a predetermined rule based on data names included in the items of form data includes:
and sequencing the form data according to the sequence of the characters in the data names in the preset word list.
In one embodiment, the specific steps of step 320 are shown in FIG. 4. Fig. 4 is a detailed flowchart of step 320 according to one embodiment shown in the fig. 3 embodiment. Referring to fig. 4, step 320 includes:
and 320', sorting the form data items from small to large according to the ASCII codes of the included data names.
In one embodiment, the sorting the items of form data from small to large according to the ASCII code of the included data name includes:
and selecting the form data with the minimum ASCII code of the first character of the included data name from each item of the form data, if the selected form data exceeds one, selecting the next character of the character on which the current form data is based as the first character, selecting the form data with the minimum ASCII code of the first character of the included data name from the selected form data again, and so on until one form data is selected, and using the form data as the form data with the minimum ASCII code of the first character of the included data name obtained by the selection at this time.
For example, there are four items of form data with data names u88ab, u78fd, u864a and v88ee, and first, since u ASCII code is smaller than v ASCII code, the first round selects the form data with the smallest ASCII code of the corresponding first character, and their corresponding data names u88ab, u78fd and u864 a; secondly, since the ASCII code of 7 is smaller than the ASCII code of 8, the data name corresponding to the form data with the smallest ASCII code of the first character selected in the second round is u78fd, and at this time, a form data, i.e., a form data with a data name of u78fd, is selected, and the form data is the form data obtained by this time selection.
In one embodiment, the sorting the items of form data according to a predetermined rule based on data names included in the items of form data includes:
dividing the characters into a plurality of priorities according to the size of the ASCII codes of the characters, so that the ASCII codes of the characters with smaller priorities are larger than the ASCII codes of the characters with larger priorities, and each priority corresponds to at least one character;
and sorting the form data of each item according to the priority of the first character of the included data name from large to small, and sorting the form data of each item with the first character of the included data name at the same priority according to the ASCII code of the included data name from large to small.
For example, if the first character of the data name included in the form data is a, b, c, d, e, f, if a and b are a priority, c and d are a priority, and e and f are a priority, then the priority of a and b is greater than that of c and d, and similarly, the priority of c and d is greater than that of e and f. If the form data is sorted in the manner of this embodiment, and if the form data is replaced with the first character of the data name included in the form data, after the form data is sorted from large to small according to the priority of the first character of the included data name, the sorting result may be a, b, c, d, e, f, and then after the form data of each item of the same priority is sorted from large to small according to the ASCII code of the included data name, the sorting result is b, a, d, c, f, e.
In this embodiment, the form data in which the first character of the included data name is ranked from large to small according to the priority of the first character of the included data name, and the form data in which the first character of the included data name is ranked at the same priority according to the ASCII code of the included data name, so that the ranking irregularity is increased, and the file sharing security is improved.
And 330, splicing the sorted form data and the additional character strings to obtain spliced form data.
In one embodiment, before the sorted form data is spliced with the additional character strings to obtain spliced form data, the method further includes:
randomly generating an additional character string;
the splicing the sorted form data and the additional character strings to obtain spliced form data comprises the following steps:
and splicing the last form data in the sorted form data with the additional character string to obtain spliced form data.
In this embodiment, the additional character string is spliced at the end of all the form data.
For example, if there are two items of form data, which are "three for username" and "123 for code", respectively, then the two items of form data may be "123 for code" and "three for username" after being sorted, and if the additional character string is abcde, then the form data obtained after being spliced may be:
code 123& username zhang triaabcde.
The additional character string may be generated randomly in various ways, such as directly randomly, or by randomly selecting a number of characters from a predetermined dictionary or character table.
In one embodiment, before the sorted form data is spliced with the additional character strings to obtain spliced form data, the method further includes:
randomly generating a corresponding additional character string for each item of the form data;
the splicing the sorted form data and the additional character strings to obtain spliced form data comprises the following steps:
and splicing each item of form data with the corresponding additional character string to obtain spliced form data.
In this embodiment, an additional character string is spliced after each form data item, so that the security of file sharing is improved.
When form data is spliced with additional character strings, the additional character strings can be spliced at any other position besides after all the form data or after each character string, for example, the additional character strings can be spliced before all the form data, or one additional character string can be spliced every several form data.
And 340, performing hash operation on the spliced form data to obtain a hash value.
The hash operation may also be referred to as a digest operation, and the hash operation herein may be implemented based on various hash algorithms. Such as may be implemented based on the MD5 algorithm.
Next, continuing with fig. 2.
Step 230, obtaining second login information from the target user.
The second login information is information submitted when the target user needs to share the file or obtain the file shared by others. The second login information is different from the first login information in that the two are information submitted at different stages.
Step 240, executing the step of generating a hash value based on the second login information and the additional character string to obtain a second hash value.
This step will re-perform the hash value generation step between steps 310-340 based on the second login information and the additional string.
In one embodiment, the first login information includes a target account number, and before acquiring the second login information from the target user, the method further includes:
correspondingly storing the target account, the additional character string and the first hash value;
the acquiring of the second login information from the target user includes:
acquiring second login information, wherein the second login information comprises an account;
if the account number is consistent with the target account number, determining that the second login information comes from the target user;
the step of generating a hash value is performed based on the second login information and the additional character string to obtain a second hash value, and the step of generating a hash value includes:
determining an additional character string stored corresponding to the account;
and executing the step of generating the hash value based on the second login information and the determined additional character string to obtain a second hash value.
In this embodiment, effective verification of the user is achieved by finding the corresponding stored additional character string according to the account and obtaining the second hash value based on the found additional character string.
Of course, it is also possible to find the additional character string using another character string that can be used to identify the user information, such as the user name, and store the character string and the additional character string and store the correspondence between the character string and the additional character string.
And step 250, if the first hash value is consistent with the second hash value, pushing a password authentication entry to the terminal where the target user is located.
Password authentication portals may exist in various ways, such as pages, windows, and the like.
And step 260, acquiring a second password sent by the target user through the password authentication entrance.
For example, the target user may submit the second password in the form of a form entry box.
Step 270, if the second password is consistent with the first password, generating a file sharing link or providing an entry for extracting network file resources to the target user.
The file sharing link is a link generated for a user who wants to share the file outwards, and other people can extract network file resources by using the file sharing link; the entry for extracting the network file resource is established based on the file sharing link and can be used for directly extracting the network file resource, for example, the entry for extracting the network file resource may include a download button, and the network file resource can be downloaded by clicking the download button.
In one embodiment, the method further comprises:
and if the first hash value is inconsistent with the second hash value or the second password is inconsistent with the first password, returning prompting information representing that the identity is illegal.
In one embodiment, before obtaining the second login information from the target user, the method further comprises:
acquiring a file to be shared uploaded by the target user;
if the second password is consistent with the first password, generating a file sharing link or providing an entry for extracting network file resources to the target user, including:
and if the second password is consistent with the first password, generating a file sharing link corresponding to the file to be shared.
In this embodiment, the target user is a user who uploads a file to be shared and makes a corresponding link for the shared file, so that the embodiment performs identity verification on a user who wants to share the file outwards, performs password verification again when the identity verification is successful, and generates a file sharing link for the user and shares the file only when the verification is successful, thereby improving the security when the user uploads the file and shares the file.
In one embodiment, after obtaining the file to be shared uploaded by the target user, the method further includes:
storing the file to be shared to a preset file path and distributing a file identifier for the file to be shared;
if the second password is consistent with the first password, generating a file sharing link corresponding to the file to be shared, including:
and if the second password is consistent with the first password, generating a file sharing link corresponding to the file to be shared according to the preset file path and the file identification.
Specifically, the file sharing link may include a file identifier, a file path, and a corresponding relationship between the file identifier and the file path, where the file identifier may include a timestamp of a current time, a random number, and a letter with a predetermined length, the preset file path is a file address created for a corresponding file, and the corresponding relationship between the file identifier and the file path is a list index stored in a key value pair, for example: when the index of the file identifier is equal to 1, the index of the file path is equal to 1; when the index of the file identification is equal to 2, the index of the file path is equal to 2.
In one embodiment, before obtaining the second login information from the target user, the method further comprises:
acquiring a file sharing link uploaded by the target user;
if the second password is consistent with the first password, generating a file sharing link or providing an entry for extracting network file resources to the target user, including:
and if the second password is consistent with the first password, providing an entrance for extracting network file resources for the target user according to the file sharing link.
In this embodiment, the target user is a user who acquires the file resource by using the file sharing link, so that the user who wants to acquire the file resource is subjected to identity verification and password verification again under the condition that the identity verification is successful, and the user can acquire the file resource by using the file sharing link only under the condition that both the verification passes, so that the security of the user when acquiring the file resource provided by another person by using the file sharing link is improved.
In an embodiment, the file sharing link includes a first file identifier, a first file path, and correspondence information between the file identifier and the file path, and after the file sharing link uploaded by the target user is acquired, the method further includes:
analyzing the file sharing link to obtain a first file identifier, a first file path and corresponding relation information between the file identifier and the file path in the file sharing link;
determining a second file path corresponding to the first file identifier according to the first file identifier and the corresponding relation information between the file identifier and the file path;
if the second file path is consistent with the first file path and the second file path comprises a file with a file identifier of the first file identifier, determining that the file sharing link is legal;
if the second password is consistent with the first password, providing an entry for extracting network file resources to the target user according to the file sharing link, including:
and if the second password is consistent with the first password, providing an entrance for extracting the file from the first file path for the target user according to the file sharing link.
In the embodiment, the identity of the user who acquires the file resource by using the file sharing link is verified, and the validity of the file sharing link is also verified, so that the file sharing safety is effectively improved.
In summary, according to the file sharing method provided in the embodiment of fig. 2, the target user is authenticated by using two steps of generating the hash value, and on this basis, the password target user is further authenticated for the second time, and the two authentication processes may be used for both the link of sharing the file by using the file sharing link and the network file resource acquisition according to the file sharing link, so that the security of file sharing is effectively improved, the data security is ensured, and the hidden danger of data leakage is reduced.
The disclosure also provides a file sharing device, and the following embodiment of the device is disclosed.
Fig. 5 is a block diagram illustrating a file sharing apparatus according to an example embodiment. As shown in fig. 5, the apparatus 500 includes:
a first obtaining module 510 configured to obtain first login information and a first password from a target user;
a first executing module 520 configured to execute a hash value generating step based on the first login information, so as to obtain a first hash value, wherein the hash value generating step includes: generating form data corresponding to login information, wherein each form data comprises a data name and a parameter value corresponding to the data name; sorting the form data according to a preset rule based on data names included in the form data; splicing the sorted form data and the additional character strings to obtain spliced form data; performing hash operation on the spliced form data to obtain a hash value;
a second obtaining module 530 configured to obtain second login information from the target user;
a second executing module 540 configured to execute the step of generating a hash value based on the second login information and the additional character string, so as to obtain a second hash value;
a pushing module 550 configured to push a password authentication entry to the terminal where the target user is located if the first hash value is consistent with the second hash value;
a third obtaining module 560 configured to obtain a second password sent by the target user through the password authentication entry;
a generating and providing module 570 configured to generate a file sharing link or provide the target user with an access to extract a network file resource if the second password is consistent with the first password.
According to a third aspect of the present disclosure, there is also provided an electronic device capable of implementing the above method.
As will be appreciated by one skilled in the art, aspects of the present invention may be embodied as a system, method or program product. Thus, various aspects of the invention may be embodied in the form of: an entirely hardware embodiment, an entirely software embodiment (including firmware, microcode, etc.) or an embodiment combining hardware and software aspects that may all generally be referred to herein as a "circuit," module "or" system.
An electronic device 600 according to this embodiment of the invention is described below with reference to fig. 6. The electronic device 600 shown in fig. 6 is only an example, and should not bring any limitation to the functions and the scope of use of the embodiments of the present invention. As shown in fig. 6, the electronic device 600 is embodied in the form of a general purpose computing device. The components of the electronic device 600 may include, but are not limited to: the at least one processing unit 610, the at least one memory unit 620, and a bus 630 that couples the various system components including the memory unit 620 and the processing unit 610. Wherein the storage unit stores program code that is executable by the processing unit 610 such that the processing unit 610 performs the steps according to various exemplary embodiments of the present invention as described in the section "example methods" above in this specification. The storage unit 620 may include readable media in the form of volatile memory units, such as a random access memory unit (RAM)621 and/or a cache memory unit 622, and may further include a read only memory unit (ROM) 623. The storage unit 620 may also include a program/utility 624 having a set (at least one) of program modules 625, such program modules 625 including, but not limited to: an operating system, one or more application programs, other program modules, and program data, each of which, or some combination thereof, may comprise an implementation of a network environment. Bus 630 may be one or more of several types of bus structures, including a memory unit bus or memory unit controller, a peripheral bus, an accelerated graphics port, a processing unit, or a local bus using any of a variety of bus architectures. The electronic device 600 may also communicate with one or more external devices 800 (e.g., keyboard, pointing device, bluetooth device, etc.), with one or more devices that enable a user to interact with the electronic device 600, and/or with any devices (e.g., router, modem, etc.) that enable the electronic device 600 to communicate with one or more other computing devices. Such communication may occur via an input/output (I/O) interface 650, such as with a display unit 640. Also, the electronic device 600 may communicate with one or more networks (e.g., a Local Area Network (LAN), a Wide Area Network (WAN), and/or a public network such as the Internet) via the network adapter 660. As shown, the network adapter 660 communicates with the other modules of the electronic device 600 over the bus 630. It should be appreciated that although not shown in the figures, other hardware and/or software modules may be used in conjunction with the electronic device 600, including but not limited to: microcode, device drivers, redundant processing units, external disk drive arrays, RAID systems, tape drives, and data backup storage systems, among others.
Through the above description of the embodiments, those skilled in the art will readily understand that the exemplary embodiments described herein may be implemented by software, or by software in combination with necessary hardware. Therefore, the technical solution according to the embodiments of the present disclosure may be embodied in the form of a software product, which may be stored in a non-volatile storage medium (which may be a CD-ROM, a usb disk, a removable hard disk, etc.) or on a network, and includes several instructions to enable a computing device (which may be a personal computer, a server, a terminal device, or a network device, etc.) to execute the method according to the embodiments of the present disclosure.
According to a fourth aspect of the present disclosure, there is also provided a computer-readable storage medium storing computer-readable instructions which, when executed by a computer, cause the computer to perform the method described above in the present specification.
In some possible embodiments, aspects of the invention may also be implemented in the form of a program product comprising program code means for causing a terminal device to carry out the steps according to various exemplary embodiments of the invention described in the above section "exemplary methods" of the present description, when said program product is run on the terminal device.
Referring to fig. 7, a program product 700 for implementing the above method according to an embodiment of the present invention is described, which may employ a portable compact disc read only memory (CD-ROM) and include program code, and may be run on a terminal device, such as a personal computer. However, the program product of the present invention is not limited in this regard and, in the present document, a readable storage medium may be any tangible medium that can contain, or store a program for use by or in connection with an instruction execution system, apparatus, or device. The program product may employ any combination of one or more readable media. The readable medium may be a readable signal medium or a readable storage medium. A readable storage medium may be, for example, but not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination of the foregoing. More specific examples (a non-exhaustive list) of the readable storage medium include: an electrical connection having one or more wires, a portable disk, a hard disk, a Random Access Memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing. A computer readable signal medium may include a propagated data signal with readable program code embodied therein, for example, in baseband or as part of a carrier wave. Such a propagated data signal may take many forms, including, but not limited to, electro-magnetic, optical, or any suitable combination thereof. A readable signal medium may also be any readable medium that is not a readable storage medium and that can communicate, propagate, or transport a program for use by or in connection with an instruction execution system, apparatus, or device. Program code embodied on a readable medium may be transmitted using any appropriate medium, including but not limited to wireless, wireline, optical fiber cable, RF, etc., or any suitable combination of the foregoing. Program code for carrying out operations for aspects of the present invention may be written in any combination of one or more programming languages, including an object oriented programming language such as Java, C + + or the like and conventional procedural programming languages, such as the "C" programming language or similar programming languages. The program code may execute entirely on the user's computing device, partly on the user's device, as a stand-alone software package, partly on the user's computing device and partly on a remote computing device, or entirely on the remote computing device or server. In the case of a remote computing device, the remote computing device may be connected to the user computing device through any kind of network, including a Local Area Network (LAN) or a Wide Area Network (WAN), or may be connected to an external computing device (e.g., through the internet using an internet service provider).
Furthermore, the above-described figures are merely schematic illustrations of processes involved in methods according to exemplary embodiments of the invention, and are not intended to be limiting. It will be readily understood that the processes shown in the above figures are not intended to indicate or limit the chronological order of the processes. In addition, it is also readily understood that these processes may be performed synchronously or asynchronously, e.g., in multiple modules. It will be understood that the invention is not limited to the precise arrangements described above and shown in the drawings and that various modifications and changes may be made without departing from the scope thereof. The scope of the invention is limited only by the appended claims.

Claims (10)

1. A file sharing method, the method comprising:
acquiring first login information and a first password from a target user;
executing a hash value generating step based on the first login information to obtain a first hash value, wherein the hash value generating step comprises: generating form data corresponding to login information, wherein each form data comprises a data name and a parameter value corresponding to the data name; sorting the form data according to a preset rule based on data names included in the form data; splicing the sorted form data and the additional character strings to obtain spliced form data; performing hash operation on the spliced form data to obtain a hash value;
acquiring second login information from a target user;
executing the step of generating the hash value based on the second login information and the additional character string to obtain a second hash value;
if the first hash value is consistent with the second hash value, pushing a password verification entry to the terminal where the target user is located;
acquiring a second password sent by the target user through the password authentication entrance;
and if the second password is consistent with the first password, generating a file sharing link or providing an entrance for extracting network file resources for the target user.
2. The method according to claim 1, wherein the sorting the items of form data according to a predetermined rule based on data names included in the items of form data comprises:
and sorting the form data according to the ASCII code of the included data name from small to large.
3. The method according to claim 1, wherein the sorting the items of form data according to a predetermined rule based on data names included in the items of form data comprises:
dividing the characters into a plurality of priorities according to the size of the ASCII codes of the characters, so that the ASCII codes of the characters with smaller priorities are larger than the ASCII codes of the characters with larger priorities, and each priority corresponds to at least one character;
and sorting the form data of each item according to the priority of the first character of the included data name from large to small, and sorting the form data of each item with the first character of the included data name at the same priority according to the ASCII code of the included data name from large to small.
4. The method according to any one of claims 1 to 3, wherein before the sorted form data is spliced with additional character strings to obtain spliced form data, the method further comprises:
randomly generating a corresponding additional character string for each item of the form data;
the splicing the sorted form data and the additional character strings to obtain spliced form data comprises the following steps:
and splicing each item of form data with the corresponding additional character string to obtain spliced form data.
5. The method of any of claims 1-3, wherein the first login information comprises a target account number, and prior to obtaining second login information from a target user, the method further comprises:
correspondingly storing the target account, the additional character string and the first hash value;
the acquiring of the second login information from the target user includes:
acquiring second login information, wherein the second login information comprises an account;
if the account number is consistent with the target account number, determining that the second login information comes from the target user;
the step of generating a hash value is performed based on the second login information and the additional character string to obtain a second hash value, and the step of generating a hash value includes:
determining an additional character string stored corresponding to the account;
and executing the step of generating the hash value based on the second login information and the determined additional character string to obtain a second hash value.
6. The method of any of claims 1-3, wherein prior to obtaining the second login information from the target user, the method further comprises:
acquiring a file to be shared uploaded by the target user;
if the second password is consistent with the first password, generating a file sharing link or providing an entry for extracting network file resources to the target user, including:
and if the second password is consistent with the first password, generating a file sharing link corresponding to the file to be shared.
7. The method of any of claims 1-3, wherein prior to obtaining the second login information from the target user, the method further comprises:
acquiring a file sharing link uploaded by the target user;
if the second password is consistent with the first password, generating a file sharing link or providing an entry for extracting network file resources to the target user, including:
and if the second password is consistent with the first password, providing an entrance for extracting network file resources for the target user according to the file sharing link.
8. A file sharing apparatus, the apparatus comprising:
the first acquisition module is configured to acquire first login information and a first password from a target user;
a first execution module configured to execute a hash value generation step based on the first login information, resulting in a first hash value, the hash value generation step comprising: generating form data corresponding to login information, wherein each form data comprises a data name and a parameter value corresponding to the data name; sorting the form data according to a preset rule based on data names included in the form data; splicing the sorted form data and the additional character strings to obtain spliced form data; performing hash operation on the spliced form data to obtain a hash value;
the second acquisition module is configured to acquire second login information from the target user;
a second execution module configured to execute the step of generating a hash value based on the second login information and the additional character string, resulting in a second hash value;
the pushing module is configured to push a password verification entry to the terminal where the target user is located if the first hash value is consistent with the second hash value;
a third obtaining module configured to obtain a second password sent by the target user through the password authentication entry;
and the generating and providing module is configured to generate a file sharing link or provide an entrance for extracting network file resources to the target user if the second password is consistent with the first password.
9. A computer-readable storage medium storing computer-readable instructions which, when executed by a computer, cause the computer to perform the method of any one of claims 1 to 7.
10. An electronic device, characterized in that the electronic device comprises:
a processor;
a memory having stored thereon computer readable instructions which, when executed by the processor, implement the method of any of claims 1 to 7.
CN202011411726.6A 2020-12-03 2020-12-03 File sharing method, device, medium and electronic equipment Pending CN112463749A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202011411726.6A CN112463749A (en) 2020-12-03 2020-12-03 File sharing method, device, medium and electronic equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202011411726.6A CN112463749A (en) 2020-12-03 2020-12-03 File sharing method, device, medium and electronic equipment

Publications (1)

Publication Number Publication Date
CN112463749A true CN112463749A (en) 2021-03-09

Family

ID=74805566

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202011411726.6A Pending CN112463749A (en) 2020-12-03 2020-12-03 File sharing method, device, medium and electronic equipment

Country Status (1)

Country Link
CN (1) CN112463749A (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115310065A (en) * 2022-10-09 2022-11-08 北京金堤科技有限公司 File generation method and device, storage medium and electronic equipment
CN115378694A (en) * 2022-08-19 2022-11-22 山东大学 Login verification method and system

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110309668A (en) * 2019-05-16 2019-10-08 深圳市白唇鹿科技有限公司 Multi-platform data managing method, device, computer equipment and storage medium
CN110493220A (en) * 2019-08-16 2019-11-22 腾讯科技(深圳)有限公司 A kind of data sharing method based on block chain, equipment and storage medium
CN110572355A (en) * 2019-07-23 2019-12-13 平安科技(深圳)有限公司 Webpage data monitoring method and device, computer equipment and storage medium

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110309668A (en) * 2019-05-16 2019-10-08 深圳市白唇鹿科技有限公司 Multi-platform data managing method, device, computer equipment and storage medium
CN110572355A (en) * 2019-07-23 2019-12-13 平安科技(深圳)有限公司 Webpage data monitoring method and device, computer equipment and storage medium
CN110493220A (en) * 2019-08-16 2019-11-22 腾讯科技(深圳)有限公司 A kind of data sharing method based on block chain, equipment and storage medium

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115378694A (en) * 2022-08-19 2022-11-22 山东大学 Login verification method and system
CN115310065A (en) * 2022-10-09 2022-11-08 北京金堤科技有限公司 File generation method and device, storage medium and electronic equipment

Similar Documents

Publication Publication Date Title
CN110879903A (en) Evidence storage method, evidence verification method, evidence storage device, evidence verification device, evidence storage equipment and evidence verification medium
US20160261586A1 (en) Identity Authentication Method And Device And Storage Medium
US9369468B2 (en) Generation of a visually obfuscated representation of an alphanumeric message that indicates availability of a proposed identifier
CN107249004B (en) Identity authentication method, device and client
CN108090351B (en) Method and apparatus for processing request message
CN108701309A (en) A kind of distributed user profile authentication system for security of e-commerce transactions
US20190373002A1 (en) Method and system for detecting credential stealing attacks
US10810176B2 (en) Unsolicited bulk email detection using URL tree hashes
CN104468531A (en) Authorization method, device and system for sensitive data
CN111343162B (en) System secure login method, device, medium and electronic equipment
CN110738323B (en) Method and device for establishing machine learning model based on data sharing
CN105827582B (en) A kind of communication encrypting method, device and system
US11244153B2 (en) Method and apparatus for processing information
CN107634947A (en) Limitation malice logs in or the method and apparatus of registration
US11640450B2 (en) Authentication using features extracted based on cursor locations
US9401914B1 (en) Utilization of multiple keypads for password inputs
CN112463749A (en) File sharing method, device, medium and electronic equipment
CN109347620B (en) Sample alignment method, system and computer readable storage medium
CN111651749A (en) Method and device for finding account based on password, computer equipment and storage medium
CN111488581A (en) Weak password vulnerability detection method and device, electronic equipment and computer readable medium
CN111191200A (en) Page display method and device and electronic equipment
CN116055067B (en) Weak password detection method, device, electronic equipment and medium
CN112598810A (en) Exhibition entrance processing method and device
CN116192445A (en) User login verification method, device, equipment and storage medium
CN114978646A (en) Access authority determination method, device, equipment and storage medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination