CN111723362B - Authority password generation method, system, device and terminal equipment - Google Patents

Authority password generation method, system, device and terminal equipment Download PDF

Info

Publication number
CN111723362B
CN111723362B CN201910222935.7A CN201910222935A CN111723362B CN 111723362 B CN111723362 B CN 111723362B CN 201910222935 A CN201910222935 A CN 201910222935A CN 111723362 B CN111723362 B CN 111723362B
Authority
CN
China
Prior art keywords
charging
password
parameter
code
equipment
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN201910222935.7A
Other languages
Chinese (zh)
Other versions
CN111723362A (en
Inventor
倪晓
邓德军
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Individual
Original Assignee
Individual
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Individual filed Critical Individual
Priority to CN201910222935.7A priority Critical patent/CN111723362B/en
Publication of CN111723362A publication Critical patent/CN111723362A/en
Application granted granted Critical
Publication of CN111723362B publication Critical patent/CN111723362B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F21/00Security arrangements for protecting computers, components thereof, programs or data against unauthorised activity
    • G06F21/30Authentication, i.e. establishing the identity or authorisation of security principals
    • G06F21/45Structures or tools for the administration of authentication
    • G06F21/46Structures or tools for the administration of authentication by designing passwords or checking the strength of passwords
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02TCLIMATE CHANGE MITIGATION TECHNOLOGIES RELATED TO TRANSPORTATION
    • Y02T10/00Road transport of goods or passengers
    • Y02T10/60Other road transportation technologies with climate change mitigation effect
    • Y02T10/70Energy storage systems for electromobility, e.g. batteries

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Security & Cryptography (AREA)
  • Theoretical Computer Science (AREA)
  • Computer Hardware Design (AREA)
  • Software Systems (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Charge And Discharge Circuits For Batteries Or The Like (AREA)

Abstract

The invention provides a method, a device and a terminal device for generating a permission password, which are applicable to the technical field of data processing, wherein the method comprises the following steps: obtaining a maximum value m of key numbers corresponding to the charging equipment, a number set corresponding to the keys, a preset password length h and a preset parameter number; combining dynamic codes with the length of h-2 for the digits in the digit set to obtain m (h-2) dynamic codes, and randomly selecting one dynamic code; calculating the digital sum of each number in the selected dynamic code, and calculating a check code based on the digital sum, a preset parameter number and a maximum value m of key numbers; and combining the selected dynamic code, the preset parameter code and the check code to obtain a corresponding authority password, and sending the authority password to the charging equipment and the user equipment so that the user obtains the use authority of the charging equipment based on the authority password received in the user equipment. The embodiment of the invention greatly improves the use safety of the shared charging equipment.

Description

Authority password generation method, system, device and terminal equipment
Technical Field
The invention belongs to the technical field of data processing, and particularly relates to a permission password generation method and terminal equipment.
Background
With the development of technology, more and more devices need to be operated by using electric energy, such as electric vehicles and mobile terminals, and in actual situations, because of the problems of large power consumption, insufficient battery capacity and the like, the devices have larger charging demands, so that users often need to charge once or even multiple times a day.
In order to facilitate the charging of users, self-service renting and selling shared charging equipment such as a shared charging pile, a shared charger and the like appears in the market, the users can freely select a required charging mode by scanning two-dimension codes of the shared charging equipment, a corresponding password can be obtained after the payment of package fees is completed, and finally, the use permission of the shared charging equipment can be obtained and the shared charging equipment can be charged by inputting the obtained password into a password keyboard of the shared charging equipment. In practical application, a password of the shared charging equipment is preset by a technician, and one password library is selected as the current authority password when needed each time, but the fixed password library is extremely easy to be cracked by lawbreakers, so that the use safety of the shared charging equipment is difficult to be ensured.
Disclosure of Invention
In view of the above, the embodiment of the invention provides a permission password generation method and terminal equipment, so as to solve the problem of low use security of shared charging equipment in the prior art.
A first aspect of an embodiment of the present invention provides a method for generating a permission password, including:
obtaining a maximum value m of key numbers corresponding to the charging equipment, a number set corresponding to the keys, a preset password length h and a preset parameter number, wherein m and h are positive integers, each key corresponds to one number in the number set only, and the preset parameter number is a positive integer smaller than or equal to m;
combining the dynamic codes with the length of h-2 for the numbers in the number set to obtain m (h-2) dynamic codes, and randomly selecting one dynamic code;
calculating the digital sum of each number in the selected dynamic code, and calculating a check code based on the digital sum, the preset parameter number and the maximum value m of key numbers;
and combining the selected dynamic code, the preset parameter code and the check code to obtain a corresponding permission password, and sending the permission password to the charging equipment and the user equipment so that a user obtains the use permission of the charging equipment based on the permission password received in the user equipment.
A first aspect of an embodiment of the present invention provides two rights password generation systems, including: the charging system comprises a server, charging equipment and user equipment;
the user equipment is used for sending equipment information of the charging equipment to the server;
the server is used for acquiring a maximum value m of key numbers corresponding to the charging equipment, a number set corresponding to the keys, a preset password length h and a preset parameter number based on the equipment information, wherein m and h are positive integers, each key corresponds to one number in the number set only, and the preset parameter number is a positive integer smaller than or equal to m;
the server is also used for carrying out dynamic code combination with the length of h-2 on the numbers in the number set to obtain m (h-2) dynamic codes, and randomly selecting one dynamic code;
the server is also used for calculating the digital sum of each number in the selected dynamic code and calculating a check code based on the digital sum, the preset parameter number and the maximum value m of the key numbers;
the server is further configured to combine the selected dynamic code, the preset parameter code and the check code to obtain a corresponding permission password, and send the permission password to the charging device and the user device;
the user equipment is used for displaying the received authority password so as to enable a user to know the authority password;
the charging equipment is also used for receiving the authority password input by the user and carrying out password verification on the authority password input by the user based on the received authority password sent by the server;
and the charging equipment is also used for opening the charging authority if the password verification is successful, so that the user can use the charging equipment to charge.
A third aspect of an embodiment of the present invention provides a rights password generating device, including:
the data acquisition module is used for acquiring a maximum value m of key numbers corresponding to the charging equipment, a number set corresponding to the keys, a preset password length h and a preset parameter number, wherein m and h are positive integers, each key corresponds to one number in the number set only, and the preset parameter number is a positive integer smaller than or equal to m;
the dynamic code generation module is used for carrying out dynamic code combination with the length of h-2 on the digits in the digit set to obtain m (h-2) dynamic codes, and randomly selecting one dynamic code;
the check code generation module is used for calculating the digital sum of each number in the selected dynamic code and calculating the check code based on the digital sum, the preset parameter number and the maximum value m of the key number;
the password generation module is used for combining the selected dynamic code, the preset parameter code and the check code to obtain a corresponding permission password, and sending the permission password to the charging equipment and the user equipment so that a user can acquire the use permission of the charging equipment based on the permission password received in the user equipment.
A fourth aspect of the embodiments of the present invention provides a terminal device, the terminal device comprising a memory, a processor, the memory storing a computer program executable on the processor, the processor implementing the steps of the rights password generation method as described above when executing the computer program.
Compared with the prior art, the embodiment of the invention has the beneficial effects that: according to the practical key number maximum value, the corresponding number and other conditions of the charging equipment and the preset password length, a plurality of corresponding selectable dynamic codes are calculated, random selection is carried out, meanwhile, digital summation is carried out based on the selected dynamic codes, then, a corresponding check code is calculated according to the number, the preset parameter number and the practical key number maximum value, and finally, the dynamic codes, the parameter number and the check code are combined to obtain a final authority password, so that the finally generated authority password can adapt to different practical conditions of the charging equipment, and meanwhile, the password has extremely high randomness, so that the cracking difficulty is increased exponentially relative to a fixed password library, and the use safety of the shared charging equipment is greatly improved.
Drawings
In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the drawings that are needed in the embodiments or the description of the prior art will be briefly described below, it being obvious that the drawings in the following description are only some embodiments of the present invention, and that other drawings may be obtained according to these drawings without inventive effort for a person skilled in the art.
Fig. 1 is a schematic flow chart of an implementation of a method for generating a right password according to an embodiment of the present invention;
fig. 2 is a schematic implementation flow chart of a rights password generation method according to a second embodiment of the present invention;
fig. 3 is a schematic implementation flow chart of a rights password generation method according to a third embodiment of the present invention;
fig. 4 is a schematic implementation flow chart of a rights password generation method according to a fourth embodiment of the present invention;
FIG. 5 is a system interaction diagram of a rights password generation system provided in a fifth embodiment of the present invention;
fig. 6 is a schematic structural diagram of a rights password generating device according to a sixth embodiment of the present invention;
fig. 7 is a schematic diagram of a terminal device according to a seventh embodiment of the present invention.
Detailed Description
In the following description, for purposes of explanation and not limitation, specific details are set forth such as the particular system architecture, techniques, etc., in order to provide a thorough understanding of the embodiments of the present invention. It will be apparent, however, to one skilled in the art that the present invention may be practiced in other embodiments that depart from these specific details. In other instances, detailed descriptions of well-known systems, devices, circuits, and methods are omitted so as not to obscure the description of the present invention with unnecessary detail.
In order to illustrate the technical scheme of the invention, the following description is made by specific examples.
In order to facilitate understanding of the present invention, the embodiment of the present invention is first briefly introduced, in order to improve the security of the shared charger password, the embodiment of the present invention discards the conventional method of password extraction of the fixed password bank, but combines the actual number of the password input keys corresponding to the charging device and the corresponding digital situation, and simultaneously, automatically selects or sets the total password length by a technician, then automatically calculates a plurality of corresponding selectable dynamic codes and randomly selects, and finally combines the dynamic codes, the parameter codes and the check codes to obtain the final authority password, and because the whole process, the dynamic codes are in an actual situation of the charging device and the preset password length, and have randomness, so that the finally obtained dynamic codes have controllable length and very strong randomness, and the check codes are also determined based on the dynamic codes, the preset parameter codes and the key numbers, and the corresponding check codes are also in a situation of having very strong randomness, and are also suitable for the actual situation of the charging device, and finally the dynamic codes, and the parameter codes and the check codes are combined to obtain the final authority password, and the practical situation of the charging device has very high security, and the security of the shared password bank is greatly improved. The details are as follows:
fig. 1 shows a flowchart of an implementation of a method for generating a rights password according to an embodiment of the present invention, which is described in detail below:
s101, obtaining a maximum value m of key numbers corresponding to the charging equipment, a number set corresponding to the keys, a preset password length h and a preset parameter number, wherein m and h are positive integers, each key corresponds to one number in the number set only, and the preset parameter number is a positive integer smaller than or equal to m.
Because of the requirements of different charging devices on the password security level and the limitation of the actual hardware environment and cost, the number of the password input keyboards set by each charging device in practical application also has certain difference, for example, some small mobile phone sharing chargers have smaller volumes and lower cost and relatively lower requirements on the password security level, so that the password keyboards of general mobile phone sharing chargers also have smaller numbers of contained keys, for example, three keys and four keys can be contained, and for the sharing charging piles of electric automobiles, the volume is high, the cost is high, and the requirements on the level of the password security are also high in consideration of the higher security requirements of the used strong electricity, so that the number of keys contained in the password keyboards of general sharing charging piles is also more, for example, 9 keys can be contained, and therefore, for different charging devices, certain difference exists in the number of keys which are specifically contained, and certain difference correspondingly exists in the number conditions and the maximum value conditions of the keys. The number set corresponding to the keys refers to a set formed by numbers corresponding to each password key, if the number set is {1,2,3,4}, when there are 4 cases, the corresponding numbers are 1,2,3, and 4, respectively. The password length refers to the total length of the finally generated password, and in the embodiment of the invention, the finally generated password contains three parts of contents of dynamic code, parameter code and check code, so the password length refers to the total length of the three parts of contents. The parameter numbers are preset, and a technician can classify different charging equipment according to one digit of numbers set by different actual charging equipment, and set corresponding parameter numbers for each type respectively so as to generate corresponding passwords aiming at the actual conditions of different charging equipment.
In practical application, the two-dimensional code recorded with the equipment information of the charging equipment and the server address is preset on the charging equipment, so that when a user accesses the server through the two-dimensional code, the server can identify the equipment and read the data such as the number of keys of the equipment, the password length of the corresponding digital set, the preset parameter number and the like.
S102, combining dynamic codes with the length of h-2 for the numbers in the digital set to obtain m (h-2) dynamic codes, and randomly selecting one dynamic code.
In the embodiment of the invention, the finally generated password comprises three parts of contents of a dynamic code, a parameter code and a check code, wherein the parameter code is preset by a technician, the check code is calculated according to the maximum values of the dynamic code, the parameter code and the key number, the parameter code and the check code are all one-digit numbers, and the dynamic code is generated when the user needs to acquire each time, so that the length=h-2 of the dynamic code.
After determining the length of the dynamic code, the embodiment of the invention randomly selects numbers from the number set to perform ordering combination to obtain corresponding m (h-2) dynamic codes, for example, the number set is assumed to be {1,2,3,4}, the length of the dynamic code is 3, and at this time, the following 64 dynamic codes can be obtained through random ordering combination:
111 112 113 114 211 212 213 214 311 312 313 314 411 412 413 414
121 122 123 124 221 222 223 224 321 322 323 324 421 422 423 424
131 132 133 134 231 232 233 234 331 332 333 334 431 432 433 434
141 142 143 144 241 242 243 244 341 342 343 344 441 442 443 444
and then randomly selecting a dynamic code from the codes.
S103, calculating the digital sum of each number in the selected dynamic code, and calculating the check code based on the digital sum, the preset parameter number and the maximum value m of the key numbers.
After determining the dynamic code, embodiments of the present invention may further calculate the sum of the digits in the dynamic code, for example, assuming that the dynamic code is 123, where a corresponding sum value of 6 may be obtained. After determining the sum, a corresponding check code is calculated based on the sum and the parameter number and the maximum value of the key number, wherein the specific calculation method includes, but is not limited to, performing an and operation on each parameter or performing a process according to the second embodiment of the present invention. Because the dynamic code has very strong randomness, and the maximum values of the parameter number and the key number are closely related to the actual situation of the charging equipment, the finally obtained check code is suitable for the charging equipment while having very strong randomness.
S104, combining the selected dynamic code, the preset parameter code and the check code to obtain a corresponding authority password, and sending the authority password to the charging equipment and the user equipment so that the user can acquire the use authority of the charging equipment based on the authority password received in the user equipment.
After the dynamic code and the check code are calculated, the embodiment of the present invention combines them with the parameter code to obtain the final authority password, wherein the specific combination sequence is not limited herein, for example, if the obtained dynamic code is 123, the parameter code is 3, the check code is 2, and the final authority password can be 12332.
As a specific implementation manner of calculating the check code in the first embodiment of the present invention, as shown in fig. 2, the second embodiment of the present invention includes:
s201, calculating the sum value of the digital sum and the preset parameter number to obtain a first check parameter.
S202, calculating a second checking parameter and a correction coefficient based on the digital set, wherein the second checking parameter is smaller than or equal to m.
S203, performing AND operation on the first check parameter and the second check parameter, and obtaining a sum value of an original check code and a correction coefficient obtained by the AND operation to obtain a corresponding check code.
In the embodiment of the invention, the digital sum of the dynamic code is summed with the parameter code to obtain the corresponding first verification parameter, and the first verification parameter is based on
The sum value of the numbers and the parameter numbers is difficult to know in advance due to randomness, the second check parameter is not larger than m, so that the sum operation result is inevitably smaller than or equal to m, and in order to prevent mismatching of the number sequence on the keyboard and the maximum value m of the keyboard, for example, the number set corresponding to the keyboard is {1,2,3,4}, and the maximum value m=4 of the keyboard, so that the finally obtained sum operation result is not larger than m, but no corresponding number is arranged on the keyboard.
As a specific implementation manner of calculating the second calibration parameter and the correction coefficient in the second embodiment of the present invention, as shown in fig. 3, the third embodiment of the present invention includes:
s301, if the digital set contains the number 0, sets the second verification parameter to m, and sets the correction coefficient to 0.
S302, if the digital set does not contain the number 0, setting the second checking parameter to m-1, and setting the correction coefficient to 1.
Since the original check code obtained by the and operation may have 0, for example, the dynamic code is assumed to be 134, the corresponding digital sum is 8, the second check parameter is 4, at this time, the and operation is performed on 8 and 3 (i.e. 8 is converted into binary number 1000,4 and is converted into binary number 0100), the result is decimal 0, but in practical situations, the keyboard number may not have 0, that is, when the digital set does not contain 0, the check code cannot be input at this time, and the check code is invalid, therefore, the embodiment of the invention sets the second check parameter as m-1 and the correction parameter as 1 for the situation that the digital set does not contain 0, so that the validity of the check code can be ensured even if the original check code appears in the and operation is 0, and since the second check parameter is m-1, the maximum value of the and operation is m-1, so that the value of the final check code cannot overflow the digital set range.
As a fourth embodiment of the present invention, after the generation of the right password by the above-described embodiments one to three is completed, as shown in fig. 4, it includes:
s401, acquiring charging mode information input by a user, and searching corresponding charging time length based on the charging mode information, wherein the charging time length is used for controlling the authority opening time length of the charging equipment.
The charging mode refers to a charging package selected by a user for payment, and mainly refers to the time duration of charging selected by the user.
Transmitting the permission password to the charging device and the user device, comprising:
s403, sending the permission password to the user equipment, and sending the permission password and the charging time length to the charging equipment, so that the charging equipment starts charging timing when the charging permission is opened, and closing the charging permission when the charging timing time length is equal to the charging time length.
After the permission password and the charging time are acquired, the embodiment of the invention can send the permission password to the charging equipment together, and simultaneously can send the permission password to the user equipment independently, so that the user can acquire the permission password and charge the user.
In the embodiment of the invention, the actual number of keys and the corresponding number condition of the key are input by combining the corresponding password of the charging equipment, the total password length is automatically selected or set by a technician, then a plurality of corresponding selectable dynamic codes are automatically calculated and randomly selected, the corresponding check codes are set based on the dynamic codes and the preset parameter numbers and the maximum value of the key numbers, and finally the dynamic codes, the parameter numbers and the check codes are combined to obtain the final authority password.
Fig. 5 shows an interaction diagram of the rights password generation system provided in the fifth embodiment of the present invention, which is described in detail below:
the authority password generation system comprises: server 51, charging device 52 and user device 53.
The user device 53 is configured to transmit the device information of the charging device 52 to the server 51.
The server 51 is configured to obtain, based on the device information, a maximum value m of key numbers corresponding to the charging device 52, a number set corresponding to the key, a preset password length h, and a preset parameter number, where m and h are both positive integers, each key corresponds to one number in the number set uniquely, and the preset parameter number is a positive integer less than or equal to m.
The server 51 is further configured to perform a dynamic code combination of length h-2 on the digits in the digit set to obtain m (h-2) dynamic codes, and randomly select one of the dynamic codes.
The server 51 is further configured to calculate a digital sum of each number in the selected dynamic code, and calculate a check code based on the digital sum, the preset parameter number, and the key number maximum value m.
The server 51 is further configured to combine the selected dynamic code, the preset parameter code and the check code to obtain a corresponding permission password, and send the permission password to the charging device 52 and the user device 53.
The user device 53 is configured to display the received permission password so that the user can learn the permission password.
The charging device 52 is further configured to receive the permission password input by the user, and perform password verification on the permission password input by the user based on the permission password sent by the server 51.
The charging device 52 is further configured to open the charging right if the password verification is successful, so that the user can use the charging device 52 to perform charging.
In the embodiment of the invention, the charging device refers to a shared charging device capable of providing charging, and the user device refers to a device for acquiring a password by a user, such as an intelligent mobile terminal, and it should be noted that when the user actually performs charging, the charged device can be selected by a technician, and can be either a user device for acquiring the password or other devices.
In this embodiment, the implementation details may refer to the first embodiment of the present invention, and will not be described herein.
As an embodiment of the present invention, it includes:
the user equipment 53 is also used to send charging mode information to the server 51.
The server 51 is further configured to obtain a corresponding charging duration based on the received charging mode information, and send the charging duration to the charging device 52.
The charging device 52 is further configured to start charging timing when the charging right is opened, and to close the charging right when the charging timing duration is equal to the charging duration.
In the embodiment of the present invention, the permission opening duration of the user is controlled according to the charging duration, so as to realize accurate control of the user permission, where the implementation description of specific technical details may refer to the fourth related content of the embodiment of the present invention, which is not described herein.
As a specific implementation manner of calculating the check code in the fifth embodiment of the present invention, the method includes:
and calculating the sum value of the digital sum and the preset parameter number to obtain a first check parameter.
And calculating a second checking parameter and a correction coefficient based on the digital set, wherein the second checking parameter is less than or equal to m.
And performing AND operation on the first check parameter and the second check parameter, and obtaining a sum value of an original check code and a correction coefficient obtained by the AND operation to obtain a corresponding check code.
The implementation details of the specific technical details may refer to the second embodiment of the present invention and other related matters of the embodiments of the present invention, which are not described herein.
As a specific implementation manner of calculating the second verification parameter and the correction coefficient, it includes:
if the digital set contains the number 0, the second checking parameter is set to m, and the correction coefficient is set to 0.
If the digital set does not contain the number 0, the second verification parameter is set to m-1, and the correction coefficient is set to 1.
The implementation details of the third embodiment of the present invention and other related matters of the third embodiment of the present invention may be referred to, and are not described herein.
As another specific implementation manner of calculating the second verification parameter and the correction coefficient, the method includes:
if the digital set contains the number 0, the second checking parameter is set to m-1, and the correction coefficient is set to 0.
If the digital set does not contain the number 0, the second verification parameter is set to m-1, and the correction coefficient is set to 1.
The implementation details of the third embodiment of the present invention and other related matters of the third embodiment of the present invention may be referred to, and are not described herein.
Corresponding to the method of the above embodiment, fig. 6 shows a block diagram of the authority password generating device according to the embodiment of the present invention, and for convenience of explanation, only the portion related to the embodiment of the present invention is shown. The rights password generation apparatus illustrated in fig. 6 may be an execution subject of the rights password generation method provided in the first embodiment described above.
Referring to fig. 6, the authority password generation apparatus includes:
the data obtaining module 61 is configured to obtain a maximum value m of numbers of keys corresponding to the charging device, a number set corresponding to the keys, a preset password length h, and a preset parameter number, where m and h are both positive integers, each key uniquely corresponds to one number in the number set, and the preset parameter number is a positive integer less than or equal to m.
The dynamic code generating module 62 is configured to perform a dynamic code combination with a length of h-2 on the digits in the digit set to obtain m (h-2) dynamic codes, and randomly select one dynamic code.
The check code generating module 63 is configured to calculate a digital sum of each number in the selected dynamic code, and calculate a check code based on the digital sum, the preset parameter number, and the maximum value m of the key numbers.
The password generating module 64 is configured to combine the selected dynamic code, the preset parameter code and the check code to obtain a corresponding permission password, and send the permission password to the charging device and the user device, so that the user obtains the use permission of the charging device based on the permission password received in the user device.
Further, the check code generating module 63 includes:
and the first parameter calculation module is used for calculating the sum value of the digital sum and the preset parameter value to obtain a first check parameter.
And the second parameter calculation module is used for calculating a second check parameter and a correction coefficient based on the digital set, wherein the second check parameter is smaller than or equal to m.
And the AND operation module is used for performing AND operation on the first check parameter and the second check parameter, and obtaining the sum value of the original check code obtained by the AND operation and the correction coefficient to obtain a corresponding check code.
Further, the second parameter calculation module includes:
if the digital set contains the number 0, the second correction parameter is set to m, and the correction coefficient is set to 0.
If the digital set does not contain the number 0, the second correction parameter is set to m-1, and the correction coefficient is set to 1.
Further, the authority password generating device further includes:
and acquiring charging mode information input by the user, and searching corresponding charging time length based on the charging mode information, wherein the charging time length is used for controlling the authority opening time length of the charging equipment.
The sending the permission password to the charging equipment and the user equipment comprises the following steps:
and sending the permission password to the user equipment, and sending the permission password and the charging duration to the charging equipment.
The process of implementing the respective functions of each module in the permission password generating device provided in the embodiment of the present invention may refer to the description of the first embodiment shown in fig. 1, which is not repeated herein.
It should be understood that the sequence number of each step in the foregoing embodiment does not mean that the execution sequence of each process should be determined by the function and the internal logic, and should not limit the implementation process of the embodiment of the present invention.
It will also be understood that, although the terms "first," "second," etc. may be used herein in some embodiments of the invention to describe various elements, these elements should not be limited by these terms. These terms are only used to distinguish one element from another element. For example, a first table may be named a second table, and similarly, a second table may be named a first table without departing from the scope of the various described embodiments. The first table and the second table are both tables, but they are not the same table.
Fig. 7 is a schematic diagram of a terminal device according to an embodiment of the present invention. As shown in fig. 7, the terminal device 7 of this embodiment includes: a processor 70, a memory 71, said memory 71 having stored therein a computer program 72 executable on said processor 70. The steps of the various embodiments of the rights password generation method described above, such as steps 101 through 106 shown in fig. 1, are implemented by the processor 70 when executing the computer program 72. Alternatively, the processor 70, when executing the computer program 72, performs the functions of the modules/units of the apparatus embodiments described above, such as the functions of the modules 61 to 64 shown in fig. 6.
The terminal device 7 may be a computing device such as a desktop computer, a notebook computer, a palm computer, a cloud server, etc. The terminal device may include, but is not limited to, a processor 70, a memory 71. It will be appreciated by those skilled in the art that fig. 7 is merely an example of the terminal device 7 and does not constitute a limitation of the terminal device 7, and may include more or less components than illustrated, or may combine certain components, or different components, e.g., the terminal device may further include an input transmitting device, a network access device, a bus, etc.
The processor 70 may be a central processing unit (Central Processing Unit, CPU), or may be another general purpose processor, a digital signal processor (Digital Signal Processor, DSP), an application specific integrated circuit (Application Specific Integrated Circuit, ASIC), an off-the-shelf programmable gate array (Field-Programmable Gate Array, FPGA) or other programmable logic device, discrete gate or transistor logic device, discrete hardware components, or the like. A general purpose processor may be a microprocessor or the processor may be any conventional processor or the like.
The memory 71 may be an internal storage unit of the terminal device 7, such as a hard disk or a memory of the terminal device 7. The memory 71 may be an external storage device of the terminal device 7, such as a plug-in hard disk, a Smart Media Card (SMC), a Secure Digital (SD) Card, a Flash memory Card (Flash Card) or the like, which are provided on the terminal device 7. Further, the memory 71 may also include both an internal storage unit and an external storage device of the terminal device 7. The memory 71 is used for storing the computer program as well as other programs and data required by the terminal device. The memory 71 may also be used for temporarily storing data that has been transmitted or is to be transmitted.
In addition, each functional unit in the embodiments of the present invention may be integrated in one processing unit, or each unit may exist alone physically, or two or more units may be integrated in one unit. The integrated units may be implemented in hardware or in software functional units.
The integrated modules/units, if implemented in the form of software functional units and sold or used as stand-alone products, may be stored in a computer readable storage medium. Based on such understanding, the present invention may implement all or part of the flow of the method of the above embodiment, or may be implemented by a computer program to instruct related hardware, where the computer program may be stored in a computer readable storage medium, and when the computer program is executed by a processor, the computer program may implement the steps of each of the method embodiments described above. Wherein the computer program comprises computer program code which may be in source code form, object code form, executable file or some intermediate form etc. The computer readable medium may include: any entity or device capable of carrying the computer program code, a recording medium, a U disk, a removable hard disk, a magnetic disk, an optical disk, a computer Memory, a Read-Only Memory (ROM), a random access Memory (Random Access Memory, RAM), an electrical carrier signal, a telecommunications signal, a software distribution medium, and so forth.
The above embodiments are only for illustrating the technical solution of the present invention, and not for limiting the same; although the invention has been described in detail with reference to the foregoing embodiments, it will be understood by those of ordinary skill in the art that: the technical scheme described in the foregoing embodiments can be modified or some technical features thereof can be replaced by equivalents; such modifications and substitutions do not depart from the spirit and scope of the technical solutions of the embodiments of the present invention, and are intended to be included in the scope of the present invention.

Claims (10)

1. A rights password generation method, characterized by comprising:
obtaining a maximum value m of key numbers corresponding to the charging equipment, a number set corresponding to the keys, a preset password length h and a preset parameter number, wherein m and h are positive integers, each key corresponds to one number in the number set only, and the preset parameter number is a positive integer smaller than or equal to m;
combining the dynamic codes with the length of h-2 for the numbers in the number set to obtain m (h-2) dynamic codes, and randomly selecting one dynamic code;
calculating the digital sum of each number in the selected dynamic code, and calculating a check code based on the digital sum, the preset parameter number and the maximum value m of key numbers;
and combining the selected dynamic code, the preset parameter code and the check code to obtain a corresponding permission password, and sending the permission password to the charging equipment and the user equipment so that a user obtains the use permission of the charging equipment based on the permission password received in the user equipment, wherein the use permission comprises charging time.
2. The rights password generation method of claim 1, wherein the calculating a digital sum of each number in the selected dynamic code and calculating a check code based on the digital sum, the preset parameter number, and a key number maximum value m comprises:
calculating the sum value of the digital sum and the preset parameter number to obtain a first verification parameter;
calculating a second calibration parameter and a correction coefficient based on the digital set, wherein the second calibration parameter is less than or equal to m;
and performing AND operation on the first check parameter and the second check parameter, and obtaining a sum value of the original check code obtained by the AND operation and the correction coefficient to obtain a corresponding check code.
3. The rights password generation method of claim 2, wherein the calculating a second verification parameter and a correction coefficient based on the digital set, wherein the second verification parameter is less than or equal to m, comprises:
if the digital set contains a digital 0, setting the second checking parameter to m and setting the correction coefficient to 0;
if the digital set does not contain the number 0, the second correction parameter is set to m-1, and the correction coefficient is set to 1.
4. The rights password generation method of claim 1, further comprising:
acquiring charging mode information input by a user, and searching corresponding charging time length based on the charging mode information, wherein the charging time length is used for controlling the authority opening time length of the charging equipment;
the sending the permission password to the charging equipment and the user equipment comprises the following steps:
and sending the permission password to the user equipment, and sending the permission password and the charging time length to the charging equipment, so that the charging equipment starts charging timing when the charging permission is opened, and closing the charging permission when the charging timing time length is equal to the charging time length.
5. A charge management system, comprising: the charging system comprises a server, charging equipment and user equipment;
the user equipment is used for sending equipment information of the charging equipment to the server;
the server is used for acquiring a maximum value m of key numbers corresponding to the charging equipment, a number set corresponding to the keys, a preset password length h and a preset parameter number based on the equipment information, wherein m and h are positive integers, and each key uniquely corresponds to one number in the number set;
the server is also used for carrying out dynamic code combination with the length of h-2 on the numbers in the number set to obtain m (h-2) dynamic codes, and randomly selecting one dynamic code;
the server is also used for calculating the digital sum of each number in the selected dynamic code and calculating a check code based on the digital sum, the preset parameter number and the maximum value m of the key numbers;
the server is further configured to combine the selected dynamic code, the preset parameter code and the check code to obtain a corresponding permission password, and send the permission password to the charging device and the user device;
the user equipment is used for displaying the received authority password so as to enable a user to know the authority password;
the charging equipment is also used for receiving the authority password input by the user and carrying out password verification on the authority password input by the user based on the received authority password sent by the server;
and the charging equipment is also used for opening the charging authority if the password verification is successful, so that the user can use the charging equipment to charge.
6. The charge management system according to claim 5, further comprising:
the user equipment is also used for sending charging mode information to the server;
the server is further used for acquiring corresponding charging duration based on the received charging mode information and sending the charging duration to the charging equipment;
the charging device is further used for starting charging timing when the charging right is opened, and closing the charging right when the charging timing duration is equal to the charging duration.
7. The charge management system of claim 6, wherein said calculating a digital sum of each digit in the selected dynamic code and calculating a check code based on said digital sum, said preset parameter number, and a key number maximum value m comprises:
calculating the sum value of the digital sum and the preset parameter number to obtain a first verification parameter;
calculating a second calibration parameter and a correction coefficient based on the digital set, wherein the second calibration parameter is less than or equal to m;
and performing AND operation on the first check parameter and the second check parameter, and obtaining a sum value of the original check code obtained by the AND operation and the correction coefficient to obtain a corresponding check code.
8. The charge management system of claim 7, wherein the calculating a second calibration parameter and a correction factor based on the digital set, wherein the second calibration parameter is less than or equal to m comprises:
if the digital set contains a digital 0, setting the second checking parameter to m and setting the correction coefficient to 0;
if the digital set does not contain the number 0, the second correction parameter is set to m-1, and the correction coefficient is set to 1.
9. A rights password generation apparatus, characterized by comprising:
the data acquisition module is used for acquiring a maximum value m of key numbers corresponding to the charging equipment, a number set corresponding to the keys, a preset password length h and a preset parameter number, wherein m and h are positive integers, and each key uniquely corresponds to one number in the number set;
the dynamic code generation module is used for carrying out dynamic code combination with the length of h-2 on the digits in the digit set to obtain m (h-2) dynamic codes, and randomly selecting one dynamic code;
the check code generation module is used for calculating the digital sum of each number in the selected dynamic code and calculating the check code based on the digital sum, the preset parameter number and the maximum value m of the key number;
the password generation module is used for combining the selected dynamic code, the preset parameter code and the check code to obtain a corresponding permission password, and sending the permission password to the charging equipment and the user equipment so that a user can acquire the use permission of the charging equipment based on the permission password received in the user equipment, wherein the use permission comprises charging time.
10. A terminal device, characterized in that it comprises a memory, a processor, on which a computer program is stored which is executable on the processor, the processor executing the computer program to carry out the steps of the method according to any one of claims 1 to 4.
CN201910222935.7A 2019-03-22 2019-03-22 Authority password generation method, system, device and terminal equipment Active CN111723362B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201910222935.7A CN111723362B (en) 2019-03-22 2019-03-22 Authority password generation method, system, device and terminal equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201910222935.7A CN111723362B (en) 2019-03-22 2019-03-22 Authority password generation method, system, device and terminal equipment

Publications (2)

Publication Number Publication Date
CN111723362A CN111723362A (en) 2020-09-29
CN111723362B true CN111723362B (en) 2023-09-08

Family

ID=72562182

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201910222935.7A Active CN111723362B (en) 2019-03-22 2019-03-22 Authority password generation method, system, device and terminal equipment

Country Status (1)

Country Link
CN (1) CN111723362B (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113010859B (en) * 2021-02-18 2022-09-06 浪潮云信息技术股份公司 Activation code generation method supporting self-checking
CN113111341A (en) * 2021-04-12 2021-07-13 北京沃东天骏信息技术有限公司 Account sharing and login method and device

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106602657A (en) * 2016-12-29 2017-04-26 杭州微飞胜科技有限公司 Charging pile and working method thereof
CN107316367A (en) * 2017-08-29 2017-11-03 龙文凯 A kind of lock, Quick Response Code mark, coded lock power supply module that Quick Response Code respective function acquisition variable cipher is scanned with mobile phone
CN107358742A (en) * 2016-05-10 2017-11-17 简锦源 System and method for the charging of electric vehicle
CN107679370A (en) * 2017-10-13 2018-02-09 北京大学 A kind of device identification generation method and device
CN107785963A (en) * 2017-10-31 2018-03-09 北京伊电园网络科技有限公司 A kind of charging method and charging system
WO2018148868A1 (en) * 2017-02-14 2018-08-23 深圳市租电智能科技有限公司 Charging device based on dynamic password
CN109255890A (en) * 2018-09-30 2019-01-22 山东鲁能智能技术有限公司 Charging transaction control method, charging equipment and system

Family Cites Families (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101662465B (en) * 2009-08-26 2013-03-27 深圳市腾讯计算机系统有限公司 Method and device for verifying dynamic password
CN106341372A (en) * 2015-07-08 2017-01-18 阿里巴巴集团控股有限公司 Terminal authentication processing method and device, and terminal authentication method, device and system

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107358742A (en) * 2016-05-10 2017-11-17 简锦源 System and method for the charging of electric vehicle
CN106602657A (en) * 2016-12-29 2017-04-26 杭州微飞胜科技有限公司 Charging pile and working method thereof
WO2018148868A1 (en) * 2017-02-14 2018-08-23 深圳市租电智能科技有限公司 Charging device based on dynamic password
CN107316367A (en) * 2017-08-29 2017-11-03 龙文凯 A kind of lock, Quick Response Code mark, coded lock power supply module that Quick Response Code respective function acquisition variable cipher is scanned with mobile phone
CN107679370A (en) * 2017-10-13 2018-02-09 北京大学 A kind of device identification generation method and device
CN107785963A (en) * 2017-10-31 2018-03-09 北京伊电园网络科技有限公司 A kind of charging method and charging system
CN109255890A (en) * 2018-09-30 2019-01-22 山东鲁能智能技术有限公司 Charging transaction control method, charging equipment and system

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
电瓶车充电停车智能管理系统;陈玲君;;电子测试(第06期);全文 *

Also Published As

Publication number Publication date
CN111723362A (en) 2020-09-29

Similar Documents

Publication Publication Date Title
CN110245220B (en) Electronic document signing method, electronic document signing device, electronic document server and storage medium
EP3983979A1 (en) Dynamic off-chain digital currency transaction processing
CN109639677B (en) Cloud storage outsourcing decryption attribute-based encryption method capable of limiting access times
CN104011728B (en) For providing the device and method of the access to encryption data
US20190052461A1 (en) System for secure storage of cryptographic keys
CN108777033B (en) Shared charger treasure leasing method based on shared leasing equipment and terminal equipment thereof
CN110768967B (en) Service authorization method, device, equipment, system and storage medium
KR20140072886A (en) Authenticating device users
CN111723362B (en) Authority password generation method, system, device and terminal equipment
CN110619222A (en) Authorization processing method, device, system and medium based on block chain
US8984599B2 (en) Real time password generation apparatus and method
US20200304288A1 (en) Preventing an erroneous transmission of a copy of a record of data to a distributed ledger system
CN111161071A (en) Data processing method, device, equipment and storage medium based on block chain
CN110489994A (en) The file permission management method, apparatus and terminal device of nuclear power station
CN110599140B (en) Digital currency verification method and system
CN107454095A (en) A kind of method and device for preventing machine from logging in
CN103685216A (en) Information processing apparatus, information processing system, information processing method, program and client terminal
CN112258092A (en) Block chain-based data asset reliability assessment method and device
CN110443641B (en) Method and device for managing reading authority and comment information of novel section
CN111210345B (en) Signature method and device based on block chain network transaction and terminal equipment
US20190362345A1 (en) Transaction Processing Method and Apparatus
CN111984268A (en) Application publishing method and application publishing platform
CN109324843A (en) A kind of finger prints processing system, method and fingerprint equipment
CN115225982A (en) Data transmission method and device of distributed energy transaction system
CN110908746A (en) Data processing method, system, readable storage medium and terminal equipment

Legal Events

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