Password verification method and device, electronic equipment and readable storage medium
By obtaining and matching the password character summary information of the account information in the password input interface, the problem of login failure caused by the user forgetting the account information is solved, the waiting time and the risk of information leakage are reduced, and the login efficiency and security of electronic devices are improved.
Patent Information
- Application Number
- CN202411000044.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-07-24
- Publication Date
- 2024-10-29
AI Technical Summary
In the existing technology, the user forgets the account information and password information, causing the login operation of the electronic device to fail, resulting in a long waiting time and increasing the login time.
Display account information in the password input interface, obtain the password characters entered by the user, and generate summary information based on some characters. Match the summary information associated with the account to display verification success information, reduce the probability of login failure, and ensure information security.
It reduces the waiting time caused by multiple failed logins, improves login efficiency, reduces the risk of account information leakage, and ensures application information security.
Smart Images

Figure CN118862046A_ABST
Abstract
Description
Technical Field
[0001] The present application belongs to the field of information security technology, and specifically relates to a password verification method, device, electronic device and readable storage medium. Background Art
[0002] Typically, when a user wants to trigger an electronic device to log in to an application in the electronic device, if the user has forgotten the account information previously created using the application and the password information corresponding to the account information, the user can trigger the electronic device to perform login operations one by one using the account information and the corresponding password information recalled by the user until the account information and the corresponding password information recalled by the user match the account information and the corresponding password information created previously, so that the electronic device can log in to the application.
[0003] However, since the electronic device may fail to perform the login operation multiple times, it may not be possible to use the account information and corresponding password information recalled by the user to perform the login operation for a long time. In this way, the user may need to wait for a long time before being able to use the account information and corresponding password information recalled by the user to perform the login operation again. Therefore, the electronic device may need to wait for a long time to log in to the above-mentioned application, thus causing the electronic device to take a long time to log in to the application. Summary of the invention
[0004] The purpose of the embodiments of the present application is to provide a password verification method, device, electronic device and readable storage medium, which can reduce the probability of being unable to use the user's recalled account information and corresponding password information to perform login operations for a long time due to the user's repeated failure to perform login operations. Therefore, the waiting time required to log in to the application required by the user can be reduced, thus reducing the time spent on logging into the application on the electronic device.
[0005] In a first aspect, an embodiment of the present application provides a password verification method, the method comprising: when displaying first account information in a password input interface, obtaining first verification information input by a user, the first verification information including N first password characters, N being a positive integer; generating first summary information based on M first password characters out of the N first password characters, M being a positive integer less than or equal to N; when the first summary information matches the second summary information associated with the first account information, displaying verification success information; wherein the above-mentioned verification success information is used to indicate that the first verification information matches the second verification information corresponding to the first account information, the second verification information including M second password characters, and the above-mentioned second summary information is generated based on the M second password characters.
[0006] In a second aspect, an embodiment of the present application provides a password verification device, which includes: an acquisition module, which is used to acquire first verification information input by a user when displaying first account information in a password input interface, the first verification information including N first password characters, where N is a positive integer. A processing module, which is used to generate first summary information based on M first password characters out of the N first password characters included in the first verification information acquired by the acquisition module, where M is a positive integer less than or equal to N. A display module, which is used to display verification success information when the first summary information generated by the processing module matches the second summary information associated with the first account information. The above-mentioned verification success information is used to indicate that the first verification information matches the second verification information corresponding to the first account information; the second verification information includes M second password characters, and the above-mentioned second summary information is generated based on the M second password characters.
[0007] In a third aspect, an embodiment of the present application provides an electronic device, which includes a processor and a memory, wherein the memory stores programs or instructions that can be run on the processor, and when the program or instructions are executed by the processor, the steps of the method described in the first aspect are implemented.
[0008] In a fourth aspect, an embodiment of the present application provides a readable storage medium, on which a program or instruction is stored, and when the program or instruction is executed by a processor, the steps of the method described in the first aspect are implemented.
[0009] In a fifth aspect, an embodiment of the present application provides a chip, comprising a processor and a communication interface, wherein the communication interface is coupled to the processor, and the processor is used to run a program or instruction to implement the steps of the method described in the first aspect.
[0010] In a sixth aspect, an embodiment of the present application provides a computer program product, which is stored in a storage medium and is executed by at least one processor to implement the steps of the method described in the first aspect.
[0011] In an embodiment of the present application, when the first account information is displayed in the password input interface, the electronic device can obtain the first verification information input by the user including N first password characters, N is a positive integer, and generate first summary information based on M first password characters among the N first password characters, M is a positive integer less than or equal to N, so that when the first summary information and the second summary information associated with the first account information match, the electronic device can display verification success information; wherein the above-mentioned verification success information is used to indicate that the first verification information and the second verification information corresponding to the first account information match; the second verification information includes M second password characters, and the second summary information is generated based on the M second password characters. Since the first account information is associated with the second summary information, and the second summary information is generated based on the M second password characters included in the second verification information, that is, the second summary information is related to the M second password characters, and after the electronic device obtains the first verification information, it can generate the first summary information based on at least part of the first password characters (that is, the M first password characters) included in the first verification information, that is, the first summary information is related to the M first password characters. In this way, after generating the first summary information, the electronic device can determine that the M first password characters match the M second password characters when the first summary information and the second summary information match, so as to determine that the first verification information and the second verification information match. At this time, the electronic device can indicate to the user that the first verification information and the second verification information match by displaying a verification success message, so that the user can determine that the first verification information and the second verification information match through the verification success message, and when determining that the first verification information and the second verification information match Only when the first account information and the second verification information match, the electronic device is triggered to use the first account information and the password information corresponding to the first verification information to perform a login operation, rather than triggering the electronic device to perform a login operation based on the first account information and the password information corresponding to the first verification information when it cannot be determined that the first verification information and the second verification information match. Therefore, the probability of failure of the electronic device to perform a login operation can be reduced, thereby reducing the probability of the electronic device failing to perform a login operation for a long time due to multiple failures to perform the login operation, thereby reducing the waiting time required to log in to the application required by the user; and, because the first account information is associated with the second summary information instead of directly associated with the second verification information, the probability of leakage of the password information corresponding to the second verification information can be reduced, thereby reducing the probability of leakage of application information in the electronic device; in this way, the time spent on electronic device login to the application can be reduced under the premise of ensuring the security of application information in the electronic device. BRIEF DESCRIPTION OF THE DRAWINGS
[0012] Figure 1 This is one of the flowcharts of the password verification method provided in the embodiment of the present application;
[0013] Figure 2A This is one of the interface diagrams of the mobile phone interface provided in the embodiment of the present application;
[0014] Figure 2B This is the second interface diagram of the mobile phone interface provided in the embodiment of the present application;
[0015] Figure 3 This is the third interface diagram of the mobile phone interface provided in the embodiment of the present application;
[0016] Figure 4 This is the second flowchart of the password verification method provided in the embodiment of the present application;
[0017] Figure 5A This is the fourth interface diagram of the mobile phone interface provided in the embodiment of the present application;
[0018] Figure 5B This is the fifth interface diagram of the mobile phone interface provided in the embodiment of the present application;
[0019] Figure 6 This is the third flowchart of the password verification method provided in the embodiment of the present application;
[0020] Figure 7 This is the fourth flowchart of the password verification method provided in the embodiment of the present application;
[0021] Figure 8 This is the fifth flowchart of the password verification method provided in the embodiment of the present application;
[0022] Fig. 9 This is the sixth flowchart of the password verification method provided in the embodiment of the present application;
[0023] Fig.10 is a schematic diagram of an electronic device generating first verification information in a password verification method provided in an embodiment of the present application;
[0024] Fig.11 This is the seventh flowchart of the password verification method provided in the embodiment of the present application;
[0025] Fig.12 is a schematic diagram of an electronic device generating first summary information in a password verification method provided in an embodiment of the present application;
[0026] Fig.13 It is a schematic diagram of the structure of a password verification device provided in an embodiment of the present application;
[0027] Fig.14 This is one of the hardware structure diagrams of the electronic device provided in the embodiment of the present application;
[0028] Fig.15This is the second schematic diagram of the hardware structure of the electronic device provided in the embodiment of the present application. DETAILED DESCRIPTION
[0029] The following will be combined with the drawings in the embodiments of the present application to clearly describe the technical solutions in the embodiments of the present application. Obviously, the described embodiments are part of the embodiments of the present application, rather than all the embodiments. All other embodiments obtained by ordinary technicians in this field based on the embodiments in the present application belong to the scope of protection of this application.
[0030] The terms "first", "second", etc. in the specification and claims of the present application are used to distinguish similar objects, and are not used to describe a specific order or sequence. It should be understood that the data used in this way can be interchangeable under appropriate circumstances, so that the embodiments of the present application can be implemented in an order other than those illustrated or described here, and the objects distinguished by "first", "second", etc. are generally of one type, and the number of objects is not limited. For example, the first object can be one or more. In addition, "and / or" in the specification and claims represents at least one of the connected objects, and the character " / " generally indicates that the objects associated with each other are in an "or" relationship.
[0031] The password verification method, device, electronic device and readable storage medium provided in the embodiments of the present application are described in detail below with reference to the accompanying drawings through specific embodiments and their application scenarios.
[0032] The password verification method provided in the embodiment of the present application is applied to the scenario where a user triggers an electronic device to log in to an application of user demand.
[0033] A specific application scenario, in the related technology, assume that a user wants to trigger an electronic device to log in to application a in the electronic device, and the account information previously created by the user using application 1 is a123456, and the password information corresponding to the account information is b123456. At this time, if the user has forgotten the password information corresponding to the account information a123456, the user can first recall the password information that may correspond to the account information a123456 (that is, the password information commonly used by the user), such as password information c123456, password information b112233, password information b112244 and password information b123456, and then use the account information a123456 and password information c123456 to perform the login operation, and if the login operation fails, use the account information a123456 and password information b112233 to perform the login operation, and if the login operation fails, use the account information a123456 and password information b112244 to perform the login operation, so that the user can finally use the account information a123456 and password information b123456 to perform the login operation if the login operation fails, and the electronic device can log in to application 1 at this time. However, in the above steps, when the user uses the account information a123456 and password information b112233 to perform a login operation, and the login operation fails, the account information a123456 may not be used again for a long time (e.g., 5 minutes) due to a large number of login failures. In this case, the user needs to wait for 5 minutes before using the account information a123456 and password information b112244 to perform a login operation again. When the login operation fails, the account information a123456 may not be used again for a long time (e.g., 30 minutes) due to a large number of login failures. In this case, the user needs to wait for 30 minutes before using the account information a123456 and password information b123456 to perform a login operation again to log in to application 1. That is, in the above steps, the electronic device needs to wait for a long time (i.e., 35 minutes) to log in to application 1, which results in a long time for the electronic device to log in to the application.
[0034] However, in the embodiment of the present application, an association relationship between account information a123456 and summary information a1cd3fcd is pre-stored in the electronic device, and the summary information a1cd3fcd is generated by verification information 2 in password information b123456 (the verification information 2 may include some password characters b1234 in password information b123456), so that the user can enter account information a123456 and password information c123456 in the password input interface of application 1, so that the electronic device can generate summary information c123456 based on verification information 1 in password information c123456 (for example, the verification information 1 includes some password characters c1234 in password information c123456). 3a1df2c, and when it is determined that the summary information a1cd3fcd and the summary information c3a1df2c do not match, the verification failure information may be displayed or no prompt information may be displayed, and the verification failure information is used to indicate that the verification information 2 and the verification information 1 do not match, so that the user can determine that the password information c123456 and the password information b123456 may not match, and continue to enter the account information a123456 and the password information b112233 in the password input interface of the application 1, so that the electronic device can generate the summary information b1 based on the verification information 3 in the password information b112233 (for example, the verification information 3 includes some password characters b1122 in the password information b112233) b8ed2e, and when it is determined that the summary information a1cd3fcd and the summary information b1b8ed2e do not match, a verification failure message is displayed or no prompt message is displayed, wherein the verification failure message is used to indicate that the verification information 2 and the verification information 3 do not match, so that the user can know that the password information b112233 and the password information b123456 may not match, and continue to enter the account information a123456 and the password information b112244 in the password input interface of the application 1, so that the electronic device can generate the summary information b1b8ed2e based on the verification information 4 in the password information b112244 (for example, the verification message 4 includes part of the password characters b1122 in the password information b112244). ed2e, and when it is determined that the summary information a1cd3fcd and the summary information b1b8ed2e do not match, a verification failure message is displayed or no prompt message is displayed, the verification failure message is used to indicate that the verification information 2 and the verification information 4 do not match, so that the user can determine that the password information b112244 and the password information b123456 do not match, and continue to enter the account information a123456 and the password information b123456 in the password input interface of application 1, so that the electronic device can generate the summary information a1cd3fcd based on the verification information 5 in the password information b123456 (for example, the verification message 5 includes part of the password characters b1234 in the password information b123456),And when it is determined that the summary information a1cd3fcd matches the summary information a1cd3fcd, verification success information is displayed, and the verification success information is used to indicate that the verification information 2 matches the verification information 5. In this way, the user can determine that the verification information 2 and the verification information 5 match, and use the account information a123456 and the password information corresponding to the verification information 5 (i.e., the password information b123456) to perform the login operation, without triggering the electronic device to use the account information a123456 and the wrong password information one by one to perform the login operation. Therefore, the probability of failure of the electronic device to perform the login operation can be reduced, thereby reducing the probability of failure to use the account information and the corresponding password information to perform the login operation for a long time due to multiple failures of the electronic device to perform the login operation, thereby reducing the waiting time required to log in to the application 1 required by the user; and because the account information a123456 is associated with the summary information a1cd3fcd, rather than directly associated with the password information b123456, the probability of the password information b123456 being leaked can be reduced, thereby reducing the probability of information leakage of the application 1; in this way, the time consumed by the electronic device to log in to the application can be reduced under the premise of ensuring the security of the application information in the electronic device. ,
[0035] It should be noted that the password verification method provided in the embodiments of the present application can be executed by electronic devices such as mobile phones, tablet computers, laptop computers, PDAs, and vehicle-mounted electronic devices. In some embodiments of the present application, a mobile phone is used as the execution subject to execute the password verification method as an example to illustrate the password verification method provided in the embodiments of the present application.
[0036] The present application embodiment provides a password verification method, Figure 1 A flowchart of a password verification method provided by an embodiment of the present application is shown. Figure 1 As shown, the password verification method provided in the embodiment of the present application may include the following steps 101 to 103.
[0037] Step 101: When the electronic device displays first account information in a password input interface, the electronic device obtains first verification information input by a user.
[0038] In some embodiments of the present application, the password input interface may be an application login interface of the first application. The application type of the first application may be any of the following: chat type, music type, video type, game type, teaching type, etc. Of course, the application type of the first application may also be other types, which are not limited in the embodiments of the present application.
[0039] In some embodiments of the present application, the first account information may be account information created by the user using the first application.
[0040] In the embodiment of the present application, the first verification information includes N first password characters, where N is a positive integer.
[0041] In some embodiments of the present application, the first verification information may be at least part of the password information corresponding to the first account information recalled by the user. It is understood that the first verification information may include at least part of the password characters in the password information corresponding to the first account information recalled by the user.
[0042] In some embodiments of the present application, the N first password characters may be all password characters included in the first verification information. The first password characters may be any of the following: English, numbers, symbols, etc. Of course, the first password characters may also be other characters, which is not limited in the embodiments of the present application.
[0043] In some embodiments of the present application, when the electronic device opens the first application, the electronic device may first determine whether the first application has opened the password mnemonics function, so that the electronic device may display a first window when it is determined that the first application has opened the password mnemonics function, and the first window displays a first prompt message, and the first prompt message is used to prompt the user whether to assist in verifying the password information, and then the electronic device may display an account input box and a password input box in the first window according to the user's input of the first prompt message, and the account input box is used to enter the account information, and the password input box is used to enter the verification information. In this way, the electronic device can display the first account information in the account input box according to the user's input of the first account information in the account input box, and obtain the first verification information according to the user's input of the first verification information in the password input box.
[0044] In some examples, when the electronic device determines that the first application has enabled the password mnemonics function, it may display the first window floating on the interface of the first application to avoid the situation where the content in the application interface of the first application obscures the first window, thereby preventing the user from being unable to view the first prompt information.
[0045] In some examples, a first control and a second control are also displayed on the first prompt information, and the first control is used to trigger the electronic device to cancel display of the first window, and the second control is used to trigger the electronic device to display an account input box and a password input box, so that the electronic device can display the account input box and the password input box in the first window according to the user's input to the second control (for example, click input).
[0046] In some examples, a third control is also displayed in the account input box, and the third control is used to trigger the electronic device to display at least one historical account information, and the at least one historical account information includes the first account information, so that the electronic device can display at least one historical account information in the first window according to the user input to the third control (for example, click input), and display the first account information in the account input box according to the user input to the first account information (for example, click input).
[0047] In some examples, the electronic device may display the first verification information in the password input box based on the user inputting the first verification information.
[0048] For example, the electronic device is a mobile phone. Assume that the mobile phone displays the application interface 1 of the first application, and the mobile phone determines that the first application has enabled the password mnemonics function, such as Figure 2A As shown, the mobile phone can display a first window 10 floating on the application interface 1, and the first window 10 displays a first prompt message, such as a prompt message 11 "The current application has enabled the password mnemonics function, do you need assistance in verification?", and a first control and a second control, such as a "No" control 12 and a "Yes" control 13, are displayed on the prompt message 11 "The current application has enabled the password mnemonics function, do you need assistance in verification?", and the "No" control 12 is used to trigger the mobile phone to cancel the display of the first window 10, and the "Yes" control 13 is used to trigger the mobile phone to display the account input box and the password input box, so that the user can click the "Yes" control 13 to input. Figure 2B As shown, after the user clicks and inputs the "Yes" control 13, the mobile phone can update the content displayed in the first window 10 to an account input box 14 and a password input box 15, so that the user can enter the first account information 16 in the account input box 14, so that the mobile phone can display the first account information 16 in the account input box 14, and the user can enter the first verification information in the password input box 15, so that the mobile phone can display the first verification information 17 in the password input box 15.
[0049] Step 102: The electronic device generates first summary information based on M first password characters among the N first password characters.
[0050] In the embodiment of the present application, M is a positive integer less than or equal to N.
[0051] In the embodiment of the present application, the M first password characters may be at least part of the N first password characters.
[0052] In the embodiment of the present application, in order to avoid the number of characters of the M first password characters used to generate the first summary information being different from the number of characters of the second password characters used to generate the second summary information, the electronic device may first determine the number of characters of the M first password characters based on the number of characters of the second password characters used to generate the second summary information, as will be illustrated below.
[0053] In some embodiments of the present application, Figure 1 ,like Figure 3 As shown, before the above step 102, the password verification method provided in the embodiment of the present application may also include the following steps 201 and 202.
[0054] Step 201: The electronic device obtains a first character number.
[0055] In the embodiment of the present application, the first number of characters is the number of M characters of the second password.
[0056] It can be understood that the M second password characters are at least part of the password characters in the password information corresponding to the first account information. The password information corresponding to the first account information is the password information corresponding to the first account information created by the user using the first application, that is, the electronic device can successfully log in to the first application using the first account information and the password information corresponding to the first account information. The number of the first characters is equal to M.
[0057] It should be noted that the present embodiment does not limit the execution order of step 201 and step 101. In one example, the electronic device may first execute step 101 and then execute step 201; in another example, the electronic device may execute step 201 while executing step 101. Figure 3 In the figure, it is illustrated that the electronic device first executes step 101 and then executes step 201.
[0058] In some embodiments of the present application, the first number of characters (ie, the number of M second password characters) is pre-stored in the electronic device, so that the electronic device can directly obtain the first number of characters from the electronic device.
[0059] Step 202: The electronic device determines the first M first password characters of the N first password characters as M first password characters.
[0060] It can be understood that the electronic device can determine the first number of first password characters of the N first password characters as M first password characters.
[0061] In the embodiment of the present application, since the number of characters of the first password characters used to generate the first summary information and the second password characters used to generate the second summary information are different, even if some of the password characters in the first password characters used to generate the first summary information and the second password characters used to generate the second summary information are the same, the first summary information and the second summary information are different, that is, even if the user enters the correct password characters, the first summary information and the second summary information are different. Therefore, in order to avoid the above situation, the electronic device may first obtain the first number of characters of the second password characters used to generate the second summary information, and then determine the first M first password characters of the N first password characters as the M first password characters to ensure that the number of characters of the first password characters used to generate the first summary information and the second password characters used to generate the second summary information are the same.
[0062] Thus, it can be known that since the electronic device can first obtain the first number of characters of the second password characters used to generate the second summary information, and then determine the first M first password characters of the N first password characters as the M first password characters, in the subsequent steps, the electronic device can generate the first summary information based on the first password characters whose number of characters is the same as the number of characters of the second password characters used to generate the second summary information. Therefore, the situation in which the first summary information and the second summary information do not match due to the different number of characters of the first password characters used to generate the first summary information and the second password characters used to generate the second summary information can be avoided, thereby improving the accuracy of the electronic device in determining whether the first verification information and the second verification information match.
[0063] In some embodiments of the present application, the electronic device may use a predetermined algorithm to calculate and generate the first summary information based on the M first password characters. The predetermined algorithm may specifically be a hash algorithm, and the first summary information may specifically be a hash value. Of course, the predetermined algorithm may also be other algorithms, which are not limited in the embodiments of the present application.
[0064] The specific scheme for the electronic device to generate the first summary information is described below by way of example.
[0065] In some embodiments of the present application, before the above step 102, the password verification method provided in the embodiment of the present application may further include the following step 203, and the above step 102 may be specifically implemented by the following step 102a.
[0066] Step 203: The electronic device obtains a first random number associated with the first account information from a database.
[0067] In some embodiments of the present application, the first random number is a random number used by the electronic device when generating the second summary information according to the M second password characters using a predetermined algorithm. It can be understood that when the electronic device generates the second summary information, the first account information, the second summary information and the first random number can be stored in a database in association, so that the electronic device can obtain the first random number associated with the first account information from the database according to the first account information.
[0068] Step 102a: The electronic device uses M first password characters and a first random number to calculate and obtain first summary information.
[0069] In some embodiments of the present application, the electronic device may use the above-mentioned predetermined algorithm, using the M first password characters and the first random number, to calculate and generate the first summary information. The predetermined algorithm may specifically be a hash algorithm, such as a slow hash algorithm, and the above-mentioned first summary information may specifically be a hash value. Of course, the predetermined algorithm may also be other algorithms, which are not limited in the embodiments of the present application.
[0070] It can be understood that since the hash algorithm has an irreversible characteristic, that is, other users cannot use the calculated first summary information to derive the M first password characters, that is, cannot derive the first verification information, therefore, the probability of leakage of the password information corresponding to the first verification information can be reduced.
[0071] In some examples, the above predetermined algorithm may specifically be:
[0072] pwdHash 1=PBKDF 2(PRF,Password 1,pwdSalt,c,dkLen);
[0073] Among them, pwdHash1 is the first summary information, PRF is a pseudo-random function, Password1 is M first password characters, pwdSalt is the salt value (ie, the first random number), c is the number of iterations, dkLen is the length of the summary information to be output, and PBKDF2 is used to indicate the algorithm formula of the predetermined algorithm.
[0074] Here, the pseudo-random function may be a hash function, such as a SHA-256 function, the salt value (i.e., the first random number) may be 8 bytes, the number of iterations may be 1000, and the length of the summary information to be output may be 256 bytes. Of course, the parameters used by the predetermined algorithm may also be other contents, which are not limited in the embodiments of the present application.
[0075] It can be seen that since the first random number is the random number associated with the first account information, that is, the random number used when generating the second summary information associated with the first account information, after the electronic device obtains the first random number from the database, the electronic device can use the first password characters with the same number of characters as the M second password characters and the same random number to generate the first summary information, instead of using the first password characters with the same number of characters as the M second password characters and a new random number to generate the first summary information. Therefore, the situation where the first summary information and the second summary information do not match due to the difference in the random number used to generate the first summary information and the random number used to generate the second summary information can be avoided, thereby improving the accuracy of password verification performed by the electronic device.
[0076] In some embodiments of the present application, a third control is also displayed in the first window, and the third control is used to trigger the electronic device to generate summary information, so that the electronic device can generate the first summary information based on the M first password characters according to the user's input to the third control.
[0077] For example, combining Figure 2B ,like Figure 4 As shown, a third control is also displayed in the first window 10, such as a "verification" control 18, and the "verification" control 18 is used to trigger the mobile phone to generate summary information, so that the electronic device can generate the first summary information according to the user's input to the "verification" control 18 (such as click input).
[0078] Step 103: When the first summary information matches the second summary information associated with the first account information, the electronic device displays a verification success message.
[0079] In some embodiments of the present application, the above-mentioned matching can be understood as: being identical, or the similarity between the two is greater than or equal to a preset similarity.
[0080] In some embodiments of the present application, multiple sets of verification data are pre-stored in a database of the electronic device, each set of verification data includes associated account information, summary information and a random number, so that the electronic device can first determine a set of verification data including the first account information from the multiple sets of verification data, and determine the summary information in the set of verification data as the second summary information, and then determine whether the first summary information and the second summary information match.
[0081] In an embodiment of the present application, the above-mentioned verification success information is used to indicate that the first verification information matches the second verification information corresponding to the first account information; the second verification information includes M second password characters, and the above-mentioned second summary information is generated based on the M second password characters.
[0082] In the embodiment of the present application, the second verification information may be at least part of the password information corresponding to the first account information, and the password information corresponding to the first account information is the password information corresponding to the first account information created by the user using the first application. That is, the electronic device can successfully log in to the first application using the first account information and the password information corresponding to the first account information, that is, the correct password information of the first account information.
[0083] In some embodiments of the present application, the M second password characters may be all password characters included in the second verification information. The second password characters may be any of the following: English, numbers, symbols, etc. Of course, the second password characters may also be other characters, which is not limited in the embodiments of the present application.
[0084] In the embodiment of the present application, if the first summary information and the second summary information match, it can be considered that the M first password characters are the same as the M second password characters, and it can also be considered that the N first password characters and the M second password characters are likely to be the same, that is, it can be considered that the password information corresponding to the first verification information and the password information corresponding to the second verification information are likely to be the same. Therefore, the electronic device can display a verification success message to prompt the user that the password information corresponding to the first verification information entered is likely to match the password information corresponding to the second verification information.
[0085] In one scenario, since the user may use the password information that the user often uses when creating account information, the electronic device can use the M second password characters in at least part of the password information (i.e., the second verification information) in the password information corresponding to the first account information (i.e., the password information corresponding to the second verification information, that is, the correct password information that can successfully log in to the first account information in the first application) to generate second summary information, so that the user can enter at least part of the password information (i.e., the first verification information) in the password information that the user often uses, so that the electronic device can use the M first password characters in the first verification information to generate the first summary information, and then the electronic device can prompt the user through a verification success message to match at least part of the password information (i.e., the first verification information) in the commonly used password information entered by the user with at least part of the password information (i.e., the second verification information) in the password information corresponding to the first account information when the first summary information and the second summary information match. In this way, the user can quickly recall the correct password information of the first account information and quickly enter the correct password information.
[0086] In some embodiments of the present application, the electronic device may display verification success information in the first window.
[0087] For example, combining Figure 4 ,like Figure 5AAs shown, when the first summary information and the second summary information match, the mobile phone can display verification success information in the first window 10, such as "Verification result: success!" information 19, and the "Verification result: success!" information 19 is used to indicate that the first verification information and the second verification information match, so that the user can know that the input first verification information and the second verification information match.
[0088] In some embodiments of the present application, the above step 103 may also be replaced by the following step 104.
[0089] Step 104: When the first summary information and the second summary information do not match, the electronic device displays a verification failure message.
[0090] In the embodiment of the present application, the above verification failure information is used to indicate that the first verification information and the second verification information do not match.
[0091] For example, combining Figure 4 ,like Figure 5B As shown, when the first summary information and the second summary information do not match, the mobile phone can display verification failure information in the first window 10, such as "Verification result: fail!" information 20, and the "Verification result: fail!" information 20 is used to indicate that the first verification information and the second verification information do not match, so that the user can know that the input first verification information and the second verification information do not match.
[0092] It can be seen that when the first summary information and the second summary information do not match, the electronic device can also display the verification failure information to prompt the user through the verification failure information that the first verification information and the second verification information do not match. This can avoid the user using the first account information and incorrect password information to perform a login operation. Therefore, it can avoid the situation where the electronic device fails to perform a login operation, thereby avoiding the situation where the account information and the corresponding password information cannot be used to perform a login operation for a long time due to multiple failures of the electronic device to perform a login operation, thereby reducing the waiting time required to log in to the application required by the user.
[0093] In summary, in the embodiment of the present application, after the electronic device obtains the first account information and the first verification information, it will not directly perform the login operation, but can generate the first summary information based on the M first password characters, and when the first summary information and the second summary information match, prompt the user to match the first verification information and the second verification information input, so that the user can know whether the first verification information and the second verification information input match when the electronic device does not perform the login operation. In this way, the user can re-enter the recalled verification information when the verification success information is not displayed, that is, when the first verification information and the second verification information input do not match, until the verification information and the second verification information input match, and trigger the electronic device to perform the login operation, so that the probability of the electronic device failing to perform the login operation multiple times can be reduced. In addition, since only the first account information and the second summary information are stored in the electronic device, instead of the first account information and the second verification information, and only the first summary information and the second summary information are used in the above verification process, instead of the first verification information and the second verification information, the probability of deciphering the first verification information and / or the second verification information can be reduced, thereby avoiding the probability of obtaining the password information corresponding to the first verification information and / or the password information corresponding to the second verification information, and thus ensuring the security of the application information in the electronic device.
[0094] An embodiment of the present application provides a password verification method. When first account information is displayed in a password input interface, the electronic device can obtain first verification information input by a user including N first password characters, where N is a positive integer, and generate first summary information based on M first password characters among the N first password characters, where M is a positive integer less than or equal to N, so that when the first summary information matches second summary information associated with the first account information, the electronic device can display verification success information; wherein the above-mentioned verification success information is used to indicate that the first verification information matches the second verification information corresponding to the first account information; the second verification information includes M second password characters, and the second summary information is generated based on the M second password characters. Since the first account information is associated with the second summary information, and the second summary information is generated based on the M second password characters included in the second verification information, that is, the second summary information is related to the M second password characters, and after the electronic device obtains the first verification information, it can generate the first summary information based on at least part of the first password characters (that is, the M first password characters) included in the first verification information, that is, the first summary information is related to the M first password characters. In this way, after generating the first summary information, the electronic device can determine that the M first password characters match the M second password characters when the first summary information and the second summary information match, so as to determine that the first verification information and the second verification information match. At this time, the electronic device can indicate to the user that the first verification information and the second verification information match by displaying a verification success message, so that the user can determine that the first verification information and the second verification information match through the verification success message, and when determining that the first verification information and the second verification information match Only when the first account information and the second verification information match, the electronic device is triggered to use the first account information and the password information corresponding to the first verification information to perform a login operation, rather than triggering the electronic device to perform a login operation based on the first account information and the password information corresponding to the first verification information when it cannot be determined that the first verification information and the second verification information match. Therefore, the probability of failure of the electronic device to perform a login operation can be reduced, thereby reducing the probability of the electronic device failing to perform a login operation for a long time due to multiple failures to perform the login operation, thereby reducing the waiting time required to log in to the application required by the user; and, because the first account information is associated with the second summary information instead of directly associated with the second verification information, the probability of leakage of the password information corresponding to the second verification information can be reduced, thereby reducing the probability of leakage of application information in the electronic device; in this way, the time spent on electronic device login to the application can be reduced under the premise of ensuring the security of application information in the electronic device.
[0095] The following is an example to illustrate a specific solution for an electronic device to store verification data in a database.
[0096] In some embodiments of the present application, Figure 1 ,like Figure 6 As shown, before the above step 101, the password verification method provided in the embodiment of the present application may also include the following steps 301 to 303.
[0097] Step 301: The electronic device obtains first account information and first password information input by a user.
[0098] In the embodiment of the present application, the first password information includes L second password characters, where L is a positive integer greater than or equal to M.
[0099] It can be understood that the M second password characters are at least part of the L second password characters.
[0100] In some embodiments of the present application, when a password input interface is displayed, the user can enter the first account information and the first password information in the password input interface, so that the electronic device can call the autofill capability through the system capability to obtain the first account information and the first password information. The autofill capability can be the AutofillService capability in Android.
[0101] In some embodiments of the present application, the above-mentioned first password information can be understood as: the password information corresponding to the second verification information, that is, the correct password information that can successfully log in to the first account information in the first application.
[0102] Step 302: When the electronic device successfully performs a login operation using the first account information and the first password information, the electronic device generates second summary information based on M second password characters out of the L second password characters.
[0103] In some embodiments of the present application, a "login" control is also displayed in the password input interface, so that the electronic device can perform a login operation using the first account information and the first password information based on the user's input to the "login" control (for example, click input), and generate second summary information based on M second password characters out of L second password characters when the login operation is successfully performed using the first account information and the first password information.
[0104] It should be noted that for instructions on successfully performing a login operation on an electronic device using the first account information and the first password information, reference may be made to the specific description in the relevant technology, and the embodiments of the present application will not be elaborated herein.
[0105] In some embodiments of the present application, the electronic device may first determine M second password characters from L second password characters, and then generate second summary information based on the M second password characters.
[0106] The following is an example of a specific solution for the electronic device to determine M second password characters from L second password characters.
[0107] In some embodiments of the present application, Figure 6 ,like Figure 7 As shown, before the above step 302, the password verification method provided in the embodiment of the present application may also include the following steps 304 and 305.
[0108] Step 304: The electronic device determines the ratio of the second number of characters to the first value as the third number of characters.
[0109] In the embodiment of the present application, the second number of characters is L characters of the second password, and the third number of characters is M characters of the second password.
[0110] It can be understood that the second character number is equal to L, and the third character number is equal to M.
[0111] In some embodiments of the present application, the first numerical value may be a default numerical value or a numerical value input by a user.
[0112] Step 305: The electronic device determines the first M second password characters of the L second password characters as M second password characters.
[0113] In the embodiment of the present application, since the number of characters L of the L second password characters may be relatively large, if the second summary information is generated directly based on the L second password characters, the storage space occupied by the second summary information may be relatively large. Therefore, the electronic device may first determine the ratio of the second number of characters to the first value as the third number of characters, and then determine the first third number of characters (i.e., M) of the second password characters of the L second password characters as M second password characters, so as to reduce the storage space occupied by the generated second summary information.
[0114] Thus, it can be known that, since the electronic device can first accurately determine the third number of characters M of the second password characters required to generate the second summary information based on the second number of characters of the L second password characters and the first numerical value, and directly determine the first M second password characters of the L second password characters as the second password characters required to generate the second summary information, instead of directly determining the L second password characters as the second password characters required to generate the second summary information, the number of characters of the second password characters required to generate the second summary information can be reduced, thereby reducing the storage space occupied by the generated second summary information, and thus, the storage space of the electronic device can be saved.
[0115] In some embodiments of the present application, the electronic device may use the above-mentioned predetermined algorithm, use the M second password characters and the first random number, and calculate and generate the second summary information. The predetermined algorithm may be a hash algorithm, and the above-mentioned second summary information may be a hash value. Of course, the predetermined algorithm may also be other algorithms, which are not limited in the embodiments of the present application.
[0116] Step 303: The electronic device stores the first account information and the second summary information in association with each other.
[0117] In some embodiments of the present application, the electronic device may store a set of verification data in a database, where the set of verification data includes associated first account information and second summary information.
[0118] In some examples, the above-mentioned set of verification data also includes at least one of the following: an application ID of the first application, and the above-mentioned first random number.
[0119] It can be understood that the electronic device can perform the above steps 301 to 303 multiple times to store multiple sets of verification data in the database.
[0120] The following is an example of a specific scheme for the electronic device to generate the second summary information.
[0121] In some embodiments of the present application, the above step 302 may be specifically implemented by the following step 302a, and the above step 303 may be specifically implemented by the following step 303a.
[0122] Step 302a: When the electronic device successfully performs a login operation using the first account information and the first password information, the electronic device uses M second password characters and the first random number to calculate and obtain second summary information.
[0123] In some embodiments of the present application, when the electronic device successfully performs a login operation using the first account information and the first password information, it can first randomly generate a first random number, and then use M second password characters and the first random number to calculate the second summary information.
[0124] In some embodiments of the present application, the electronic device may use the above-mentioned predetermined algorithm, use the M second password characters and the first random number, and calculate and generate the second summary information. The predetermined algorithm may specifically be a hash algorithm, such as a slow hash algorithm, and the above-mentioned second summary information may specifically be a hash value. Of course, the predetermined algorithm may also be other algorithms, which are not limited in the embodiments of the present application.
[0125] It can be understood that due to the irreversible nature of the hash algorithm, that is, other users cannot use the calculated second summary information to derive the M second password characters, that is, they cannot derive the second verification information, that is, they cannot derive the password information corresponding to the second verification information (that is, the correct password information of the first account information). Therefore, the probability of leakage of the password information corresponding to the second verification information can be reduced.
[0126] In some examples, the above predetermined algorithm may specifically be:
[0127] pwdHash 2=PBKDF 2(PRF,Password 2,pwdSalt,c,dkLen);
[0128] Among them, pwdHash2 is the second summary information, PRF is a pseudo-random function, Password2 is M second password characters, pwdSalt is the salt value (ie, the first random number), c is the number of iterations, dkLen is the length of the summary information to be output, and PBKDF2 is used to indicate the algorithm formula of the predetermined algorithm.
[0129] Step 303a: The electronic device stores the first random number, the first account information, and the second summary information in a database in association with each other.
[0130] It can be seen that, since when the electronic device successfully performs the login operation, the electronic device can use the M second password characters and the first random number to calculate the second summary information, and store the first random number, the first account information and the second summary information in a database in an associated manner, so that, on the one hand, in subsequent steps, the electronic device can also obtain the first random number and the second summary information based on the first account information, and use the first random number and the M first password characters input by the user to generate the first summary information, so that it can be avoided that the first summary information and the second summary information do not match each other due to the difference between the random number used to generate the first summary information and the random number used to generate the second summary information; on the other hand, the electronic device does not need to associate and store the password information corresponding to the first account information and the second verification information (that is, the correct password information of the first account information), so the probability of leakage of the password information corresponding to the second verification information can be reduced; thereby, the accuracy of password verification by the electronic device can be improved while ensuring the security of application information in the electronic device.
[0131] In some embodiments of the present application, after the electronic device stores multiple sets of verification data in a database, when the electronic device turns on the first application, the electronic device can first obtain the application ID of the first application, and then determine whether the application IDs in the multiple sets of verification data include the application ID of the first application. When it is determined that the application IDs in the multiple sets of verification data include the application ID of the first application, it is determined that the password mnemonics function has been turned on for the first application, so that the electronic device can display the first window in the above embodiment.
[0132] Of course, during the process of the user using the first application, the user may modify the password information corresponding to the first account information (i.e., the correct password information) on other electronic devices. At this time, the electronic device can update the second summary information in the electronic device to ensure the accuracy of the verification based on the second summary information. An example will be given below.
[0133] In some embodiments of the present application, Figure 6 ,like Figure 8 As shown, after the above step 303, the password verification method provided in the embodiment of the present application may further include the following steps 401 to 403.
[0134] Step 401: The electronic device obtains first account information and second password information input by a user.
[0135] In the embodiment of the present application, the second password information includes T third password characters, where T is a positive integer.
[0136] In some embodiments of the present application, when a password input interface is displayed, the user can enter the first account information and the second password information in the password input interface, so that the electronic device can call the autofill capability through the system capability to obtain the first account information and the second password information. The autofill capability can be the AutofillService capability in Android.
[0137] Step 402: When the electronic device successfully performs a login operation using the first account information and the second password information, the electronic device generates third summary information based on M third password characters out of the T third password characters.
[0138] It should be noted that, for the description of the electronic device determining M third password characters from T third password characters, and generating third summary information based on the M third password characters, reference can be made to the specific description of the electronic device determining M first password characters from N first password characters, and generating first summary information based on the M first password characters in the above embodiment, and the embodiments of the present application will not be repeated here.
[0139] Step 403: When the third summary information and the second summary information do not match, the electronic device updates the summary information associated with the first account information from the second summary information to the third summary information.
[0140] In some embodiments of the present application, the electronic device may delete the second summary information associated with the first account information from the above-mentioned set of verification data in the database, and store the third summary information in the set of verification data.
[0141] In this way, it can be seen that since the electronic device can also generate the third summary information based on M third password characters when the first account information and the second password information are used to successfully perform the login operation, and the summary information associated with the first account information is updated from the second summary information to the third summary information, the probability of inaccurate verification results obtained by using the second summary information for verification due to the user modifying the password information corresponding to the first account information on other electronic devices can be reduced, thereby ensuring the accuracy of the verification results obtained by using the summary information for verification.
[0142] The following will combine the schemes in each embodiment to illustrate the complete process of the password verification method provided in the embodiments of the present application.
[0143] like Fig. 9 As shown, the password verification method provided in the embodiment of the present application may include the following steps:
[0144] Step 501: When a user triggers an electronic device to open a first application, the user can enter the first account information and the second password information in the password input interface of the first application to trigger the electronic device to perform a login operation using the first account information and the second password information. When the login operation is successful, the electronic device can display a first prompt message, and the first prompt message is used to prompt the user whether to use the password mnemonics function to prompt the user whether the password mnemonics function is needed.
[0145] Step 502: When the user selects the password mnemonic function, the electronic device may obtain the first account information and the first password information by invoking the automatic filling capability through the system capability.
[0146] Step 503: The electronic device may determine whether the number L of the L second password characters included in the first password information is greater than or equal to a preset number of characters, so as to determine whether the password length of the first password information supports mnemonics.
[0147] Step 504: When the number of characters L of the L second password characters included in the first password information is greater than or equal to the preset number of characters, that is, when the password length of the first password information supports mnemonics, refer to Fig.10The electronic device may determine the ratio of the number of characters L of the L second password characters included in the first password information to a first numerical value (e.g., 2) set by the user as the number of characters L / 2 (i.e., M), and determine the first M second password characters of the L second password characters as the M second password characters, and use a slow hash algorithm to generate second summary information (pwdHash2) based on the M second password characters and the first random number (pwdSalt).
[0148] Step 505: Reference Fig.10 , the electronic device may store a set of verification data in the database, the set of verification data including the application ID of the first application, the first account information ( Fig.10 ), a first random number (pwdSalt), and second summary information (pwdHash2).
[0149] Step 506: When the number of characters L of the L second password characters included in the first password information is less than the preset number of characters, that is, when the password length of the first password information does not support mnemonics, the electronic device can display a third prompt message, and the third prompt message is used to prompt the user that the use of the mnemonics function has failed, so that the electronic device can execute the above step 501 again.
[0150] It is understandable that after the electronic device executes the above steps 501 to 505, the electronic device can store the above set of verification data in the database to facilitate subsequent use to verify whether the verification information input by the user matches the second verification information based on the second summary information.
[0151] like Fig.11 As shown, the password verification method provided in the embodiment of the present application may also include the following steps:
[0152] Step 507: When the user triggers the electronic device to start the first application and the electronic device displays a password input interface, the electronic device can first obtain the application ID of the first application and determine whether there is verification data including the application ID of the first application in the multiple sets of verification data in the database.
[0153] Step 508: When determining that there is verification data including the application ID of the first application, the electronic device can determine that the first application has enabled the password mnemonics function and display a first window, in which a first prompt message is displayed. The first prompt message is used to prompt the user whether he needs assistance in verifying the password information, so that the user can choose whether he needs assistance in verifying the password information.
[0154] Step 509: The electronic device may update the content displayed in the first window to an account input box and a password input box.
[0155] Step 510: The electronic device determines whether at least one account information (ie, the at least one historical account information) can be determined from the verification data including the application ID of the first application, ie, the electronic device can determine whether there is a corresponding account.
[0156] Step 511: When the electronic device determines that at least one account information can be determined from the verification data including the application ID of the first application, the electronic device can display a third control in the account input box, so that the user can input the third control so that the electronic device can display the at least one account information, and then the user can input the first account information among the at least one account information, so that the electronic device can display the first account information in the account input box and input the first verification information in the password input box.
[0157] Step 512: When the electronic device determines that at least one account information cannot be determined from the verification data including the application ID of the first application, the electronic device may display a fourth prompt message, which is used to prompt the user that an error has occurred in the application operation.
[0158] Step 513: The electronic device determines M first password characters from N first password characters, referring to Fig.12 The electronic device may first determine the above-mentioned set of verification data ( Fig.12 It is not shown that the set of verification data includes the first account information), and then a slow hash algorithm is used to generate the first summary information (pwdHash1) based on the M first password characters and the first random number (pwdSalt) in the set of verification data.
[0159] Step 514: The electronic device may determine whether the first summary information (pwdHash1) and the second summary information (pwdHash2) in the above set of verification data match (are equal).
[0160] Step 515: If the first summary information (pwdHash1) and the second summary information (pwdHash2) match, the electronic device may display a verification success message to prompt the user that the first verification information matches the second verification information.
[0161] Step 516: If the first summary information (pwdHash1) and the second summary information (pwdHash2) do not match, the electronic device may display a verification failure message to prompt the user that the first verification information and the second verification information do not match.
[0162] The password verification method provided in the embodiment of the present application can be executed by a password verification device. In the embodiment of the present application, the password verification device executing the password verification method is taken as an example to illustrate the password verification device provided in the embodiment of the present application.
[0163] Fig.13 A possible structural diagram of a password verification device involved in an embodiment of the present application is shown. Fig.13 As shown, the password verification device 60 may include: an acquisition module 61, which is used to acquire the first verification information input by the user when the first account information is displayed in the password input interface, and the first verification information includes N first password characters, where N is a positive integer. A processing module 62, which is used to generate first summary information based on M first password characters among the N first password characters included in the first verification information acquired by the acquisition module 61, where M is a positive integer less than or equal to N. A display module 63, which is used to display verification success information when the first summary information generated by the processing module 62 matches the second summary information associated with the first account information.
[0164] The above verification success information is used to indicate that the first verification information matches the second verification information corresponding to the first account information; the second verification information includes M second password characters, and the above second summary information is generated based on the M second password characters.
[0165] An embodiment of the present application provides a password verification device. Since the first account information is associated with the second summary information, and the second summary information is generated based on the M second password characters included in the second verification information, that is, the second summary information is related to the M second password characters, and after the password verification device obtains the first verification information, the first summary information can be generated based on at least part of the first password characters (that is, the M first password characters) included in the first verification information, that is, the first summary information is related to the M first password characters. In this way, after the first summary information is generated, the password verification device can determine that the M first password characters match the M second password characters when the first summary information and the second summary information match, so as to determine that the first verification information and the second verification information match. At this time, the password verification device can indicate to the user that the first verification information and the second verification information match by displaying a verification success message, so that the user can determine that the first verification information and the second verification information match through the verification success message, and after determining that the first verification information and the second verification information match, the password verification device can determine that the first verification information and the second verification information match. The password verification device is triggered to perform a login operation using the first account information and the password information corresponding to the first verification information only when the first verification information and the second verification information match, rather than triggering the password verification device to perform a login operation based on the first account information and the password information corresponding to the first verification information when it cannot be determined that the first verification information and the second verification information match. Therefore, the probability of failure of the password verification device to perform a login operation can be reduced, thereby reducing the probability of failure to use the account information and the corresponding password information to perform a login operation for a long time due to multiple failures of the password verification device to perform a login operation, thereby reducing the waiting time required to log in to the application required by the user; and, because the first account information is associated with the second summary information instead of directly associated with the second verification information, the probability of leakage of the password information corresponding to the second verification information can be reduced, thereby reducing the probability of leakage of application information in the password verification device; in this way, the time consumed by the password verification device to log in to the application can be reduced under the premise of ensuring the security of the application information in the password verification device.
[0166] In a possible implementation, the acquisition module 61 is further used to acquire the first account information and the first password information input by the user before acquiring the first verification information input by the user when the first account information is displayed in the password input interface, the first password information including L second password characters, where L is a positive integer greater than or equal to M. The processing module 62 is further used to generate the second summary information based on M second password characters out of the L second password characters when the login operation is successfully performed using the first account information and the first password information acquired by the acquisition module 61; and store the first account information and the second summary information in association.
[0167] In some embodiments of the present application, the above-mentioned processing module 62 is also used to determine the ratio of the second character number and the first numerical value as the third character number before generating the second summary information based on M second password characters out of L second password characters, the second character number being the number of characters of the L second password characters, and the third character number being the number of characters of the M second password characters.
[0168] In some embodiments of the present application, the processing module 62 is specifically configured to use M second password characters and the first random number to calculate the second summary information; and store the first random number, the first account information and the second summary information in a database in association with each other.
[0169] In some embodiments of the present application, the acquisition module 61 is further used to acquire the first account information and the second password information input by the user after the processing module 62 associates and stores the first account information and the second summary information, the second password information including T third password characters, where T is a positive integer. The processing module 62 is further used to generate the third summary information based on M third password characters among the T third password characters when the login operation is successfully performed using the first account information and the second password information; and when the third summary information and the second summary information do not match, update the summary information associated with the first account information from the second summary information to the third summary information.
[0170] In some embodiments of the present application, the acquisition module 61 is further used to acquire the first character number before the processing module 62 generates the first summary information based on the M first password characters in the N first password characters, and the first character number is the number of characters of the M second password characters. The processing module 62 is also used to determine the first M first password characters of the N first password characters as the M first password characters.
[0171] In some embodiments of the present application, the acquisition module 61 is further used to acquire the first random number associated with the first account information from the database before the processing module 62 generates the first summary information based on M first password characters among the N first password characters. The processing module 62 is specifically used to calculate the first summary information using the M first password characters and the first random number acquired by the acquisition module 61.
[0172] In some embodiments of the present application, the display module 63 is further configured to display verification failure information when the first summary information and the second summary information do not match; wherein the verification failure information is configured to indicate that the first verification information and the second verification information do not match.
[0173] The password verification device in the embodiment of the present application can be an electronic device, or a component in the electronic device, such as an integrated circuit or a chip. The electronic device can be a terminal, or other devices other than a terminal. Exemplarily, the electronic device can be a mobile phone, a tablet computer, a laptop computer, a PDA, a car-mounted electronic device, a mobile internet device (mobile internet device, MID), an augmented reality (augmentedreality, AR) / virtual reality (virtualreality, VR) device, a robot, a wearable device, an ultra-mobile personal computer (ultra-mobile personal computer, UMPC), a netbook or a personal digital assistant (personal digital assistant, PDA), etc., and can also be a server, a network attached storage (network attached storage, NAS), a personal computer (personalcomputer, PC), a television (television, TV), a teller machine or a self-service machine, etc., which is not specifically limited in the embodiment of the present application.
[0174] The password verification device in the embodiment of the present application may be a device having an operating system. The operating system may be an Android operating system, an iOS operating system, or other possible operating systems, which are not specifically limited in the embodiment of the present application.
[0175] The password verification device provided in the embodiment of the present application can achieve Figures 1 to 12 To avoid repetition, the various processes implemented by the method embodiment are not described here.
[0176] In some embodiments of the present application, Fig.14 As shown, an embodiment of the present application also provides an electronic device 70, including a processor 71 and a memory 72, wherein the memory 72 stores programs or instructions that can be executed on the processor 71, and when the program or instructions are executed by the processor 71, the various process steps of the above-mentioned password verification method embodiment are implemented, and the same technical effect can be achieved. To avoid repetition, they are not repeated here.
[0177] It should be noted that the electronic devices in the embodiments of the present application include the above-mentioned mobile electronic devices and non-mobile electronic devices.
[0178] Fig.15 A schematic diagram of the hardware structure of an electronic device to implement an embodiment of the present application.
[0179] The electronic device 100 includes but is not limited to components such as a radio frequency unit 101, a network module 102, an audio output unit 103, an input unit 104, a sensor 105, a display unit 106, a user input unit 107, an interface unit 108, a memory 109, and a processor 110.
[0180] Those skilled in the art will appreciate that the electronic device 100 may also include a power source (such as a battery) for supplying power to various components, and the power source may be logically connected to the processor 110 through a power management system, thereby implementing functions such as managing charging, discharging, and power consumption management through the power management system. Fig.15 The electronic device structure shown in the figure does not constitute a limitation on the electronic device. The electronic device may include more or fewer components than shown in the figure, or combine certain components, or arrange the components differently, which will not be described in detail here.
[0181] Among them, the processor 110 is used to obtain first verification information input by the user when the first account information is displayed in the password input interface, and the first verification information includes N first password characters, where N is a positive integer; and generate first summary information based on M first password characters among the N first password characters, where M is a positive integer.
[0182] The display unit 106 is configured to display verification success information when the first summary information matches the second summary information associated with the first account information.
[0183] In an embodiment of the present application, the above-mentioned verification success information is used to indicate that the first verification information matches the second verification information corresponding to the first account information; the second verification information includes M second password characters, and the above-mentioned second summary information is generated based on the M second password characters.
[0184] An embodiment of the present application provides an electronic device, in which first account information is associated with second summary information, and the second summary information is generated based on M second password characters included in the second verification information, that is, the second summary information is related to the M second password characters, and after the electronic device obtains the first verification information, the first summary information can be generated based on at least part of the first password characters (that is, the M first password characters) included in the first verification information, that is, the first summary information is related to the M first password characters. In this way, after the first summary information is generated, the electronic device can determine that the M first password characters match the M second password characters when the first summary information and the second summary information match, so as to determine that the first verification information and the second verification information match. At this time, the electronic device can indicate to the user that the first verification information and the second verification information match by displaying a verification success message, so that the user can determine that the first verification information and the second verification information match through the verification success message, and when determining that the first verification information and the second verification information match, the electronic device can determine that the first verification information and the second verification information match. Only when the second verification information matches, the electronic device is triggered to use the first account information and the password information corresponding to the first verification information to perform a login operation, rather than triggering the electronic device to perform a login operation based on the first account information and the password information corresponding to the first verification information when it cannot be determined that the first verification information and the second verification information match. Therefore, the probability of failure of the electronic device to perform a login operation can be reduced, thereby reducing the probability of the electronic device being unable to use the account information and the corresponding password information to perform a login operation for a long time due to multiple failures to perform login operations, thereby reducing the waiting time required to log in to the application required by the user; and, since the first account information is associated with the second summary information instead of directly associated with the second verification information, the probability of leakage of the password information corresponding to the second verification information can be reduced, thereby reducing the probability of leakage of application information in the electronic device; in this way, the time spent on electronic device login to the application can be reduced under the premise of ensuring the security of application information in the electronic device.
[0185] In some embodiments of the present application, the user input unit 107 is used to obtain the first account information and first password information input by the user before obtaining the first verification information input by the user when the first account information is displayed in the password input interface, and the first password information includes L second password characters, where L is a positive integer greater than or equal to M.
[0186] The processor 110 is further configured to generate second summary information based on M second password characters out of L second password characters when a login operation is successfully performed using the first account information and the first password information; and store the first account information and the second summary information in association with each other.
[0187] In some embodiments of the present application, the processor 110 is further used to determine the ratio of the second character number to the first numerical value as the third character number before generating the second summary information based on M second password characters out of the L second password characters, the second character number being the number of characters of the L second password characters, and the third character number being the number of characters of the M second password characters; and determine the first M second password characters of the L second password characters as the M second password characters.
[0188] In some embodiments of the present application, the processor 110 is specifically configured to use M second password characters and the first random number to calculate the second summary information; and store the first random number, the first account information, and the second summary information in a database in an associated manner.
[0189] In some embodiments of the present application, the user input unit 107 is further used to obtain the first account information and the second password information input by the user after the processor 110 associates and stores the first account information and the second summary information, where the second password information includes T third password characters, where T is a positive integer.
[0190] The processor 110 is further configured to, when a login operation is successfully performed using the first account information and the second password information, generate third summary information based on M third password characters among the T third password characters; and when the third summary information and the second summary information do not match, update the summary information associated with the first account information from the second summary information to the third summary information.
[0191] In some embodiments of the present application, the processor 110 is further used to obtain a first character number before generating the first summary information based on M first password characters out of the N first password characters, where the first character number is the number of M second password characters; and determine the first M first password characters of the N first password characters as the M first password characters.
[0192] In some embodiments of the present application, the processor 110 is further configured to obtain a first random number associated with the first account information from a database before generating the first summary information based on M first password characters out of the N first password characters.
[0193] The processor 110 is specifically configured to calculate and obtain first summary information using M first password characters and a first random number.
[0194] In some embodiments of the present application, the display unit 106 is configured to display verification failure information when the first summary information and the second summary information do not match.
[0195] The verification failure information is used to indicate that the first verification information and the second verification information do not match.
[0196] It should be understood that in the embodiment of the present application, the input unit 104 may include a graphics processing unit (GPU) 1041 and a microphone 1042, and the graphics processor 1041 processes the image data of a static picture or video obtained by an image capture device (such as a camera) in a video capture mode or an image capture mode. The display unit 106 may include a display panel 1061, and the display panel 1061 may be configured in the form of a liquid crystal display, an organic light emitting diode, etc. The user input unit 107 includes a touch panel 1071 and at least one of other input devices 1072. The touch panel 1071 is also called a touch screen. The touch panel 1071 may include two parts: a touch detection device and a touch controller. Other input devices 1072 may include, but are not limited to, a physical keyboard, function keys (such as a volume control button, a switch button, etc.), a trackball, a mouse, and a joystick, which will not be repeated here.
[0197] The memory 109 can be used to store software programs and various data. The memory 109 may mainly include a first storage area for storing programs or instructions and a second storage area for storing data, wherein the first storage area may store an operating system, an application program or instructions required for at least one function (such as a sound playback function, an image playback function, etc.), etc. In addition, the memory 109 may include a volatile memory or a non-volatile memory, or the memory 109 may include both volatile and non-volatile memories. Among them, the non-volatile memory may be a read-only memory (ROM), a programmable read-only memory (PROM), an erasable programmable read-only memory (EPROM), an electrically erasable programmable read-only memory (EEPROM), or a flash memory. The volatile memory may be a random access memory (RAM), a static random access memory (SRAM), a dynamic random access memory (DRAM), a synchronous dynamic random access memory (SDRAM), a double data rate synchronous dynamic random access memory (DDRSDRAM), an enhanced synchronous dynamic random access memory (ESDRAM), a synchronous link dynamic random access memory (SLDRAM) and a direct rambus RAM (DRRAM). The memory 109 in the embodiment of the present application includes but is not limited to these and any other suitable types of memory.
[0198] The processor 110 may include one or more processing units; optionally, the processor 110 integrates an application processor and a modem processor, wherein the application processor mainly processes operations related to an operating system, a user interface, and application programs, and the modem processor mainly processes wireless communication signals, such as a baseband processor. It is understandable that the modem processor may not be integrated into the processor 110.
[0199] An embodiment of the present application also provides a readable storage medium, on which a program or instruction is stored. When the program or instruction is executed by a processor, each process of the above-mentioned password verification method embodiment is implemented, and the same technical effect can be achieved. To avoid repetition, it will not be repeated here.
[0200] The processor is the processor in the electronic device described in the above embodiment. The readable storage medium includes a computer readable storage medium, such as a computer read-only memory ROM, a random access memory RAM, a magnetic disk or an optical disk.
[0201] An embodiment of the present application further provides a chip, which includes a processor and a communication interface, wherein the communication interface is coupled to the processor, and the processor is used to run programs or instructions to implement the various processes of the above-mentioned password verification method embodiment, and can achieve the same technical effect. To avoid repetition, it will not be repeated here.
[0202] It should be understood that the chip mentioned in the embodiments of the present application can also be called a system-level chip, a system chip, a chip system or a system-on-chip chip, etc.
[0203] An embodiment of the present application provides a computer program product, which is stored in a storage medium. The program product is executed by at least one processor to implement the various processes of the above-mentioned password verification method embodiment and can achieve the same technical effect. To avoid repetition, it will not be repeated here.
[0204] It should be noted that, in this article, the terms "comprise", "include" or any other variant thereof are intended to cover non-exclusive inclusion, so that the process, method, article or device including a series of elements includes not only those elements, but also includes other elements not explicitly listed, or also includes elements inherent to such process, method, article or device. In the absence of further restrictions, the elements defined by the sentence "comprise one..." do not exclude the presence of other identical elements in the process, method, article or device including the element. In addition, it should be pointed out that the scope of the methods and devices in the embodiments of the present application is not limited to performing functions in the order shown or discussed, and may also include performing functions in a substantially simultaneous manner or in reverse order according to the functions involved, for example, the described method may be performed in an order different from that described, and various steps may also be added, omitted, or combined. In addition, the features described with reference to certain examples may be combined in other examples.
[0205] Through the description of the above implementation methods, those skilled in the art can clearly understand that the above-mentioned embodiment methods can be implemented by means of software plus a necessary general hardware platform, and of course by hardware, but in many cases the former is a better implementation method. Based on such an understanding, the technical solution of the present application, or the part that contributes to the prior art, can be embodied in the form of a computer software product, which is stored in a storage medium (such as ROM / RAM, a disk, or an optical disk), and includes a number of instructions for a terminal (which can be a mobile phone, a computer, a server, or a network device, etc.) to execute the methods described in each embodiment of the present application.
[0206] The embodiments of the present application are described above in conjunction with the accompanying drawings, but the present application is not limited to the above-mentioned specific implementation methods. The above-mentioned specific implementation methods are merely illustrative and not restrictive. Under the guidance of the present application, ordinary technicians in this field can also make many forms without departing from the purpose of the present application and the scope of protection of the claims, all of which are within the protection of the present application.
Claims
1. A password verification method, characterized in that: include: When the first account information is displayed in the password input interface, obtaining first verification information input by the user, where the first verification information includes N first password characters, where N is a positive integer; Generate first summary information based on M of the first password characters out of the N first password characters, where M is a positive integer less than or equal to N; If the first summary information matches the second summary information associated with the first account information, displaying a verification success message; The verification success information is used to indicate that the first verification information matches the second verification information corresponding to the first account information; The second verification information includes M second password characters, and the second summary information is generated based on the M second password characters.
2. The method according to claim 1, characterized in that In the case where the first account information is displayed in the password input interface, before obtaining the first verification information input by the user, the method further includes: Obtaining the first account information and first password information input by the user, where the first password information includes L characters of the second password, where L is a positive integer greater than or equal to M; In the case where a login operation is successfully performed using the first account information and the first password information, generating the second summary information based on M of the second password characters out of the L second password characters; The first account information and the second summary information are stored in association.
3. The method according to claim 2, characterized in that Before generating the second summary information based on M of the second password characters among the L second password characters, the method further includes: Determine the third number of characters as the ratio of the second number of characters to the first value, wherein the second number of characters is the number of L characters of the second password, and the third number of characters is the number of M characters of the second password; The first M second password characters of the L second password characters are determined as M second password characters.
4. The method according to claim 2, characterized in that: The generating the second summary information based on M of the second password characters among the L second password characters includes: Using the M second password characters and the first random number, calculate and obtain the second summary information; The associated storage of the first account information and the second summary information includes: The first random number, the first account information, and the second summary information are stored in a database in association with each other.
5. The method according to claim 2, characterized in that: After the associative storage of the first account information and the second summary information, the method further includes: Obtaining the first account information and the second password information input by the user, where the second password information includes T third password characters, where T is a positive integer; In the case where a login operation is successfully performed using the first account information and the second password information, generating third summary information based on M of the third password characters among the T third password characters; When the third summary information does not match the second summary information, the summary information associated with the first account information is updated from the second summary information to the third summary information.
6. The method according to claim 1, characterized in that Before generating the first summary information based on M of the first password characters among the N first password characters, the method further includes: Obtaining a first number of characters, where the first number of characters is the number of M characters of the second password; The first M first password characters of the N first password characters are determined as the M first password characters.
7. The method according to claim 1, characterized in that Before generating the first summary information based on M of the first password characters among the N first password characters, the method further includes: Obtaining a first random number associated with the first account information from a database; The generating first summary information based on M of the first password characters among the N first password characters includes: The first summary information is obtained by calculation using M first password characters and the first random number.
8. The method according to claim 1, characterized in that The method further comprises: If the first summary information and the second summary information do not match, displaying a verification failure message; The verification failure information is used to indicate that the first verification information and the second verification information do not match.
9. A password verification device, characterized in that: include: An acquisition module, configured to acquire first verification information input by a user when the first account information is displayed in the password input interface, wherein the first verification information includes N first password characters, where N is a positive integer; a processing module, configured to generate first summary information based on M of the first password characters among the N first password characters included in the first verification information acquired by the acquisition module, where M is a positive integer less than or equal to N; a display module, configured to display verification success information when the first summary information generated by the processing module matches the second summary information associated with the first account information; The verification success information is used to indicate that the first verification information matches the second verification information corresponding to the first account information; The second verification information includes M second password characters, and the second summary information is generated based on the M second password characters.
10. An electronic device, characterized in that: The method comprises a processor and a memory, wherein the memory stores a program or instruction that can be run on the processor, and when the program or instruction is executed by the processor, the steps of the password verification method as described in any one of claims 1 to 8 are implemented.
11. A readable storage medium, characterized in that: The readable storage medium stores a program or instruction, and when the program or instruction is executed by a processor, the steps of the password verification method according to any one of claims 1 to 8 are implemented.
Citation Information
Cited By
Password verification method and apparatus, and electronic device and readable storage medium
WO2026021383A1
