CN114662161A - Electronic lock control method, system and request terminal based on block chain network - Google Patents

Electronic lock control method, system and request terminal based on block chain network Download PDF

Info

Publication number
CN114662161A
CN114662161A CN202210346370.5A CN202210346370A CN114662161A CN 114662161 A CN114662161 A CN 114662161A CN 202210346370 A CN202210346370 A CN 202210346370A CN 114662161 A CN114662161 A CN 114662161A
Authority
CN
China
Prior art keywords
blockchain network
unlocking
request
electronic lock
block chain
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202210346370.5A
Other languages
Chinese (zh)
Inventor
刘洋
许刚
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Shanghai Molian Information Technology Co ltd
Original Assignee
Shanghai Molian Information Technology Co ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Shanghai Molian Information Technology Co ltd filed Critical Shanghai Molian Information Technology Co ltd
Priority to CN202210346370.5A priority Critical patent/CN114662161A/en
Publication of CN114662161A publication Critical patent/CN114662161A/en
Pending legal-status Critical Current

Links

Images

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/70Protecting specific internal or peripheral components, in which the protection of a component leads to protection of the entire computer
    • G06F21/71Protecting specific internal or peripheral components, in which the protection of a component leads to protection of the entire computer to assure secure computing or processing of information
    • G06F21/72Protecting specific internal or peripheral components, in which the protection of a component leads to protection of the entire computer to assure secure computing or processing of information in cryptographic circuits
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/27Replication, distribution or synchronisation of data between databases or within a distributed database system; Distributed database system architectures therefor
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F21/00Security arrangements for protecting computers, components thereof, programs or data against unauthorised activity
    • G06F21/60Protecting data
    • G06F21/602Providing cryptographic facilities or services

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • Computer Hardware Design (AREA)
  • General Physics & Mathematics (AREA)
  • Computer Security & Cryptography (AREA)
  • Software Systems (AREA)
  • Databases & Information Systems (AREA)
  • General Health & Medical Sciences (AREA)
  • Health & Medical Sciences (AREA)
  • Bioethics (AREA)
  • Computing Systems (AREA)
  • Data Mining & Analysis (AREA)
  • Mathematical Physics (AREA)
  • Lock And Its Accessories (AREA)

Abstract

The invention provides an electronic lock control method, an electronic lock control system, a request terminal and a computer storage medium based on a block chain network. The method comprises the following steps: receiving an unlocking request of a request terminal at a first blockchain network, wherein the unlocking request comprises a user identifier associated with the request terminal; receiving an unlocking request sending event of the request terminal at a second blockchain network, wherein the unlocking request sending event indicates that the request terminal sends the unlocking request to the first blockchain network; responding to the unlocking request in the first blockchain network, comparing the user identification with a pre-registered user identification, and if the comparison is successful, sending an unlocking instruction of the electronic lock; and reporting an unlocking execution result from the first block chain network to the second block chain network through a cross-chain bridge. The unlocking authority is managed and the unlocking request is processed through the first block chain network, and the unlocking authority is reported to the second block chain network for supervision, so that the unlocking authority reliability is met, and meanwhile, the requirement of the unlocking request response time is met.

Description

Electronic lock control method, system and request terminal based on block chain network
Technical Field
The present invention relates to the field of internet technologies, and in particular, to a method and a system for controlling an electronic lock based on a blockchain network, a request end, and a computer storage medium.
Background
Electronic locks have replaced traditional mechanical locks in many applications due to their ease of use. With the introduction of computers and communication technologies, electronic locks are becoming intelligent, for example, allowing unlocking using digital passwords, smart cards (IC cards, RFID cards, etc.), biometrics (e.g., fingerprints), and the like. Since an electronic lock typically allows multiple users to unlock at the same time or different users to unlock at different times, assigning unlocking privileges among multiple users, especially users of different interests, becomes a problem to be solved.
Taking a door lock as an example, in a rented house type scene, different unlocking persons such as a landlord, an operator and a tenant often have disputes about who has unlocking authority. At present, some house renting operators introduce a cloud management system to carry out unified management on users of the door locks and the door locks. However, the management system has the obvious characteristic of centralization, if the management system is not just, the distributed unlocking authority cannot be convinced by users of all interests, the reliability of the system is low, and the dispute of the unlocking authority cannot be solved.
Disclosure of Invention
The invention aims to provide an electronic lock control method, a system, a request terminal and a computer storage medium based on a block chain network, so as to solve the problem of low reliability of unlocking authority of a centralized management system.
In order to solve the technical problem, the invention provides an electronic lock control method based on a block chain network, which comprises the following steps: receiving an unlocking request of a request terminal at a first blockchain network, wherein the unlocking request comprises a user identifier associated with the request terminal; receiving an unlocking request sending event of the request terminal at a second blockchain network, wherein the unlocking request sending event indicates that the request terminal sends the unlocking request to the first blockchain network; responding to the unlocking request at the first blockchain network, comparing the user identification with a pre-registered user identification, and if the comparison is successful, sending an unlocking instruction of the electronic lock; and reporting an unlocking execution result from the first block chain network to the second block chain network through a cross-chain bridge.
In an embodiment of the present application, the method further includes: receiving a lock status message of the requesting party and/or the electronic lock at the second blockchain network; and comparing whether the unlocking execution result is consistent with the lock state message in the second block chain network, and storing the comparison result.
In an embodiment of the present application, the step of sending an unlocking instruction of the electronic lock includes: sending the unlocking instruction from the first blockchain network to the request terminal; and sending the unlocking instruction to the electronic lock from the request end.
In an embodiment of the present application, the method further includes: and receiving the lock state information of the request terminal and/or the electronic lock in the first blockchain network, and storing the lock state information.
In an embodiment of the application, the method further includes sending an alarm when the second blockchain network finds that the unlocking execution result is inconsistent with the lock status message.
In an embodiment of the present application, the method further includes: receiving a user registration request at the first blockchain network, the user registration request including a user identification; and responding to the user registration request in the first blockchain network, executing user role and authority management to set user roles and authorities and maintaining registered user identifications.
In an embodiment of the present application, the method further includes maintaining the registered subscriber identity in the second blockchain network.
In an embodiment of the present application, the response time of the first blockchain network is less than the response time of the second blockchain network, and the confidence level of the second blockchain network is higher than the confidence level of the first blockchain network.
In an embodiment of the present application, the requesting end is a portable terminal; and/or the electronic lock is a smart door lock.
Another aspect of the present application provides an electronic lock control method based on a block chain network, including: responding to an unlocking operation of a user, and generating an unlocking request, wherein the unlocking request comprises a user identifier associated with the request terminal; sending the unlocking request to a first block chain network, wherein the unlocking request is used for triggering the first block chain network to compare the user identification with a pre-registered user identification, sending an unlocking instruction of the electronic lock after the comparison is successful, and reporting an unlocking execution result to a second block chain network through a cross-chain bridge; and sending an unlocking request sending event to the second block chain network, wherein the unlocking request sending event indicates that the request terminal sends the unlocking request to the first block chain network.
In an embodiment of the application, the method further includes receiving an unlocking instruction of the first blockchain network, and sending the unlocking instruction to the electronic lock.
In an embodiment of the present application, the method further includes: receiving a lock status message of the electronic lock; and sending a lock state message of the electronic lock to the first blockchain network and the second blockchain network, wherein the lock state message is used for triggering the first blockchain network to store the lock state message, and is used for triggering the second blockchain network to compare the unlocking execution result with the lock state message and store the comparison result.
Another aspect of the present application provides a blockchain network system, which includes a first blockchain network and a second blockchain network. The first blockchain network is configured to: receiving an unlocking request of a request terminal, wherein the unlocking request comprises a user identifier associated with the request terminal; responding to the unlocking request, comparing the user identification with a pre-registered user identification, and if the comparison is successful, sending an unlocking instruction of the electronic lock; reporting an unlocking execution result to a second block chain network through the cross-chain bridge; the second blockchain network configured to: receiving an unlocking request sending event of the request end, wherein the unlocking request sending event indicates that the request end sends the unlocking request to the first block chain network; and receiving the unlocking execution result.
In an embodiment of the application, the second blockchain network is further configured to: receiving a lock state message of the request terminal and/or the electronic lock; and comparing whether the unlocking execution result is consistent with the lock state information or not, and storing the comparison result.
In an embodiment of the application, the second blockchain network is further configured to issue an alarm when the unlocking execution result is found to be inconsistent with the lock status message.
In an embodiment of the application, the first blockchain network is further configured to receive a lock status message of the requesting terminal and/or the electronic lock, and store the lock status message.
In an embodiment of the present application, the first blockchain network is further configured to: receiving a user registration request, wherein the user registration request comprises a user identifier; and responding to the user registration request, executing user role and authority management to set the user role and authority, and maintaining the registered user identification.
In an embodiment of the application, the second blockchain network is further configured to maintain a registered subscriber identity.
In an embodiment of the application, the response time of the first blockchain network is shorter than the response time of the second blockchain network, and the confidence level of the second blockchain network is higher than the confidence level of the first blockchain network.
In order to solve the above technical problem, the present application provides a request end for controlling an electronic lock, including: a memory for storing instructions executable by the processor; and a processor for executing the instructions to implement the above-mentioned method for controlling an electronic lock based on a blockchain network.
To solve the above technical problem, the present application provides a computer storage medium storing computer program code, which when executed by a processor implements the method for controlling an electronic lock based on a blockchain network as described above.
Compared with the prior art, the unlocking authority is managed and the unlocking request is processed through the first block chain network, and the unlocking authority is reported to the second block chain network for supervision. Compared with a centralized management system, the decentralized block chain network improves the reliability of unlocking authority, and meanwhile, the reliability is further improved through the matching of the double block chains.
Drawings
The accompanying drawings, which are included to provide a further understanding of the application and are incorporated in and constitute a part of this application, illustrate embodiment(s) of the application and together with the description serve to explain the principle of the invention. In the drawings:
fig. 1 is a schematic structural diagram of an electronic lock control system based on a block chain network according to an exemplary embodiment of the present application;
FIG. 2 is a schematic illustration of an unlocking process according to an exemplary embodiment of the present application;
FIG. 3 is a schematic diagram of a lock state saving process according to another exemplary embodiment of the present application;
FIG. 4 is a schematic flow chart illustrating user registration in an exemplary embodiment of the present application;
FIG. 5 is a schematic unlocking flow diagram of an electronic lock control method based on a block chain network according to an exemplary embodiment of the present application;
FIG. 6 is a schematic diagram illustrating lock status messaging and a more fluid control of an electronic lock control method based on a blockchain network according to an exemplary embodiment of the present application;
FIG. 7 is a schematic flow chart of an electronic lock control method based on a blockchain network according to another exemplary embodiment of the present application;
fig. 8 is a schematic structural diagram of a request end for electronic lock control according to an exemplary embodiment of the present application.
Detailed Description
In order to more clearly illustrate the technical solutions of the embodiments of the present application, the drawings used in the description of the embodiments will be briefly introduced below. It is obvious that the drawings in the following description are only examples or embodiments of the application, from which the application can also be applied to other similar scenarios without inventive effort for a person skilled in the art. Unless otherwise apparent from the context, or otherwise indicated, like reference numbers in the figures refer to the same structure or operation.
As used in this application and the appended claims, the terms "a," "an," "the," and/or "the" are not intended to be inclusive in the singular, but rather are intended to be inclusive in the plural unless the context clearly dictates otherwise. In general, the terms "comprises" and "comprising" merely indicate that steps and elements are included which are explicitly identified, that the steps and elements do not form an exclusive list, and that a method or apparatus may include other steps or elements.
The relative arrangement of the components and steps, the numerical expressions, and numerical values set forth in these embodiments do not limit the scope of the present application unless specifically stated otherwise. Meanwhile, it should be understood that the sizes of the respective portions shown in the drawings are not drawn in an actual proportional relationship for the convenience of description. Techniques, methods, and apparatus known to those of ordinary skill in the relevant art may not be discussed in detail but are intended to be part of the specification where appropriate. In all examples shown and discussed herein, any particular value should be construed as exemplary only and not as limiting. Thus, other examples of the exemplary embodiments may have different values. It should be noted that: like reference numbers and letters refer to like items in the following figures, and thus, once an item is defined in one figure, further discussion thereof is not required in subsequent figures.
It should be noted that the terms "first", "second", and the like are used to define the components, and are only used for convenience of distinguishing the corresponding components, and the terms have no special meanings unless otherwise stated, and therefore, the scope of protection of the present application is not to be construed as being limited. Further, although the terms used in the present application are selected from publicly known and used terms, some of the terms mentioned in the specification of the present application may be selected by the applicant at his or her discretion, the detailed meanings of which are described in relevant parts of the description herein. Further, it is required that the present application is understood not only by the actual terms used but also by the meaning of each term lying within.
Also, this application uses specific language to describe embodiments of the application. Reference throughout this specification to "one embodiment," "an embodiment," and/or "some embodiments" means that a particular feature, structure, or characteristic described in connection with at least one embodiment of the present application is included in at least one embodiment of the present application. Therefore, it is emphasized and should be appreciated that two or more references to "an embodiment" or "one embodiment" or "an alternative embodiment" in various places throughout this specification are not necessarily all referring to the same embodiment. Furthermore, some features, structures, or characteristics of one or more embodiments of the present application may be combined as appropriate.
It will be understood that when an element is referred to as being "on," "connected to," "coupled to" or "contacting" another element, it can be directly on, connected or coupled to, or contacting the other element or intervening elements may be present. In contrast, when an element is referred to as being "directly on," "directly connected to," "directly coupled to" or "directly contacting" another element, there are no intervening elements present. Similarly, when a first component is said to be "in electrical contact with" or "electrically coupled to" a second component, there is an electrical path between the first component and the second component that allows current to flow. The electrical path may include capacitors, coupled inductors, and/or other components that allow current to flow even without direct contact between the conductive components.
Flowcharts are used herein to illustrate the operations performed by systems according to embodiments of the present application. It should be understood that the preceding or following operations are not necessarily performed in the exact order in which they are performed. Rather, various steps may be processed in reverse order or simultaneously. Meanwhile, other operations are added to or removed from these processes.
Fig. 1 is a schematic structural diagram of an electronic lock control system based on a block chain network according to an embodiment of the present application. As shown in fig. 1, the electronic lock control system 10 includes an electronic lock 11, a request end 12, and a blockchain network system 13, and the blockchain network system 13 includes a first blockchain network 131, a second blockchain network 132, and a cross-chain bridge 133.
In the context of the present application, the electronic lock 11 may be a lock that is separate or attached to various carriers and may be manipulated by electronic control. In various embodiments, the electronic lock 11 may be opened by means of a password (e.g., characters), biometric features (e.g., fingerprints, faces, sounds), and the like. In the present embodiment, the electronic lock 11 may be an intelligent door lock. The electronic lock 11 itself does not include an unlocking verification function, and the request terminal 12 receives an unlocking operation including a password or a biometric characteristic and the like, and then transmits the password or the biometric characteristic and the like as a part of the user identification to the blockchain network system 13 for verification through the network. The following description will be given taking a password as an example.
In the present embodiment, the requesting end 12 may be a portable terminal, such as a smart phone, a smart bracelet, a smart watch, smart glasses, and the like. The request end 12 and the electronic lock can interact through wireless communication modes such as Bluetooth, radio frequency, zigbee and the like. The request end 12 is configured to trigger acquisition of a password of the user in response to an unlocking operation of the user. The requester 12 then generates an unlock request that includes a user identification associated with the requester, which may include a password for the user. The requesting end 12 then sends an unlock request to the first blockchain network 131 and reports an unlock request send event to the second blockchain network 132. The unlocking request sending event indicates that the request terminal 12 sends an unlocking request to the first blockchain network 131.
In another embodiment, the request 12 may be a module integrated in the electronic lock 11. The request end 12 and the electronic lock 11 may be connected by wire. The requesting end 12 may include input components (e.g., a keyboard, touch sensor, sound sensor, camera, etc.), a processor, and a communication module (e.g., a wireless communication module or a cellular communication module), among other modules, as necessary to perform the aforementioned functions.
Fig. 2 is a schematic illustration of an unlocking process according to an exemplary embodiment of the present application. As shown in fig. 2, in step S21, the request end 12 receives an unlocking operation of the user 200, for example, collects information (e.g., password) of the user as a user identifier. The request terminal 12 generates an unlocking request based on the unlocking operation and includes the user identification. In one embodiment, in order to protect sensitive information such as the password of the user, the request end 12 encrypts the collected password of the user, for example, calculates a Hash value of the password, and then includes the Hash value of the password and the user ID as the user identifier in the unlocking request. In step S22, the request end 12 sends an unlocking request including the user identifier to the first blockchain network 131 to trigger the first blockchain network 131 to perform unlocking and authentication operations, which will be described later. In step S23, the request end 12 reports an unlocking request sending event including the user identifier to the second blockchain network 132. The present application does not limit the encryption method of the password. In this embodiment, the Hash values of the messages are uploaded to the first blockchain network and the second blockchain network, and the original messages only exist in the request end. The privacy of the sensitive information is maintained while making full use of the sensitive information.
A blockchain network is a collection of a series of centerless nodes that incorporate new blocks into the blockchain in a consensus manner. As shown in fig. 2, a first blockchain network 131 may be configured in the service platform, and a second blockchain network 132 and a cross-chain bridge 133 may be configured in the supervisory platform. The first blockchain network 131 may be used to execute unlock-related contracts and the second blockchain network 132 may be used to execute verification-related contracts. The cross-link bridge 133 mediates the transfer of information from the first blockchain network 131 to the second blockchain network 132.
Due to the difference in function, the first blockchain network 131 and the second blockchain network 132 are set to networks of two different attributes. In this embodiment, the response time of the first blockchain network 131 is faster than that of the second blockchain network 132, and is the time required for the blockchain network to complete a request from the receipt of the request. For example, the response time of the first blockchain network 131 is in the order of seconds. The response time of the second blockchain network 132 is on the order of minutes, typically tens of minutes. In addition, the second blockchain network 132 has a higher degree of trust than the first blockchain network 131.
Further, as shown in fig. 2, the first blockchain network 131 is configured to receive an unlocking request of the request terminal 12; and executing unlocking intelligent contract C1 in response to the unlocking request to compare the user identification with the pre-registered user identification, and issuing an unlocking instruction to the request end 12 if the comparison is successful.
In the field of block chains, a Smart Contract (Smart Contract) is a computer protocol aiming at propagating, verifying or executing a Contract in an informatization mode, a developer formulates a set of rules through the Smart Contract, and then the rules are deployed on a line, a person interacts with the Smart Contract, and a machine completes part of a service, so that cheating behaviors possibly caused when the person executes the service are avoided. In this embodiment, some rules, such as unlocking verification, lock state message saving, lock user role and authority management of the first blockchain network 131, record unlocking request sending event of the second blockchain network 132, record lock state message, compare lock state message and unlocking verification message, etc., may be formulated in advance through an intelligent contract. The relevant contracts are then deployed onto the first blockchain network 131 and the second blockchain network 132, respectively. Specifically, the first blockchain network 131 compares the Hash value and the user ID of the received password with the Hash value and the user ID of the password registered by the user in advance by performing unlocking verification at step S24, and if the comparison is consistent, performs step S25 to issue an unlocking instruction to the requesting terminal 12, and at the same time, may perform step S26 to send the unlocking execution result to the second blockchain network 132. The sequence of step S25 and step S26 is not limited in the present application, and both may be executed simultaneously or sequentially, and the sequence of execution is not limited in the present application.
As shown in fig. 2, the request end 12 is further configured to receive an unlocking instruction issued by the first blockchain network 131 after the first blockchain network 131 is successfully verified, and then execute step S27 to forward the unlocking instruction to the electronic lock 11.
The second blockchain network 132 is configured to receive an unlocking request transmission event of the request terminal 12; receiving an unlocking execution result; and recording the unlocking request sending event. Specifically, the second blockchain network 132 records the unlocking request transmission event for subsequent evidence preservation supervision at step S28. The second blockchain network 132 may store and maintain the registered subscriber identity using the received unlock request to send events and/or other information.
The embodiment gives consideration to the reliability and the response time of decentralization through the double block chain network. The unlocking request is received through the first block chain network 131 with short response time to verify whether the unlocking request is successful, and if the verification is successful, an unlocking instruction is sent to the request terminal 12, so that the real-time requirements of control types such as unlocking and the like are well met. The second blockchain network 132 with high trust level is used for storing and certifying and monitoring the first blockchain network 131, and an alarm is given when the first blockchain network 131 is not trusted, so that the trust level of the whole blockchain system is ensured.
Fig. 3 is a schematic diagram of a lock state saving process according to an exemplary embodiment of the present application. As shown in fig. 3, the first blockchain network 131 is further configured to receive a lock status message of the requesting terminal 12 and/or the electronic lock 11. Specifically, when the electronic lock 11 has an IP network function and the electronic lock 11 can directly interact with the first blockchain network 131 in a communication manner, the electronic lock 11 is configured to encapsulate the lock status into a lock status message, and then execute step S31a to send the lock status message to the first blockchain network 131 and the second blockchain network 132, and correspondingly, the first blockchain network 131 is configured to receive the lock status message of the electronic lock 11. When the electronic lock 11 does not have the IP network function and cannot directly interact with the first blockchain network 131, the electronic lock 11 performs step S31b to report the lock status information to the requesting end 12, the requesting end 12 is further configured to receive the lock status information of the electronic lock 11, and then performs step S32 to send the lock status message to the first blockchain network 131 and the second blockchain network 132, and the first blockchain network 131 is configured to receive the lock status message of the requesting end 12. First blockchain network 131 then saves the lock status message in response to the lock status message at step S33.
The second blockchain network 132 is further configured to receive a lock status message of the requesting end 12 and/or the electronic lock 11. Similarly, the detailed description may refer to the configuration of the first blockchain network 131 according to whether the electronic lock 11 has the IP network function, and will not be described herein again. The second blockchain network 132 then performs lock status verification in step S35 in response to the lock status information of the requesting end 12 and/or the lock status information of the electronic lock 11. Specifically, the process of verifying the lock status may be comparing the received lock status information with the unlocking execution result stored on the second blockchain network 132, and if the received lock status information is consistent, the result indicates compliance, otherwise, the result indicates non-compliance. Generally speaking, the lock status message sent by the electronic lock is real, so if the unlocking execution result is inconsistent with the lock status message, it means that the first blockchain network 131 does not report the real unlocking execution result, and the reliability of the unlocking execution result is questionable, and the second blockchain network 132 thus records the comparison result for the supervision of the supervision platform where the second blockchain network is located on the service platform.
In some embodiments, the second blockchain network is further configured to issue an alarm when the unlocking execution result received from the first blockchain network 131 is found to be inconsistent with the lock status message received from the requesting terminal 12 and/or the electronic lock 11. The warning mode may be sending a warning instruction to the request end 12 and/or the electronic lock 11, the request end 12 and/or the electronic lock 11 receiving the warning instruction, and prompting the stakeholder in a vibration or sound mode, or displaying warning information through a display screen of the request end 12 and/or the electronic lock 11 to prompt the stakeholder, and the prompting mode is not limited in the present application. According to the method and the device, through the comparison and the verification of the electronic lock, the request end and the information ring of the first block chain network and the second block chain network, a certain part can be attacked and abnormal, and an alarm can be sent out in time. The safety factor of the system is improved, meanwhile, maintenance personnel can conveniently and quickly locate the abnormal position, and the maintenance difficulty is reduced.
Fig. 4 is a flowchart illustrating user registration according to an exemplary embodiment of the present application. As shown in fig. 4, the request end 12 is configured to trigger execution of step S41 to collect user information (e.g., password) in response to the registration operation of the user 200. A registration request is then generated and sent at step S42, the registration request including the user identification associated with the requesting end 12. In this embodiment, the user identification includes a user password Hash value and a user ID. The first blockchain network 131 is further configured to receive a registration request including the user identification, and in response to the registration request, the first blockchain network 131 performs lock user role and authority management, sets the user role and authority, and maintains the registered user identification at step S43. Specifically, the lock user role and authority management may be the following rules:
1) the roles of the lock users are as follows: landlord, operator (landlord) and tenant.
2) The landlord has the right to collect rent and the right to grant the role of an operator or a tenant, and once the landlord grants the role of other users, the right to unlock the landlord is recovered;
3) the operator has the right of collecting operation fee, house maintenance guarantee, lease invitation and charge, and the right of granting the role of tenant, once the operator grants the role of tenant to other users, the unlocking right is recovered;
4) the user is granted the tenant role and has independent lock opening and closing rights.
The multi-party cooperative control is introduced to the control of the door lock through the lock user role and the authority management contract, the real appeal of each right and interest party of the rental room type intelligent door lock is fully met, the transaction between each party and the lock can not be falsified, and meanwhile, the unlocking right of only one party is ensured at any time, so that the interest of each party is powerfully guaranteed. Moreover, the cooperation relationship of all parties of the intelligent door lock is bound by the intelligent contract, and the cooperation surrounding the lock is also driven by the intelligent contract to be executed; this also allows parties to complete contracts that can be signed at different locations and executed, greatly facilitating the labor costs of intelligent door lock management.
After the first blockchain network 131 performs lock user role and authority management, a user role and authority are set for each user. The user identification can be associated with the user role and the rights by the user ID. This allows for the user identity and user role and privileges to be certified on the first blockchain network 131. The format of the complete user registration information can be user ID, password Hash value, role and authority. The password Hash value is uploaded to the first blockchain network 131, and the original password exists only in the individual request terminal. The privacy of the sensitive information is maintained while the sensitive information is fully utilized. And the Hash value of the password of the electronic lock user is stored in the uplink, so that the electronic lock can be used for infinite times after being registered once, and the electronic lock does not need to be registered again if a tenant changes a house, thereby improving the experience satisfaction degree of the user.
The present application further provides an electronic lock control method based on a block chain network, which will be described below with reference to the accompanying drawings.
Fig. 5 is a flowchart illustrating a method 50 for controlling an electronic lock based on a blockchain network according to an exemplary embodiment of the present application, where the method may be performed by the above-mentioned blockchain network system 13, and as shown in fig. 5, the method 50 includes:
step S501: an unlocking request of a request terminal is received in the first block chain network, and the unlocking request comprises a user identification associated with the request terminal.
Step S501: and receiving an unlocking request sending event of the request end at the second block chain network, wherein the unlocking request sending event indicates that the request end sends an unlocking request to the first block chain network.
Step S503: and executing an unlocking intelligent contract in response to the unlocking request in the first blockchain network so as to compare the user identification with the pre-registered user identification, and if the comparison is successful, sending an unlocking instruction of the electronic lock.
Step S504: and reporting the unlocking execution result from the first block chain network to the second block chain network through the cross-chain bridge.
In step S502, if the comparison is successful, an unlocking instruction of the electronic lock is transmitted. In some embodiments, the step of sending an unlocking instruction of the electronic lock comprises sending the unlocking instruction from the first blockchain network to the requesting terminal; and sending an unlocking instruction to the electronic lock from the request terminal through wireless communication. The wireless communication may be bluetooth, radio frequency, zigbee, etc., and the application is not limited thereto.
In some embodiments, the method for controlling an electronic lock based on a blockchain network further comprises issuing an alarm when the second blockchain network finds that the lock state information received from the first blockchain network is inconsistent with the lock state information received from the requesting terminal and/or the electronic lock. According to the method and the device, the information ring-to-ring comparison and the verification of the electronic lock, the request end, the first block chain network and the second block chain network are carried out, so that an alarm can be timely sent out when a certain part is attacked and abnormal, and the safety coefficient of the system is improved.
In some embodiments, the method for electronic lock control based on a blockchain network further comprises receiving a user registration request at the first blockchain network, the user registration request including a user identification; and responding to the user registration request in the first blockchain network to execute user role locking and authority management so as to set user roles and authorities and maintain registered user identifications.
In this embodiment, the blockchain network system can take into account both the reliability and response time of decentralization based on a dual blockchain network. Whether the unlocking request is successful or not is verified through the first block chain network with short response time, and if the unlocking request is successful, an unlocking instruction is sent to a request end, so that the real-time requirements of control types such as unlocking and the like are well met; and the first block chain is monitored by storing and verifying the second block chain network with high trust degree, and an alarm is given when the first block chain network is not trusted, so that the trust degree of the whole block chain system is ensured.
Fig. 6 is a flowchart illustrating an electronic lock control method 60 based on a blockchain network according to an exemplary embodiment of the present application, where the method may be executed by the above-mentioned blockchain network system 13, and as shown in fig. 6, the method 60 includes:
step S601: receiving a lock state message of a request end and/or an electronic lock in a first block chain network, and storing the lock state message;
step S602: receiving lock state information of the request terminal and/or the electronic lock at the second blockchain network;
step S603: and comparing whether the unlocking execution result is consistent with the locking state message or not in the second block chain network, and storing the comparison result.
In some embodiments, an alarm is raised when the second blockchain network finds that the unlock execution result and the lock status message are inconsistent.
Fig. 7 is a flowchart of an electronic lock control method 70 based on a block chain network according to another exemplary embodiment of the present application, where the method may be executed by the requesting terminal 12, and as shown in fig. 7, the method 70 includes:
step S701: responding to the unlocking operation of a user, and generating an unlocking request, wherein the unlocking request comprises a user identifier associated with a request terminal;
step S702: and sending an unlocking request to the first block chain network, wherein the unlocking request is used for triggering the first block chain network to compare the user identification with the pre-registered user identification, sending an unlocking instruction of the electronic lock after the comparison is successful, and reporting an unlocking execution result to the second block chain network through the cross-chain bridge.
In step S703: and sending an unlocking request sending event to the second blockchain network, wherein the unlocking request sending event indicates that the request terminal sends the unlocking request to the first blockchain network. The unlocking request sending event triggers the second block chain network to verify whether the unlocking execution result is in compliance.
In some embodiments, the method for controlling an electronic lock based on a blockchain network further includes receiving an unlocking instruction of the first blockchain network and sending the unlocking instruction to the electronic lock.
In some embodiments, the method of electronic lock control based on a blockchain network further comprises receiving a lock status message of the electronic lock; and sending a lock state message of the electronic lock to the first block chain network and the second block chain network, wherein the lock state message is used for triggering the first block chain network to store the lock state message, sending the lock state message to the second block chain network, triggering the second block chain network to compare the unlocking execution result with the lock state information, and storing the comparison result.
In the embodiment, the user identification is acquired through the request terminal, so that the cost of an electronic lock acquisition sensor is saved; meanwhile, the collected user identification is encrypted, the encrypted user identification is uploaded to the first block chain network and the second block chain network for storage, and the original sensitive information only exists in the individual request terminal. The privacy of the sensitive information is maintained while making full use of the sensitive information. And the encrypted user identification of the electronic lock user is stored in the uplink, so that the electronic lock user can be registered once and used for infinite times, and the experience satisfaction of the user is improved.
The application also provides a request terminal for controlling the electronic lock, which comprises a memory and a processor. Wherein the memory is to store instructions executable by the processor; the processor is configured to execute the instructions to implement the above-mentioned method for controlling an electronic lock based on a blockchain network.
Fig. 8 is a schematic structural diagram of a request terminal for electronic lock control according to an exemplary embodiment of the present application, where the request terminal is adapted to an electronic lock control system based on a block chain network provided in the foregoing embodiment. As shown in fig. 8, the requesting end 800 may include an internal communication bus 801, a processor 802, a Read Only Memory (ROM)803, a Random Access Memory (RAM)804, and a communication port 805. The internal communication bus 801 may enable data communication among the components of the operating device 800. The processor 802 may make the determination and issue the prompt. In some embodiments, processor 802 may be comprised of one or more processors. The communication port 805 can enable data communication between the operation device 800 and the outside. In some embodiments, the operating device 800 may send and receive information and data from a network through the communication port 805. The operating device 800 may also include various forms of program storage and data storage such as a Read Only Memory (ROM)803 and a Random Access Memory (RAM)804, capable of storing various data files used in computer processing and/or communications, and possibly program instructions for execution by the processor 802. The processor executes these instructions to implement the main parts of the method. The result processed by the processor is transmitted to the user equipment through the communication port and displayed on the user interface.
The above-mentioned electronic lock control method based on the blockchain network may be implemented as a computer program, stored in a Read Only Memory (ROM)803, and loaded into the processor 802 for execution, so as to implement the electronic lock control method based on the blockchain network of the present application.
The present application also provides a computer readable medium storing computer program code, which when executed by a processor implements the above-described method for controlling an electronic lock based on a blockchain network.
When the electronic lock control method based on the blockchain network is implemented as a computer program, the computer program may also be stored in a computer-readable storage medium as an article of manufacture. For example, computer-readable storage media can include but are not limited to magnetic storage devices (e.g., hard disk, floppy disk, magnetic strips), optical disks (e.g., Compact Disk (CD), Digital Versatile Disk (DVD)), smart cards, and flash memory devices (e.g., electrically Erasable Programmable Read Only Memory (EPROM), card, stick, key drive). In addition, various storage media described herein can represent one or more devices and/or other machine-readable media for storing information. The term "machine-readable medium" can include, without being limited to, wireless channels and various other media (and/or storage media) capable of storing, containing, and/or carrying code and/or instructions and/or data.
It should be understood that the above-described embodiments are illustrative only. The embodiments described herein may be implemented in hardware, software, firmware, middleware, microcode, or any combination thereof. For a hardware implementation, the processor may be implemented within one or more Application Specific Integrated Circuits (ASICs), Digital Signal Processors (DSPs), Digital Signal Processing Devices (DSPDs), Programmable Logic Devices (PLDs), Field Programmable Gate Arrays (FPGAs), processors, controllers, micro-controllers, microprocessors, and/or other electronic units designed to perform the functions described herein, or a combination thereof.
Aspects of the present application may be embodied entirely in hardware, entirely in software (including firmware, resident software, micro-code, etc.) or in a combination of hardware and software. The above hardware or software may be referred to as "data block," module, "" engine, "" unit, "" component, "or" system. The processor may be one or more Application Specific Integrated Circuits (ASICs), Digital Signal Processors (DSPs), digital signal processing devices (DAPDs), Programmable Logic Devices (PLDs), Field Programmable Gate Arrays (FPGAs), processors, controllers, microcontrollers, microprocessors, or a combination thereof. Furthermore, aspects of the present application may be represented as a computer product, including computer readable program code, embodied in one or more computer readable media. For example, computer-readable media can include but are not limited to magnetic storage devices (e.g., hard disk, floppy disk, magnetic strips … …), optical disks (e.g., Compact Disk (CD), Digital Versatile Disk (DVD) … …), smart cards, and flash memory devices (e.g., card, stick, key drive … …).
The computer readable medium may comprise a propagated data signal with the computer program code embodied therein, for example, on a baseband or as part of a carrier wave. The propagated signal may take any of a variety of forms, including electromagnetic, optical, and the like, or any suitable combination. The computer readable medium can be any computer readable medium that can communicate, propagate, or transport the program for use by or in connection with an instruction execution system, apparatus, or device. Program code on a computer readable medium may be propagated over any suitable medium, including radio, electrical cable, fiber optic cable, radio frequency signals, or the like, or any combination of the preceding.
Having thus described the basic concept, it will be apparent to those skilled in the art that the foregoing disclosure is by way of example only, and is not intended to limit the present application. Various modifications, improvements and adaptations to the present application may occur to those skilled in the art, although not explicitly described herein. Such modifications, improvements and adaptations are proposed in the present application and thus fall within the spirit and scope of the exemplary embodiments of the present application.

Claims (21)

1. An electronic lock control method based on a block chain network comprises the following steps:
receiving an unlocking request of a request terminal at a first blockchain network, wherein the unlocking request comprises a user identifier associated with the request terminal;
receiving an unlocking request sending event of the request terminal at a second blockchain network, wherein the unlocking request sending event indicates that the request terminal sends the unlocking request to the first blockchain network;
responding to the unlocking request at the first blockchain network, comparing the user identification with a pre-registered user identification, and if the comparison is successful, sending an unlocking instruction of the electronic lock; and
and reporting an unlocking execution result from the first block chain network to the second block chain network through a cross-chain bridge.
2. The method of claim 1, further comprising:
receiving a lock status message of the requesting party and/or the electronic lock at the second blockchain network; and
and comparing whether the unlocking execution result is consistent with the lock state message or not in the second block chain network, and storing the comparison result.
3. The method of claim 1, wherein the step of sending an unlock command for the electronic lock comprises:
sending the unlocking instruction from the first blockchain network to the request terminal; and
and sending the unlocking instruction to the electronic lock from the request end.
4. The method of claim 1, further comprising:
and receiving the lock state information of the request terminal and/or the electronic lock in the first blockchain network, and storing the lock state information.
5. The method of claim 4, further comprising issuing an alarm when the second blockchain network finds that the unlock execution result and the lock status message are inconsistent.
6. The method of claim 1, further comprising:
receiving a user registration request at the first blockchain network, the user registration request including a user identification;
and responding to the user registration request in the first blockchain network, executing user role and authority management to set user roles and authorities and maintaining registered user identifications.
7. The method of claim 1, further comprising maintaining a registered subscriber identity at the second blockchain network.
8. The method of claim 1, wherein a response time of the first blockchain network is less than a response time of the second blockchain network, and a degree of trust of the second blockchain network is higher than a degree of trust of the first blockchain network.
9. The method of claim 1, wherein the requesting end is a portable terminal; and/or the electronic lock is a smart door lock.
10. An electronic lock control method based on a block chain network comprises the following steps:
responding to an unlocking operation of a user, and generating an unlocking request, wherein the unlocking request comprises a user identifier associated with the request terminal;
sending the unlocking request to a first block chain network, wherein the unlocking request is used for triggering the first block chain network to compare the user identification with a pre-registered user identification, sending an unlocking instruction of the electronic lock after the comparison is successful, and reporting an unlocking execution result to a second block chain network through a cross-chain bridge; and
and sending an unlocking request sending event to the second blockchain network, wherein the unlocking request sending event indicates that the request terminal sends the unlocking request to the first blockchain network.
11. The method of claim 10, further comprising receiving an unlock instruction for the first blockchain network and sending the unlock instruction to the electronic lock.
12. The method of claim 10, further comprising:
receiving a lock status message of the electronic lock;
and sending a lock state message of the electronic lock to the first block chain network and the second block chain network, wherein the lock state message is used for triggering the first block chain network to store the lock state message, and is used for triggering the second block chain network to compare the unlocking execution result with the lock state message and store the comparison result.
13. A blockchain network system comprising:
a first blockchain network configured to:
receiving an unlocking request of a request terminal, wherein the unlocking request comprises a user identifier associated with the request terminal;
responding to the unlocking request, comparing the user identification with a pre-registered user identification, and if the comparison is successful, sending an unlocking instruction of the electronic lock; and
reporting an unlocking execution result to a second block chain network through a cross-chain bridge;
a second blockchain network configured to:
receiving an unlocking request sending event of the request end, wherein the unlocking request sending event indicates that the request end sends the unlocking request to the first block chain network; and receiving the unlocking execution result.
14. The blockchain network system of claim 13,
the second blockchain network is further configured to: receiving a lock state message of the request terminal and/or the electronic lock; and comparing whether the unlocking execution result is consistent with the lock state information or not, and storing the comparison result.
15. The blockchain network system of claim 14, wherein the second blockchain network is further configured to issue an alarm when the unlock execution result and the lock status message are found to be inconsistent.
16. The blockchain network system of claim 13, wherein the first blockchain network is further configured to receive a lock status message of the requesting party and/or the electronic lock and to save the lock status message.
17. The blockchain network system of claim 13,
the first blockchain network is further configured to: receiving a user registration request, wherein the user registration request comprises a user identifier; and responding to the user registration request, executing user role and authority management to set the user role and authority and maintaining the registered user identification.
18. The blockchain network system of claim 13, wherein the second blockchain network is further configured to maintain a registered subscriber identity.
19. The blockchain network system of claim 13, wherein a response time of the first blockchain network is less than a response time of the second blockchain network, and a degree of trust of the second blockchain network is higher than a degree of trust of the first blockchain network.
20. A requesting end for electronic lock control, comprising:
a memory for storing instructions executable by the processor; and
a processor for executing the instructions to implement the method of any one of claims 10-12.
21. A computer storage medium having computer program code stored thereon, which when executed by a processor implements the method of any one of claims 1-12.
CN202210346370.5A 2022-03-31 2022-03-31 Electronic lock control method, system and request terminal based on block chain network Pending CN114662161A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202210346370.5A CN114662161A (en) 2022-03-31 2022-03-31 Electronic lock control method, system and request terminal based on block chain network

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202210346370.5A CN114662161A (en) 2022-03-31 2022-03-31 Electronic lock control method, system and request terminal based on block chain network

Publications (1)

Publication Number Publication Date
CN114662161A true CN114662161A (en) 2022-06-24

Family

ID=82033273

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202210346370.5A Pending CN114662161A (en) 2022-03-31 2022-03-31 Electronic lock control method, system and request terminal based on block chain network

Country Status (1)

Country Link
CN (1) CN114662161A (en)

Similar Documents

Publication Publication Date Title
AU2017276840B2 (en) Padlock device, systems including a padlock device, and methods of operating therefor
CN109767534B (en) Access control access method, system, management terminal and access control terminal based on block chain
US10169937B1 (en) Systems and methods for multifactor physical authentication
CN109272606B (en) Intelligent lock supervision equipment and method based on block chain and storage medium
KR101296863B1 (en) Entry authentication system using nfc door lock
CN104091376B (en) Intelligent lock control method and apparatus thereof
CN108961475B (en) Access control deployment method and access control deployment server
CN104240342B (en) Access control method and device based on identity authentication
CN106453874B (en) Mobile phone control method and system
KR101814719B1 (en) System and method for remote controlling digital door-lock using smartphone
CN104809773A (en) Entrance guard control method, entrance guard control apparatus, and entrance guard system
CN114579943A (en) Employee digital identity management system and method based on block chain
US10402558B2 (en) Device restrictions during events
CN106548059A (en) The method of teacher, head of a family's mobile terminal and head of a family's authentication
CN110324350A (en) Identity identifying method and server based on the non-sensitive sensing data in mobile terminal
CN109409057A (en) Security system and its control method, control device and storage medium
CN115758398A (en) Access control data processing method and device, access control system and storage medium
CN109347865A (en) A kind of user data authentication based on block chain technology deposits the method and system of card
CN110766850A (en) Visitor information management method, access control system, server and storage medium
CN110266653A (en) A kind of method for authenticating, system and terminal device
CN117151736A (en) Anti-electricity fraud management early warning method and system
CN114662161A (en) Electronic lock control method, system and request terminal based on block chain network
Akbarfam et al. Dlacb: Deep learning based access control using blockchain
CN113765897A (en) Sharing use method and system of electronic equipment
CN111379475B (en) Unlocking method of electronic lock, electronic lock and unlocking management 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