Authorization verification method, device, equipment and computer readable medium

The user logo, the validity period of the authorization code, and the number of authoritative use of the user's authorization code obtained through the decryption of the user's authorization code, the actual number of days of updating the software of the software solves the problem of illegal use of software in the existing technology, and achieves effective restrictions on software use time.

CN112182514BActive Publication Date: 2025-01-24CHINA CONSTRUCTION BANK
View PDF 1 Cites 0 Cited by

Patent Information

Application Number
CN202011003200.4
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2020-09-22
Publication Date
2025-01-24
Estimated Expiration
2040-09-22

AI Technical Summary

Technical Problem

In the prior art, authorization information is generated based on the characteristics of the server, and the illegal use of software cannot be effectively restricted.

Method used

By using the public key to decrypt the user authorization code, obtain an encrypted authorization code, and based on the user's key decryption of the original authorization code, the user logo, the effective period of the authorization code, and the number of authorized use days are obtained. The decrypted user logo is consistent with the actual logo and the authorization code is valid for the validity period, and the actual number of days of updating the software will be updated.

Benefits of technology

It implements restrictions on the legal use time of software, prevents illegal use, and enhances the security of software protection.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN112182514B_ABST
    Figure CN112182514B_ABST
Patent Text Reader

Abstract

The present invention discloses a method, device, equipment and computer-readable medium for authorization verification, and relates to the field of computer technology. A specific implementation of the method includes: using a public key to decrypt a user authorization code to obtain an encrypted authorization code; based on a user secret key obtained from the encrypted authorization code, decrypting the original authorization code in the encrypted authorization code to obtain a user identifier, an authorization code validity period and authorized use days; if the decrypted user identifier is consistent with the actual user identifier, and the current date does not exceed the authorization code validity period, then the actual use days of the software are updated by the authorized use days. This implementation can limit the illegal use of software.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of computer technology, and in particular to a method, device, equipment and computer-readable medium for authorization verification. Background Art

[0002] The concept of software protection is based on the developer's perspective. It emphasizes the use of encryption-based technical means to protect software from being cracked and from being illegally or excessively used by customers. Theoretically, all software protection technologies can be cracked as long as there are enough resources and time. However, if the security strength of a protection technology reaches a level that makes the cracker pay more than the cost of purchasing the software, this protection technology is successful and worth using.

[0003] To protect the rights and interests of software developers and prevent software from being copied, stolen or used illegally without authentication, software authorization is generally used to authenticate and activate the software. Only software that has been authenticated and activated can be used normally, and users can use the various functions and services provided by the software.

[0004] In the process of implementing the present invention, the inventors found that there are at least the following problems in the prior art: the authorization information is generated based on the characteristics of the server, which cannot restrict the illegal use of the software. Summary of the invention

[0005] In view of this, embodiments of the present invention provide a method, apparatus, device and computer-readable medium for authorization verification, which can limit the illegal use of software.

[0006] To achieve the above object, according to one aspect of an embodiment of the present invention, a method for authorization verification is provided, comprising:

[0007] Decrypt the user authorization code using the public key to obtain the encrypted authorization code;

[0008] Decrypting the original authorization code in the encrypted authorization code based on the user secret key obtained from the encrypted authorization code to obtain the user identification, the validity period of the authorization code and the number of days for authorized use;

[0009] If the user identification obtained by decryption is consistent with the actual user identification and the current date does not exceed the validity period of the authorization code, the actual usage days of the software are updated by the authorized usage days.

[0010] The method of decrypting the original authorization code in the encrypted authorization code based on the user secret key obtained from the encrypted authorization code to obtain the user identification, the validity period of the authorization code and the number of days for authorized use includes:

[0011] Obtaining the user key and the original authorization code from the encrypted authorization code by using preset characters in the encrypted authorization code;

[0012] Based on the user secret key, the original authorization code in the encrypted authorization code is decrypted to obtain the user identification, the validity period of the authorization code and the number of days for authorized use.

[0013] The decrypting of the original authorization code in the encrypted authorization code to obtain the user identification, the validity period of the authorization code and the number of days for authorized use includes:

[0014] Decrypting the original authorization code in the encrypted authorization code to obtain a concatenated authorization code;

[0015] The spliced ​​authorization code is segmented according to the preset characters in the spliced ​​authorization code to obtain the user identification, the validity period of the authorization code and the number of days for authorized use.

[0016] If the user ID obtained by decryption is consistent with the actual user ID, and the current date does not exceed the validity period of the authorization code, the actual usage days of the software are updated by the authorized usage days, including:

[0017] Decrypting the configuration file using the public key to obtain the actual user ID and the validity period of the software;

[0018] If the user identification obtained by decryption is consistent with the actual user identification and the current date does not exceed the validity period of the authorization code, the authorized usage days are added to the actual usage days of the software.

[0019] The user authorization code is input by the user.

[0020] The method further comprises:

[0021] The actual usage days of the software are updated at least once a day.

[0022] The method further comprises:

[0023] If the actual number of days the software is used is equal to zero, the service of the software is stopped.

[0024] The method further comprises:

[0025] If the actual usage days of the software are less than or equal to the reminder days, a reminder message is sent.

[0026] The method further comprises:

[0027] The server uses the user's secret key to encrypt the user ID, the validity period of the authorization code, and the number of days for authorized use to obtain the original authorization code;

[0028] The server constructs the encrypted authorization code according to the original authorization code and the user secret key;

[0029] The server encrypts the encrypted authorization code using a public key to obtain the user authorization code.

[0030] The server uses the user key to encrypt the user ID, the validity period of the authorization code, and the number of days for authorized use to obtain the original authorization code, including:

[0031] According to the preset characters, the user ID, the validity period of the authorization code and the number of days for authorized use are concatenated to obtain a concatenated authorization code;

[0032] The spliced ​​authorization code is encrypted using the user secret key to obtain the original authorization code.

[0033] The server forms the encrypted authorization code according to the original authorization code and the user secret key, including:

[0034] The server uses preset characters to concatenate the original authorization code and the user key to obtain the encrypted authorization code.

[0035] The preset characters include preset special characters.

[0036] The server includes a user information table, and the user information table includes the user identifier and the user key.

[0037] The method further comprises:

[0038] If the decrypted user ID is inconsistent with the actual user ID, the decryption failure is displayed.

[0039] The method further comprises:

[0040] If the user ID obtained by decryption is consistent with the actual user ID and the current date has exceeded the validity period of the authorization code, the decryption expired message will be displayed.

[0041] The method is applied in the software.

[0042] The public key is preset in the software.

[0043] According to a second aspect of an embodiment of the present invention, there is provided an authorization verification device, comprising:

[0044] A first decryption module, used to decrypt the user authorization code using the public key to obtain the encrypted authorization code;

[0045] A second decryption module is used to decrypt the original authorization code in the encrypted authorization code based on the user secret key obtained from the encrypted authorization code to obtain the user identification, the validity period of the authorization code and the number of days for authorized use;

[0046] The authorization module is used to update the actual usage days of the software by the authorized usage days if the user identification obtained by decryption is consistent with the actual user identification and the current date does not exceed the validity period of the authorization code.

[0047] According to a third aspect of an embodiment of the present invention, there is provided an electronic device for authorization verification, including:

[0048] one or more processors;

[0049] a storage device for storing one or more programs,

[0050] When the one or more programs are executed by the one or more processors, the one or more processors implement the above method.

[0051] According to a fourth aspect of an embodiment of the present invention, there is provided a computer-readable medium on which a computer program is stored, and when the program is executed by a processor, the method as described above is implemented.

[0052] One embodiment of the above invention has the following advantages or beneficial effects: using the public key to decrypt the user authorization code to obtain the encrypted authorization code; based on the user secret key obtained from the encrypted authorization code, decrypting the original authorization code in the encrypted authorization code to obtain the user identification, the authorization code validity period and the authorized use days; if the decrypted user identification is consistent with the actual user identification, and the authorization code validity period does not exceed the current date, the actual use days of the software are updated by the authorized use days. Since not only the user identification can be verified, but also the validity period of the authorization code can be used for time verification, the illegal use of the software can be restricted.

[0053] The further effects of the above-mentioned non-conventional optional manner will be described below in conjunction with the specific implementation manner. BRIEF DESCRIPTION OF THE DRAWINGS

[0054] The accompanying drawings are used to better understand the present invention and do not constitute an improper limitation of the present invention.

[0055] Figure 1 It is a schematic diagram of the process of server-based feature authorization verification in the prior art;

[0056] Figure 2 is a schematic diagram of the main process of the authorization verification method according to an embodiment of the present invention;

[0057] Figure 3 is a schematic diagram of a usage scenario of a method for application authorization verification according to an embodiment of the present invention;

[0058] Figure 4 is a schematic diagram of decrypting a user authorization code according to an embodiment of the present invention;

[0059] Figure 5 is a schematic diagram of a process for decrypting an original authorization code according to an embodiment of the present invention;

[0060] Figure 6 is a schematic diagram of decrypting an original authorization code according to an embodiment of the present invention;

[0061] Figure 7 is a schematic diagram of a process for decrypting an original authorization code according to an embodiment of the present invention;

[0062] Figure 8 is a schematic diagram of a process for updating the useful life of software according to an embodiment of the present invention;

[0063] Fig. 9 is a schematic diagram of a process for constructing a user authorization code according to an embodiment of the present invention;

[0064] Fig.10 is a schematic diagram of a process for establishing an original authorization code according to an embodiment of the present invention;

[0065] Fig.11 is a schematic diagram of obtaining an original authorization code according to an embodiment of the present invention;

[0066] Fig.12 is a schematic diagram of obtaining a user authorization code according to an embodiment of the present invention;

[0067] Fig.13 is a schematic diagram of the main structure of an authorization verification device according to an embodiment of the present invention;

[0068] Fig.14 is an exemplary system architecture diagram to which embodiments of the present invention may be applied;

[0069] Fig.15 It is a schematic diagram of the structure of a computer system of a terminal device or a server suitable for implementing an embodiment of the present invention. DETAILED DESCRIPTION

[0070] The following is a description of exemplary embodiments of the present invention in conjunction with the accompanying drawings, including various details of the embodiments of the present invention to facilitate understanding, which should be considered as merely exemplary. Therefore, it should be recognized by those of ordinary skill in the art that various changes and modifications may be made to the embodiments described herein without departing from the scope and spirit of the present invention. Similarly, for clarity and conciseness, the description of well-known functions and structures is omitted in the following description.

[0071] Software can provide two deployment solutions: cloud and local, so software authorization can be divided into online authorization and offline authorization. Cloud-deployed services generally provide online authorization. For locally deployed software, offline authorization is generally provided.

[0072] Software with intellectual property rights generally adopts software protection measures, and needs to be activated in some way before it can be used. The essence of software activation is to compare ciphertext data, which is generally generated by the software developer through encryption based on the characteristic data of the target machine. The activation process is completed on the authentication server or the target machine.

[0073] At present, the mainstream offline authorization scheme basically generates an MD5 value based on the characteristics of the server, and encrypts the MD5 value again to obtain authorization information. The software is activated offline using the authorization information. The characteristics of the server may include one or more of the Mac address, hard disk serial number, and CPU serial number.

[0074] Among them, the MD5 value is the parameter obtained by the MD5 algorithm. The MD5 algorithm is the MD5 Message-Digest Algorithm information digest algorithm, a widely used cryptographic hash function. The Media Access Control Address (Mac) address is the physical address of the device. The MAC address is used to uniquely identify a network card in the network. If a device has one or more network cards, each network card needs and will have a unique Mac address.

[0075] See also Figure 1 , Figure 1 This is a schematic diagram of the process of server-based feature authorization verification in the prior art, taking the machine feature as the Mac address and the encryption algorithm as the DES feature as an example, specifically including:

[0076] S101. Obtain the Mac address of the server, and generate an MD5 value according to the obtained Mac address.

[0077] S102: Encrypt the MD5 value to generate an authorization code or authorization file lisence.txt.

[0078] S103. Send authorization information to the customer. The customer enters the authorization code in the software or uploads the authorization file lisence.txt.

[0079] S104: The software parses the authorization code or authorization file and obtains the MD5 value after decryption.

[0080] S105. Compare MD5 values.

[0081] The software obtains the Mac address of the currently running server and generates an MD5 value. The MD5 values ​​of S104 and S105 are compared. If they are consistent, the software system is successfully activated. Otherwise, it fails.

[0082] Among them, the Data Encryption Standard (DES) is a block algorithm that uses key encryption.

[0083] exist Figure 1 The solution has the following problems: once authorized, it can be used all the time, and the software usage time cannot be limited; the authorization information can be reused. For example, by modifying the MAC address of other servers to the existing MAC address, the software on multiple servers can be activated with one authorization information.

[0084] It can be seen that generating authorization information based on server characteristics cannot restrict illegal use of software.

[0085] In order to solve the technical problem of being unable to restrict the illegal use of software, the following technical solution in the embodiment of the present invention may be adopted.

[0086] See also Figure 2 , Figure 2 Schematic diagram of the main flow of the authorization verification method according to an embodiment of the present invention, which verifies the user through the user identification in the user authorization code and the validity period of the authorization code in the user authorization code, thereby limiting the illegal use of the software. Figure 2 As shown, the specific steps include:

[0087] S201. Decrypt the user authorization code using the public key to obtain the encrypted authorization code.

[0088] In the embodiment of the present invention, two ends are involved, namely, a server and a client, wherein the server can be arranged in a server for developing software, and the client can be arranged in a server for using software.

[0089] See also Figure 3 , Figure 3 It is a schematic diagram of a usage scenario of a method for application authorization verification according to an embodiment of the present invention, which specifically includes a server and two clients.

[0090] The server is used to generate a user authorization password for the user. The server can send the generated user authorization password to the user. As an example, the server sends the user authorization password to the user by email or other means. After receiving the user authorization password, the user can enter the user authorization password on the client. If the user authorization password is successfully verified, the user can continue to use the software; if the user authorization password verification fails, the user cannot continue to use the software after the actual number of days of use.

[0091] Understandably, Figure 2 The execution subject of each step is the client.

[0092] In order to avoid leaking authorization information, the user authorization code is encrypted by the server. The client needs to decrypt the user authorization code to obtain the authorization information.

[0093] In the embodiment of the present invention, decrypting the user authorization code is divided into two steps. The first step is to decrypt using the public key, and the second step is to decrypt using the user secret key. Among them, the public key is preset in the software, and the user secret key is preset in the user authorization code.

[0094] See also Figure 4 , Figure 4 Schematic diagram of decrypting a user authorization code according to an embodiment of the present invention, wherein, after receiving the user authorization code, the client can use the public key and DES to decrypt the user authorization code to obtain an encrypted authorization code. In one embodiment of the present invention, the user authorization code can be input by the user.

[0095] That is to say, a public key is pre-set in the software, and the public key user decrypts the user authorization code to obtain the encrypted authorization code.

[0096] S202. Decrypt the original authorization code in the encrypted authorization code based on the user secret key obtained from the encrypted authorization code to obtain the user identification, the validity period of the authorization code, and the number of days for authorized use.

[0097] The encrypted authorization code includes the user key and the original authorization code, and the user key can be used to decrypt the original authorization code.

[0098] See also Figure 5 , Figure 5 1 is a schematic diagram of a process for decrypting an original authorization code according to an embodiment of the present invention, which specifically includes:

[0099] S501. Obtain a user key and an original authorization code from the encrypted authorization code by encrypting preset characters in the authorization code.

[0100] In the encrypted authorization code, the user key and the original authorization code are separated by preset characters. Then, by identifying the preset characters in the encrypted authorization code, the user key and the original authorization code can be obtained from the encrypted authorization code.

[0101] In the embodiment of the present invention, in order to quickly obtain the user key and the original authorization code, the preset characters include preset special characters. That is, the user key and the original authorization are separated by the preset special characters. For example, the preset special character is: #. Of course, it can also be other special characters.

[0102] S502: Based on the user secret key, decrypt the original authorization code in the encrypted authorization code to obtain the user identification, the validity period of the authorization code and the number of days for authorized use.

[0103] According to the user's secret key, the original authorization code in the encrypted authorization code can be decrypted to obtain the user ID, authorization code validity period and authorized usage days.

[0104] See also Figure 6 , Figure 6 It is a schematic diagram of decrypting the original authorization code according to an embodiment of the present invention, which specifically includes: using the user key to decrypt the original authorization code in the encrypted authorization code, the user identification, the validity period of the authorization code and the number of days for authorized use can be obtained.

[0105] See also Figure 7 , Figure 7 1 is a schematic diagram of a process for decrypting an original authorization code according to an embodiment of the present invention, which specifically includes the following steps:

[0106] S701. Decrypt the original authorization code in the encrypted authorization code to obtain a concatenated authorization code.

[0107] The user secret key is combined with DEC to decrypt the original authorization code in the encrypted authorization code to obtain the spliced ​​authorization code.

[0108] In the embodiment of the present invention, the spliced ​​authorization code is spliced ​​by the user identification, the authorization code validity period and the authorized use days. The user identification, the authorization code validity period and the authorized use days are separated by a preset character.

[0109] S702: Segment the spliced ​​authorization code according to the preset characters in the spliced ​​authorization code to obtain the user identification, the validity period of the authorization code and the number of days for authorized use.

[0110] Since the user ID, authorization code validity period and authorized use days are separated by preset characters, the concatenated authorization code can be divided according to the preset characters in the concatenated authorization code to obtain the user ID, authorization code validity period and authorized use days.

[0111] In the embodiment of the present invention, in order to quickly obtain the user identification, the validity period of the authorization code and the number of days for authorized use, the preset characters include preset special characters. That is, the user key and the original authorization are separated by the preset special characters. For example, the preset special character is: #. Of course, it can also be other special characters.

[0112] As an example, the concatenated authorization code is: T1#YYYYMMDD#D1. The concatenated authorization code is split according to the preset character # to obtain T1, YYYYMMDD and D1, user number T1, authorization code validity period YYYYMMDD, and authorized use days D1.

[0113] In the above Figure 7 In the embodiment, the spliced ​​authorization code includes not only the user identification but also the validity period of the authorization code and the number of days for authorized use, and can be segmented according to the preset characters in the spliced ​​authorization code.

[0114] In the above Figure 5 In the embodiment, the user identification, validity period of the authorization code and number of days of authorized use are obtained by encrypting the authorization code. On the one hand, preset characters are used to ensure that information can be extracted. On the other hand, the original authorization code is decrypted by the user key to ensure the security of the original authorization code.

[0115] S203: If the user ID obtained by decryption is consistent with the actual user ID and the current date does not exceed the validity period of the authorization code, the actual usage days of the software are updated by the authorized usage days.

[0116] The client is preset with the user ID and the actual number of days the software is used. As an example, in order to ensure the security of the user ID and the actual number of days the software is used and to prevent the above information from being illegally modified, the actual user ID and the actual number of days the software is used are encrypted with a public key and stored on the client. During the authorization verification process, the public key is used to decrypt and obtain the actual user ID and the actual number of days the software is used.

[0117] Table 1

[0118] User ID Actual use days T1 D=0

[0119] See Table 1, which is a table in which the client stores user IDs and actual usage days. Table 1 can be encrypted by a public key.

[0120] If the decrypted user ID is consistent with the actual user ID, it means that the user authorization code is for this user, not for other users. If the decrypted user ID is inconsistent with the actual user ID, it means that the user authorization code is for other users, and the decryption fails.

[0121] If the current date does not exceed the validity period of the authorization code, it means that the user authorization code is valid; if the current date exceeds the validity period of the authorization code, it means that the user authorization code is invalid and the decryption has expired.

[0122] As an example, the current date is February 4, 2020, and the authorization code validity period is February 8, 2020. The current date does not exceed the authorization code validity period, and the user authorization code is valid.

[0123] As another example, the current date is February 9, 2020, and the authorization code is valid until February 8, 2020. The current date exceeds the authorization code validity period, the user authorization code is invalid, and the decryption expires.

[0124] See also Figure 8 , Figure 8 The flowchart of updating the service life of software according to an embodiment of the present invention specifically includes:

[0125] S801. Decrypt the configuration file using the public key to obtain the actual user ID and the validity period of the software.

[0126] In order to avoid illegal modification of the user ID and the actual number of days the software is used, the user ID and the actual number of days the software is used can be stored in a configuration file and encrypted with a public key. As an example, the configuration file can be Table 1 above.

[0127] When the validity period of the software needs to be updated, the configuration file can be decrypted using the public key to obtain the actual user identification and the validity period of the software.

[0128] S802: If the user ID obtained by decryption is consistent with the actual user ID and the current date does not exceed the validity period of the authorization code, the number of authorized use days is increased to the actual number of days the software is used.

[0129] If the decrypted user ID is consistent with the actual user ID and the current date does not exceed the validity period of the authorization code, it means that the user authorization code is valid, then the authorized usage days will be increased to the actual usage days of the software.

[0130] As an example, the actual usage days of the software are 2 days, the user authorization code is valid, and the authorized usage days are 30 days, then the actual usage days of the updated software are 32 days.

[0131] exist Figure 8 In the embodiment, when the user authorization code is valid, the actual usage days of the software can be updated by the authorized usage days.

[0132] In one embodiment of the present invention, the actual number of days of use of the software is updated over time. As an example, the actual number of days of use of the software is updated at least once a day. For example, at 24:00 every day, the actual number of days of use D in the configuration file is automatically updated, D=D-1 is executed, and the software is encrypted and saved using a public key.

[0133] In one embodiment of the present invention, in order to remind the user to obtain the user authorization code again to extend the actual use days of the software, a reminder message is sent when the actual use days of the software are less than or equal to the reminder days.

[0134] As an example, if the number of reminder days is 20 and the actual number of days the software is used is 19, a reminder message is sent to the user.

[0135] In one embodiment of the present invention, if the actual number of days the software is used is equal to zero, the software service is stopped and the user authorization code is waited for to be input.

[0136] The above is the actual number of days from when the client receives the user authorization code to update the software, which illustrates the technical solution in the embodiment of the present invention.

[0137] The following describes the specific technical solution for establishing a user authorization code from the perspective of the server.

[0138] In an embodiment of the present invention, a user authorization code may be established on the server side. Fig. 9 , Fig. 9 1 is a schematic diagram of a process for constructing a user authorization code according to an embodiment of the present invention, specifically including:

[0139] S901. The server uses the user key to encrypt the user ID, the validity period of the authorization code and the number of days for authorized use to obtain the original authorization code.

[0140] A user information table is stored in the server, see Table 2 for details. The user information table maintains user identification and user secret key. That is, each user identification has a corresponding user secret key.

[0141] Table 2

[0142] Username User ID User Key Uname1 T1 S1 Uname2 T2 S2

[0143] See also Fig.10 , Fig.10 1 is a schematic diagram of a process for establishing an original authorization code according to an embodiment of the present invention, which specifically includes:

[0144] S1001. Concatenate the user ID, the validity period of the authorization code, and the number of days for authorized use according to preset characters to obtain a concatenated authorization code.

[0145] The user identification, the validity period of the authorization code and the number of days for authorized use can be sequentially concatenated according to preset characters to obtain a concatenated authorization code, wherein the preset characters include preset special characters.

[0146] As an example, the preset character is #, the user identifier T1, the authorization code validity period YYYY MMDD and the authorized use days D1, then the spliced ​​authorization code T1#YYYYMMDD#D1 is obtained.

[0147] S1002. Use the user's secret key to encrypt the concatenated authorization code to obtain the original authorization code.

[0148] See also Fig.11 , Fig.11 Schematic diagram of obtaining the original authorization code according to an embodiment of the present invention. Each user identification has a corresponding user key, and the authorization code is encrypted and concatenated using the user key to obtain the original authorization code.

[0149] exist Fig.10 In the embodiment, preset characters are concatenated and encrypted with a user key to obtain the original authorization code.

[0150] S902. The server constructs an encrypted authorization code based on the original authorization code and the user's secret key.

[0151] The user key is not stored on the client. In order to send the user key to the client so that the client can decrypt the original authorization code, the server uses preset characters to concatenate the original authorization code and the user key to obtain the encrypted authorization code. The preset characters include preset special characters.

[0152] S903. The server encrypts the authorization code using the public key to obtain the user authorization code.

[0153] See also Fig.12 , Fig.12 Schematic diagram of obtaining a user authorization code according to an embodiment of the present invention. After the server obtains the encrypted authorization code, it can encrypt the encrypted authorization code with a public key to obtain the user authorization code.

[0154] exist Fig. 9 In the embodiment, the server forms an encrypted authorization code based on the original authorization code and combines the user key to generate the user authorization code, so that the client can obtain the user key to decrypt the original authorization code.

[0155] In the above-mentioned embodiment of the present invention, the user authorization code is decrypted using the public key to obtain the encrypted authorization code; based on the user secret key obtained from the encrypted authorization code, the original authorization code in the encrypted authorization code is decrypted to obtain the user identification, the authorization code validity period and the authorized use days; if the decrypted user identification is consistent with the actual user identification and the current date does not exceed the authorization code validity period, the actual use days of the software are updated by the authorized use days. Since not only the user identification can be verified, but also the validity period of the authorization code can be used for time verification, the illegal use of the software can be restricted.

[0156] Since encryption is no longer based on the server's characteristic data, nor does it rely on the authentication server to generate encryption, a complete and rigorous technical solution can independently generate user authorization codes and implement offline activation of authentication software on the client.

[0157] See also Fig.13 , Fig.13 is a schematic diagram of the main structure of an authorization verification device according to an embodiment of the present invention. The authorization verification device can implement an authorization verification method, such as Fig.13 As shown, the authorization verification device specifically includes:

[0158] The first decryption module 1301 is used to decrypt the user authorization code using the public key to obtain the encrypted authorization code.

[0159] The second decryption module 1302 is used to decrypt the original authorization code in the encrypted authorization code based on the user secret key obtained from the encrypted authorization code to obtain the user identification, the validity period of the authorization code and the number of days for authorized use.

[0160] The authorization module 1303 is used to update the actual usage days of the software with the authorized usage days if the user identification obtained by decryption is consistent with the actual user identification and the current date does not exceed the validity period of the authorization code.

[0161] In one embodiment of the present invention, the second decryption module 1302 is specifically configured to obtain the user key and the original authorization code from the encrypted authorization code by using preset characters in the encrypted authorization code;

[0162] Based on the user secret key, the original authorization code in the encrypted authorization code is decrypted to obtain the user identification, the validity period of the authorization code and the number of days for authorized use.

[0163] In one embodiment of the present invention, the second decryption module 1302 is specifically used to decrypt the original authorization code in the encrypted authorization code to obtain the spliced ​​authorization code;

[0164] The spliced ​​authorization code is segmented according to the preset characters in the spliced ​​authorization code to obtain the user identification, the validity period of the authorization code and the number of days for authorized use.

[0165] In one embodiment of the present invention, the authorization module 1303 is specifically used to decrypt the configuration file using the public key to obtain the actual user identification and the validity period of the software;

[0166] If the user identification obtained by decryption is consistent with the actual user identification and the current date does not exceed the validity period of the authorization code, the authorized usage days are added to the actual usage days of the software.

[0167] In one embodiment of the present invention, the user authorization code is input by the user.

[0168] In one embodiment of the present invention, the authorization module 1303 is specifically configured to update the actual number of days of use of the software at least once a day.

[0169] In one embodiment of the present invention, the authorization module 1303 is specifically configured to stop the service of the software if the actual number of days the software is used is equal to zero.

[0170] In one embodiment of the present invention, the authorization module 1303 is specifically configured to send a reminder message if the actual usage days of the software is less than or equal to the reminder days.

[0171] In one embodiment of the present invention, the authorization module 1303 is further used to control the server to encrypt the user identification, the validity period of the authorization code and the number of days for authorized use using the user key to obtain the original authorization code;

[0172] The control server forms the encrypted authorization code according to the original authorization code and the user secret key;

[0173] The control server encrypts the encrypted authorization code through a public key to obtain the user authorization code.

[0174] In one embodiment of the present invention, the authorization module 1303 is further used to control the splicing of the user identification, the validity period of the authorization code and the number of days of authorized use according to preset characters to obtain a spliced ​​authorization code;

[0175] The spliced ​​authorization code is encrypted using the user secret key to obtain the original authorization code.

[0176] In one embodiment of the present invention, the authorization module 1303 is further used to control the server to use preset characters to concatenate the original authorization code and the user key to obtain the encrypted authorization code.

[0177] In one embodiment of the present invention, the preset characters include preset special characters.

[0178] In one embodiment of the present invention, the server includes a user information table, and the user information table includes the user identifier and the user key.

[0179] In one embodiment of the present invention, the authorization module 1303 is further configured to display a decryption failure if the user identification obtained by decryption is inconsistent with the actual user identification.

[0180] In one embodiment of the present invention, the authorization module 1303 is further configured to display a decryption expiration date if the user identification obtained by decryption is consistent with the actual user identification and the current date has exceeded the validity period of the authorization code.

[0181] In one embodiment of the present invention, the method is applied in the software.

[0182] In one embodiment of the present invention, the public key is preset in the software.

[0183] Fig.14 An exemplary system architecture 1400 is shown to which the method or apparatus for authorization verification according to an embodiment of the present invention may be applied.

[0184] like Fig.14 As shown, system architecture 1400 may include terminal devices 1401, 1402, 1403, a network 1404, and a server 1405. Network 1404 is used to provide a medium for communication links between terminal devices 1401, 1402, 1403 and server 1405. Network 1404 may include various connection types, such as wired, wireless communication links, or optical fiber cables, etc.

[0185] Users can use terminal devices 1401, 1402, 1403 to interact with server 1405 through network 1404 to receive or send messages, etc. Various communication client applications can be installed on terminal devices 1401, 1402, 1403, such as shopping applications, web browser applications, search applications, instant messaging tools, email clients, social platform software, etc. (only as examples).

[0186] The terminal devices 1401 , 1402 , and 1403 may be various electronic devices having a display screen and supporting web browsing, including but not limited to smart phones, tablet computers, laptop computers, and desktop computers, etc.

[0187] The server 1405 may be a server that provides various services, such as a backend management server (only an example) that provides support for shopping websites browsed by users using the terminal devices 1401, 1402, and 1403. The backend management server may analyze and process the received data such as product information query requests, and feed back the processing results (such as target push information, product information - only an example) to the terminal device.

[0188] It should be noted that the authorization verification method provided in the embodiment of the present invention is generally executed by the server 1405 , and accordingly, the authorization verification device is generally set in the server 1405 .

[0189] It should be understood that Fig.14 The number of terminal devices, networks and servers in the embodiment is only for illustration. Any number of terminal devices, networks and servers may be provided according to implementation requirements.

[0190] Reference below Fig.15 , which shows a schematic diagram of the structure of a computer system 1500 of a terminal device suitable for implementing an embodiment of the present invention. Fig.15 The terminal device shown is only an example and should not bring any limitation to the functions and scope of use of the embodiments of the present invention.

[0191] like Fig.15 As shown, the computer system 1500 includes a central processing unit (CPU) 1501, which can perform various appropriate actions and processes according to a program stored in a read-only memory (ROM) 1502 or a program loaded from a storage part 1508 into a random access memory (RAM) 1503. In the RAM 1503, various programs and data required for the operation of the system 1500 are also stored. The CPU 1501, the ROM 1502, and the RAM 1503 are connected to each other through a bus 1504. An input / output (I / O) interface 1505 is also connected to the bus 1504.

[0192] The following components are connected to the I / O interface 1505: an input section 1506 including a keyboard, a mouse, etc.; an output section 1507 including a cathode ray tube (CRT), a liquid crystal display (LCD), etc., and a speaker, etc.; a storage section 1508 including a hard disk, etc.; and a communication section 1509 including a network interface card such as a LAN card, a modem, etc. The communication section 1509 performs communication processing via a network such as the Internet. A drive 1510 is also connected to the I / O interface 1505 as needed. A removable medium 1511, such as a magnetic disk, an optical disk, a magneto-optical disk, a semiconductor memory, etc., is installed on the drive 1510 as needed, so that a computer program read therefrom is installed into the storage section 1508 as needed.

[0193] In particular, according to the embodiments disclosed in the present invention, the process described above with reference to the flowchart can be implemented as a computer software program. For example, the embodiments disclosed in the present invention include a computer program product, which includes a computer program carried on a computer-readable medium, and the computer program includes a program code for executing the method shown in the flowchart. In such an embodiment, the computer program can be downloaded and installed from the network through the communication part 1509, and / or installed from the removable medium 1511. When the computer program is executed by the central processing unit (CPU) 1501, the above-mentioned functions defined in the system of the present invention are executed.

[0194] It should be noted that the computer-readable medium shown in the present invention may be a computer-readable signal medium or a computer-readable storage medium or any combination of the above two. The computer-readable storage medium may be, for example, but not limited to, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, device or device, or any combination of the above. More specific examples of computer-readable storage media may include, but are not limited to: an electrical connection with one or more wires, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the above. In the present invention, a computer-readable storage medium may be any tangible medium containing or storing a program that can be used by or in combination with an instruction execution system, device or device. In the present invention, a computer-readable signal medium may include a data signal propagated in a baseband or as part of a carrier wave, which carries a computer-readable program code. This propagated data signal may take a variety of forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination of the above. Computer-readable signal media may also be any computer-readable medium other than computer-readable storage media, which may send, propagate or transmit a program for use by or in conjunction with an instruction execution system, apparatus or device. The program code contained on the computer-readable medium may be transmitted using any appropriate medium, including but not limited to: wireless, wire, optical cable, RF, etc., or any suitable combination of the above.

[0195] The flow chart and block diagram in the accompanying drawings illustrate the possible architecture, function and operation of the system, method and computer program product according to various embodiments of the present invention. In this regard, each box in the flow chart or block diagram can represent a module, a program segment, or a part of a code, and the above-mentioned module, program segment, or a part of a code contains one or more executable instructions for realizing the specified logical function. It should also be noted that in some alternative implementations, the functions marked in the box can also occur in a different order from the order marked in the accompanying drawings. For example, two boxes represented in succession can actually be executed substantially in parallel, and they can sometimes be executed in the opposite order, depending on the functions involved. It should also be noted that each box in the block diagram or flow chart, and the combination of the boxes in the block diagram or flow chart can be implemented with a dedicated hardware-based system that performs a specified function or operation, or can be implemented with a combination of dedicated hardware and computer instructions.

[0196] The modules involved in the embodiments of the present invention may be implemented in software or hardware. The modules described may also be provided in a processor. For example, they may be described as follows: a processor includes a sending unit, an acquisition unit, a determination unit, and a first processing unit. The names of these units do not, in some cases, constitute limitations on the units themselves. For example, the sending unit may also be described as a "unit that sends a request for obtaining an image to a connected server."

[0197] As another aspect, the present invention further provides a computer-readable medium, which may be included in the device described in the above embodiment; or may exist independently without being assembled into the device. The above computer-readable medium carries one or more programs, and when the above one or more programs are executed by a device, the device includes:

[0198] Decrypt the user authorization code using the public key to obtain the encrypted authorization code;

[0199] Decrypting the original authorization code in the encrypted authorization code based on the user secret key obtained from the encrypted authorization code to obtain the user identification, the validity period of the authorization code and the number of days for authorized use;

[0200] If the user identification obtained by decryption is consistent with the actual user identification and the current date does not exceed the validity period of the authorization code, the actual usage days of the software are updated by the authorized usage days.

[0201] According to the technical solution of the embodiment of the present invention, the user authorization code is decrypted using the public key to obtain the encrypted authorization code; based on the user secret key obtained from the encrypted authorization code, the original authorization code in the encrypted authorization code is decrypted to obtain the user identification, the authorization code validity period and the authorized use days; if the decrypted user identification is consistent with the actual user identification, and the authorization code validity period does not exceed the current date, the actual use days of the software are updated by the authorized use days. Since not only the user identification can be verified, but also the validity period of the authorization code can be used for time verification, the illegal use of the software can be restricted.

[0202] The above specific implementations do not constitute a limitation on the protection scope of the present invention. It should be understood by those skilled in the art that various modifications, combinations, sub-combinations and substitutions may occur depending on design requirements and other factors. Any modification, equivalent substitution and improvement made within the spirit and principle of the present invention shall be included in the protection scope of the present invention.

Claims

1. A method for authorization verification, characterized in that: The execution subject is the client, including: Decrypt the user authorization code using the public key to obtain the encrypted authorization code; Decrypting the original authorization code in the encrypted authorization code based on the user secret key obtained from the encrypted authorization code to obtain the user identification, the validity period of the authorization code and the number of days for authorized use; If the decrypted user ID is consistent with the actual user ID and the current date does not exceed the validity period of the authorization code, the actual usage days of the software are updated by the authorized usage days; The method of decrypting the original authorization code in the encrypted authorization code based on the user secret key obtained from the encrypted authorization code to obtain the user identification, the validity period of the authorization code and the number of days for authorized use includes: Obtaining the user key and the original authorization code from the encrypted authorization code by using preset characters in the encrypted authorization code; Based on the user secret key, decrypt the original authorization code in the encrypted authorization code to obtain the user identification, the validity period of the authorization code and the number of days for authorized use; The decrypting of the original authorization code in the encrypted authorization code to obtain the user identification, the validity period of the authorization code and the number of days for authorized use includes: Decrypting the original authorization code in the encrypted authorization code to obtain a concatenated authorization code; According to the preset characters in the spliced ​​authorization code, the spliced ​​authorization code is divided to obtain the user identification, the validity period of the authorization code and the number of days for authorized use; If the user ID obtained by decryption is consistent with the actual user ID, and the current date does not exceed the validity period of the authorization code, the actual usage days of the software are updated by the authorized usage days, including: Decrypting the configuration file using the public key to obtain the actual user ID and the validity period of the software; If the user identification obtained by decryption is consistent with the actual user identification and the current date does not exceed the validity period of the authorization code, the authorized usage days are added to the actual usage days of the software.

2. The authorization verification method according to claim 1, characterized in that: The user authorization code is input by the user.

3. The authorization verification method according to claim 1, characterized in that: The method further comprises: The actual usage days of the software are updated at least once a day.

4. The authorization verification method according to claim 1, characterized in that: The method further comprises: If the actual number of days the software is used is equal to zero, the service of the software is stopped.

5. The authorization verification method according to claim 1, characterized in that: The method further comprises: If the actual usage days of the software are less than or equal to the reminder days, a reminder message is sent.

6. The authorization verification method according to claim 1, characterized in that: The method further comprises: The server uses the user's secret key to encrypt the user ID, the validity period of the authorization code, and the number of days for authorized use to obtain the original authorization code; The server constructs the encrypted authorization code according to the original authorization code and the user secret key; The server encrypts the encrypted authorization code using a public key to obtain the user authorization code.

7. The authorization verification method according to claim 6, characterized in that: The server uses the user key to encrypt the user ID, the validity period of the authorization code, and the number of days for authorized use to obtain the original authorization code, including: According to the preset characters, the user ID, the validity period of the authorization code and the number of days for authorized use are concatenated to obtain a concatenated authorization code; The spliced ​​authorization code is encrypted using the user secret key to obtain the original authorization code.

8. The authorization verification method according to claim 6, characterized in that: The server forms the encrypted authorization code according to the original authorization code and the user secret key, including: The server uses preset characters to concatenate the original authorization code and the user key to obtain the encrypted authorization code.

9. The authorization verification method according to claim 7 or 8, characterized in that: The preset characters include preset special characters.

10. The authorization verification method according to claim 7, characterized in that: The server includes a user information table, and the user information table includes the user identifier and the user key.

11. The authorization verification method according to claim 1, characterized in that: The method further comprises: If the decrypted user ID is inconsistent with the actual user ID, the decryption failure is displayed.

12. The authorization verification method according to claim 1, characterized in that: The method further comprises: If the user ID obtained by decryption is consistent with the actual user ID and the current date has exceeded the validity period of the authorization code, the decryption expired message will be displayed.

13. The authorization verification method according to claim 1, characterized in that: The method is applied in the software.

14. The authorization verification method according to claim 1, characterized in that: The public key is preset in the software.

15. An authorization verification device, characterized in that: The execution subject is the client, including: A first decryption module, used to decrypt the user authorization code using a public key to obtain an encrypted authorization code; A second decryption module is used to decrypt the original authorization code in the encrypted authorization code based on the user key obtained from the encrypted authorization code to obtain the user identification, the validity period of the authorization code and the number of days for authorized use; and to obtain the user key and the original authorization code from the encrypted authorization code through the preset characters in the encrypted authorization code; to decrypt the original authorization code in the encrypted authorization code based on the user key to obtain the user identification, the validity period of the authorization code and the number of days for authorized use; and to decrypt the original authorization code in the encrypted authorization code to obtain the spliced ​​authorization code; to segment the spliced ​​authorization code according to the preset characters in the spliced ​​authorization code to obtain the user identification, the validity period of the authorization code and the number of days for authorized use; The authorization module is used to update the actual usage days of the software by the authorized usage days if the user identification obtained by decryption is consistent with the actual user identification and the current date does not exceed the validity period of the authorization code, and to decrypt the configuration file using the public key to obtain the actual user identification and the usage period of the software; if the user identification obtained by decryption is consistent with the actual user identification and the current date does not exceed the validity period of the authorization code, the authorized usage days are added to the actual usage days of the software.

16. An electronic device for authorization verification, characterized in that: include: one or more processors; a storage device for storing one or more programs, When the one or more programs are executed by the one or more processors, the one or more processors implement the method according to any one of claims 1 to 14.

17. A computer readable medium having a computer program stored thereon, characterized in that: When the program is executed by a processor, the method according to any one of claims 1 to 14 is implemented.

Citation Information

Patent Citations

  • Software starting method, software authorization verification method, equipment and storage medium

    CN109684790A