CN109272617A - Unlocking verification method, server, door lock, electronic equipment and storage medium - Google Patents
Unlocking verification method, server, door lock, electronic equipment and storage medium Download PDFInfo
- Publication number
- CN109272617A CN109272617A CN201811015487.5A CN201811015487A CN109272617A CN 109272617 A CN109272617 A CN 109272617A CN 201811015487 A CN201811015487 A CN 201811015487A CN 109272617 A CN109272617 A CN 109272617A
- Authority
- CN
- China
- Prior art keywords
- door lock
- validity period
- code
- activation code
- password
- 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.)
- Granted
Links
Classifications
-
- G—PHYSICS
- G07—CHECKING-DEVICES
- G07C—TIME OR ATTENDANCE REGISTERS; REGISTERING OR INDICATING THE WORKING OF MACHINES; GENERATING RANDOM NUMBERS; VOTING OR LOTTERY APPARATUS; ARRANGEMENTS, SYSTEMS OR APPARATUS FOR CHECKING NOT PROVIDED FOR ELSEWHERE
- G07C9/00—Individual registration on entry or exit
- G07C9/00174—Electronically operated locks; Circuits therefor; Nonmechanical keys therefor, e.g. passive or active electrical keys or other data carriers without mechanical keys
-
- G—PHYSICS
- G07—CHECKING-DEVICES
- G07C—TIME OR ATTENDANCE REGISTERS; REGISTERING OR INDICATING THE WORKING OF MACHINES; GENERATING RANDOM NUMBERS; VOTING OR LOTTERY APPARATUS; ARRANGEMENTS, SYSTEMS OR APPARATUS FOR CHECKING NOT PROVIDED FOR ELSEWHERE
- G07C9/00—Individual registration on entry or exit
- G07C9/00174—Electronically operated locks; Circuits therefor; Nonmechanical keys therefor, e.g. passive or active electrical keys or other data carriers without mechanical keys
- G07C9/00571—Electronically operated locks; Circuits therefor; Nonmechanical keys therefor, e.g. passive or active electrical keys or other data carriers without mechanical keys operated by interacting with a central unit
-
- G—PHYSICS
- G07—CHECKING-DEVICES
- G07C—TIME OR ATTENDANCE REGISTERS; REGISTERING OR INDICATING THE WORKING OF MACHINES; GENERATING RANDOM NUMBERS; VOTING OR LOTTERY APPARATUS; ARRANGEMENTS, SYSTEMS OR APPARATUS FOR CHECKING NOT PROVIDED FOR ELSEWHERE
- G07C2209/00—Indexing scheme relating to groups G07C9/00 - G07C9/38
- G07C2209/08—With time considerations, e.g. temporary activation, valid time window or time limitations
Landscapes
- Physics & Mathematics (AREA)
- General Physics & Mathematics (AREA)
- Lock And Its Accessories (AREA)
Abstract
The present invention provides a kind of unlocking verification method, door lock service device and door locks, which comprises obtains order information, the order information includes order validity period, target door lock;Obtain the corresponding door lock key of the target door lock;Determine whether the network state of the target door lock is in off-line state;In the case where the target door lock is in off-line state, activation code is generated according to the order validity period and the door lock key, and be sent to third party system, the activation code is used to verify and unlock after being verified for target door lock.New order of moving in can be being generated, and when door lock is in offline, notify user to unlock using activation code by third party, it can be to avoid security risk existing for the use of original code after house user change.
Description
Technical field
The present embodiments relate to intelligent door lock technical field more particularly to a kind of unlocking verification methods, server, door
Lock, electronic equipment and storage medium.
Background technique
Intelligent door lock is since its safety is higher, advantage easy to use, it is already possible to gradually replace conventional door lock.Intelligence
The unlocking and management of energy door lock are dependent on the door lock service device positioned at distal end.When intelligent door lock is online, intelligent door lock can with it is remote
End door lock server is communicated, so as to obtain real-time password from distal end door lock service device to unlock;Intelligent door lock is offline
When, intelligent door lock can not be communicated with distal end door lock service device, so that real-time password can not be obtained from distal end door lock service device.
At this point, being unlocked using the spare password for being previously written intelligent door lock.
However, since the validity period of spare password is longer, when leading to intelligent door lock long-term offline, spare password always can be with
It is unlocked.For hotel guest room, if house user changes, there are security risks.
Summary of the invention
The present invention provides a kind of unlocking verification method and device, to solve the above problem in the prior art.
According to the first aspect of the invention, a kind of unlocking verification method is provided, which comprises
Order information is obtained, the order information includes order validity period, target door lock;
Obtain the corresponding door lock key of the target door lock;
Determine whether the network state of the target door lock is in off-line state;
It is raw according to the order validity period and the door lock key in the case where the target door lock is in off-line state
At activation code, and it is sent to third party system, the activation code is used to verify and be verified for target door lock
It unlocks later.
Optionally, described the step of activation code is generated according to the order validity period and the door lock key, comprising:
The first validity period ciphertext is generated according to the order validity period and the door lock key;
The first check code is generated according to the order validity period and the door lock key;
The first validity period ciphertext and first check code are spliced into activation code.
Optionally, described the step of first validity period ciphertext is generated according to the order validity period and the door lock key,
Include:
The difference between the order validity period and preset reference time is calculated, obtained for the first relative efficiency phase;
After the first relative efficiency phase and door lock key splicing, encrypted to obtain the using symmetry algorithm
One validity period ciphertext.
Optionally, described the step of first check code is generated according to the order validity period and the door lock key, comprising:
After the order validity period and door lock key splicing, encrypted to obtain first using digest algorithm close
Code;
The first password is encrypted to obtain the first check code using digest algorithm.
According to the second aspect of the invention, a kind of unlocking verification method is provided, which comprises
Receive the authentication code of user's input;
Judge whether to get the real-time password for specifying validity period, the validity period includes current time;
In the case where the real-time password for specifying validity period has not been obtained, the authentication code of user's input is determined
It whether is activation code;
In the case where the authentication code is activation code, the activation code is verified, and be verified it
After unlock.
Optionally, the described the step of activation code is verified, comprising:
The second check code and third check code are extracted from the activation code;
If second check code is consistent with third check code, the activation code is verified;
If second check code and third check code are inconsistent, the activation code verifying does not pass through.
Optionally, described the step of the second check code and third check code are extracted from the activation code, comprising:
The data for presetting the first segment in the activation code are obtained, the second check code is obtained;
The data for presetting the second segment in the activation code are obtained, the second validity period ciphertext is obtained;
Third check code is generated according to the second validity period ciphertext and preset door lock key.
Optionally, the step that third check code is generated according to the second validity period ciphertext and preset door lock key
Suddenly, comprising:
The second validity period ciphertext according to preset door lock key pair is decrypted using symmetry algorithm, obtains the second phase
To validity period;
It calculates the sum of the second relative efficiency phase and preset reference time and obtains absolute validity period;
After the absolute validity period and door lock key splicing, encrypted to obtain second using digest algorithm close
Code;
Second password is encrypted to obtain third check code using digest algorithm.
Optionally, the method also includes:
In the case where the activation code is verified, second password and absolute validity period are saved.
Optionally, the method also includes:
In the case where the authentication code is password, according to second password and absolute validity period to the password
It is verified, and is unlocked after being verified.
According to the third aspect of the invention we, a kind of door lock service device is provided, the door lock service device includes:
Order information obtains module, and for obtaining order information, the order information includes order validity period, target door
Lock;
Door lock Key Acquisition Module, for obtaining the corresponding door lock key of the target door lock;
Network state determining module, for determining whether the network state of the target door lock is in off-line state;
Activation code generation module, for being had according to the order in the case where the target door lock is in off-line state
Effect phase and the door lock key generate activation code, and are sent to third party system, and the activation code is used to supply the target door lock
Verify and unlock after being verified.
According to the fourth aspect of the invention, a kind of intelligent door lock is provided, the door lock includes:
Authentication code receiving module, for receiving the authentication code of user's input;
Real-time password judgment module, gets the real-time password for specifying validity period for judging whether;
Activation code determining module, for determining user in the case where the real-time password for specifying validity period has not been obtained
Whether the authentication code of input is activation code;
Unlocking module is verified, for testing the activation code in the case where the authentication code is activation code
Card, and unlock after being verified.
According to the fifth aspect of the invention, a kind of electronic equipment is provided, comprising:
Processor, memory and it is stored in the computer journey that can be run on the memory and on the processor
Sequence, the processor realize method above-mentioned when executing described program.
According to the sixth aspect of the invention, provide a kind of readable storage medium storing program for executing, when the instruction in the storage medium by
When the processor of electronic equipment executes, so that electronic equipment is able to carry out method above-mentioned.
The embodiment of the invention provides a kind of unlocking verification method, door lock service device and intelligent door locks, which comprises
Order information is obtained, the order information includes order validity period, target door lock;It is close to obtain the corresponding door lock of the target door lock
Key;Determine whether the network state of the target door lock is in off-line state;The feelings of off-line state are in the target door lock
Under condition, activation code is generated according to the order validity period and the door lock key, and be sent to third party system, the activation code
For verify and unlock after being verified for target door lock.New order, and door lock can be moved in generating
In it is offline when, notify user to unlock using activation code by third party, can be to avoid former after house user change
Security risk existing for the use of password.
Detailed description of the invention
In order to illustrate the technical solution of the embodiments of the present invention more clearly, below by institute in the description to the embodiment of the present invention
Attached drawing to be used is needed to be briefly described, it should be apparent that, the accompanying drawings in the following description is only some implementations of the invention
Example, for those of ordinary skill in the art, without any creative labor, can also be according to these attached drawings
Obtain other attached drawings.
Fig. 1 is a kind of specific steps flow chart for unlocking verification method that the embodiment of the present invention one provides;
Fig. 2 is a kind of specific steps flow chart of unlocking verification method provided by Embodiment 2 of the present invention;
Fig. 3 is a kind of specific steps flow chart for unlocking verification method that the embodiment of the present invention three provides;
Fig. 4 is a kind of specific steps flow chart for unlocking verification method that the embodiment of the present invention four provides;
Fig. 5 is a kind of structure chart for door lock service device that the embodiment of the present invention five provides;
Fig. 6 is a kind of structure chart for intelligent door lock that the embodiment of the present invention six provides.
Specific embodiment
Following will be combined with the drawings in the embodiments of the present invention, and technical solution in the embodiment of the present invention carries out clear, complete
Site preparation description, it is clear that described embodiments are some of the embodiments of the present invention, instead of all the embodiments.Based on this hair
Embodiment in bright, every other implementation obtained by those of ordinary skill in the art without making creative efforts
Example, shall fall within the protection scope of the present invention.
Embodiment one
Referring to Fig.1, a kind of specific steps flow chart of the unlocking verification method provided it illustrates the embodiment of the present invention one.
Step 101, order information is obtained, the order information includes order validity period, target door lock.
The embodiment of the present invention is applied to door lock service device, and whether which can generate respectively online according to target door lock
Real-time password and activation code.
The embodiment of the present invention one typical application scenarios are the door lock management of hotel room, Hospitality management system according to
The check-in information at family generates order information, and the order information is sent to door lock service device.
Wherein, order validity period can move in the deadline in room for user.
Target door lock can move in the corresponding door lock in room for user, and door lock has unique mark.In practical applications,
Mark is arranged when leaving the factory, or is determined according to hotel and room number.
Step 102, the corresponding door lock key of the target door lock is obtained.
Door lock key is the hardware identifier of door lock.The corresponding unique door lock key of each door lock.
It is appreciated that door lock key can carry in order information, can also be obtained from the database of door lock service device
It takes, can also be obtained from other given servers.
Step 103, determine whether the network state of the target door lock is in off-line state.
Wherein, network state refers to whether target door lock can be communicated by network with door lock service device, if cannot,
Then target door lock is in off-line state;If can, target door lock is online.
It is appreciated that target door lock can directly receive the information of door lock service device transmission under presence, for example, real
When password, so that door lock can be verified by the password that the password inputs user;Under off-line state, target door lock without
Method receives the information that door lock service device is sent, to need by other means to verify user identity.
In practical applications, door lock service device can send detection information to target door lock, if within a certain period of time not
Receive feedback information, it is determined that the target door lock is in off-line state;If receiving feedback information during this period of time, really
The fixed target door lock is online.
Step 104, in the case where the target door lock is in off-line state, according to the order validity period and the door
Lock key and generate activation code, and be sent to third party system, the activation code be used to carry out for the target door lock verifying and
It unlocks after being verified.
Wherein, activation code can be by splicing order validity period and the door lock key according to certain rule, and encrypts
It generates.It is appreciated that the embodiment of the present invention is without restriction to its specific generation method.
The embodiment of the present invention is directed under off-line state the scene that can not receive verifying password, and the activation code of generation is sent to
Third party system, so that user is input in target door lock after getting the activation code, so that target door lock swashs according only to this
Code living can carry out subscriber authentication.
Third party system includes but is not limited to Hospitality management system or room management system or other appointing systems, can be with
Network is connected, and is communicated with door lock service device.
It is appreciated that activation code can be when user handles and moves in hotel, staff will be sharp in Hospitality management system
Code living informs user face to face, or is sent to user mobile phone.
It in practical applications, can also include subscriber phone number in order information, so that door lock service device can also be straight
It connects and the activation code of generation is sent to user mobile phone.
In conclusion the embodiment of the invention provides a kind of unlocking verification methods, which comprises obtain order letter
Breath, the order information includes order validity period, target door lock;Obtain the corresponding door lock key of the target door lock;Determine institute
Whether the network state for stating target door lock is in off-line state;In the case where the target door lock is in off-line state, according to
The order validity period and the door lock key generate activation code, and are sent to third party system, and the activation code is used for for institute
Target door lock is stated verify and unlock after being verified.New order of moving in can be being generated, and door lock is in offline
When, notify user to unlock using activation code by third party, can to avoid after house user change original code make
With existing security risk.
Embodiment two
Referring to Fig. 2, it illustrates a kind of specific steps flow charts of unlocking verification method provided by Embodiment 2 of the present invention.
Step 201, order information is obtained, the order information includes order validity period, target door lock.
The step is referred to the detailed description of step 101, and details are not described herein.
Step 202, the corresponding door lock key of the target door lock is obtained.
The step is referred to the detailed description of step 102, and details are not described herein.
Step 203, determine whether the network state of the target door lock is in off-line state.
The step is referred to the detailed description of step 103, and details are not described herein.
Step 204, in the case where the target door lock is in off-line state, according to the order validity period and the door
It locks key and generates the first validity period ciphertext.
Specifically, order validity period and the splicing of door lock key can be become into an object, then it is encrypted, is obtained
To the first validity period ciphertext.
Optionally, in another embodiment of the invention, above-mentioned steps 204 include sub-step 2041 to 2042:
Sub-step 2041 calculates the difference between the order validity period and preset reference time, and obtain first has relatively
The effect phase.
Wherein, it can be set according to practical application scene between note is punctual, the embodiment of the present invention is without restriction to its.
In practical applications, the relative efficiency phase can be indicated using minute, second.
Sub-step 2042, by the first relative efficiency phase and the door lock key splicing after, using symmetry algorithm into
Row encryption obtains the first validity period ciphertext.
Specifically, the first relative efficiency phase can be spliced behind door lock key, door lock key can also be spliced
Behind first relative efficiency phase.The embodiment of the present invention is without restriction to splicing sequence.
Symmetry algorithm is a kind of conventional encryption algorithm, and encryption key and decruption key, which can be calculated mutually, to be obtained.It is most of
In the case of, encryption key is identical with decruption key.
Step 205, the first check code is generated according to the order validity period and the door lock key.
It is appreciated that the algorithm of the first check code of generation and the algorithm of the first validity period ciphertext be not identical, it specifically can be with body
It is now different for Encryption Algorithm.
Optionally, in another embodiment of the invention, above-mentioned steps 205 include sub-step 2051 to 2052:
Sub-step 2051 is added after the order validity period and door lock key splicing using digest algorithm
It is close to obtain first password.
Specifically, order validity period can be spliced behind door lock key, door lock key can also be spliced in order
Behind validity period.The embodiment of the present invention is without restriction to splicing sequence.
The characteristics of digest algorithm is that ciphering process does not need encryption key, and the data by encryption can not be decrypted, only
Identical ciphertext can just be obtained by identical digest algorithm by inputting identical clear data.Encryption key is not present in digest algorithm
Management and distribution problem, be suitable for distributed network.
In embodiments of the present invention, digest algorithm can choose MD5.
Sub-step 2052 is encrypted to obtain the first check code to the first password using digest algorithm.
As can be seen that the first check code have passed through digest algorithm twice, safety is higher.
Step 206, the first validity period ciphertext and first check code are spliced into activation code, and are sent to third
Method, system, the activation code are used to verify and unlock after being verified for target door lock.
Specifically, the first validity period ciphertext can be spliced behind the first check code, the first check code can also be spelled
It connects behind the first validity period ciphertext.The embodiment of the present invention is without restriction to splicing sequence.
As can be seen that there are two parts contents for activation code, in authentication, it can use and two parts content is solved
Close two for obtaining the same object as a result, and compare, to realize the verification of activation code.
In conclusion the embodiment of the invention provides a kind of unlocking verification methods, which comprises obtain order letter
Breath, the order information includes order validity period, target door lock;Obtain the corresponding door lock key of the target door lock;Determine institute
Whether the network state for stating target door lock is in off-line state;In the case where the target door lock is in off-line state, according to
The order validity period and the door lock key generate activation code, and are sent to third party system, and the activation code is used for for institute
Target door lock is stated verify and unlock after being verified.New order of moving in can be being generated, and door lock is in offline
When, notify user to unlock using activation code by third party, can to avoid after house user change original code make
With existing security risk.
Embodiment three
Referring to Fig. 3, it illustrates a kind of specific steps flow charts for unlocking verification method that the embodiment of the present invention three provides.
Step 301, the authentication code of user's input is received.
The embodiment of the present invention is applied to intelligent door lock.
The authentication code that door lock is used to input user is verified, and is unlocked after being verified, or verifying is not
By when, do not unlock.
Door lock service device is managed for lock on the door, sends real-time password, to third party to door lock and third party system
System sends activation code etc..
Wherein, the authentication code of user's input includes but is not limited to: activation code, offline cryptogram, real-time password.
Authentication code obtains from third party system when user moves in room for the first time.For example, for hotel occupancy,
The activation code that hotel staff obtains Hospitality management system is sent to the mobile terminal of user, or informs face to face.
In practical applications, in order to distinguish various types of authentication codes, user before inputting identity information first
Input designated symbols.
Step 302, judge whether to get the real-time password for specifying validity period, the validity period includes current time.
When door lock is online, door lock service device can send real-time password to door lock by network, and specify
Validity period.When the presence of real-time password, and current time is before the deadline, it is determined that obtains and specifies the real-time close of validity period
Code;When real-time password be not present or current time not before the deadline, it is determined that have not been obtained and specify the real-time close of validity period
Code.
Step 303, in the case where the real-time password for specifying validity period has not been obtained, the body of user's input is determined
Whether part identifying code is activation code.
In embodiments of the present invention, preferential that authentication is carried out using the real-time password obtained online.When reality has not been obtained
When password, then authentication for the first time is carried out using the activation code that obtains offline.
Specifically, can be judged according to length or the additional character pre-entered.For example, user inputs " JHM " symbol first
Number when, be determined as activation code;Or the length of the authentication code of user's input is 10, is determined as activation code.
Step 304, in the case where the authentication code is activation code, the activation code is verified, and is testing
Card is unlocked after.
If the activation code for being appreciated that user's input is the activation code that door lock service device generates, which is used
Verification algorithm corresponding with generating algorithm obtains the activation code and is verified;If the activation code of user's input is not door lock service
When the activation code that device generates, verification algorithm corresponding with generating algorithm is used to the activation code, it is obstructed to obtain activation code verifying
It crosses.
In conclusion the embodiment of the invention provides a kind of unlocking verification methods, which comprises receive user's input
Authentication code;Judge whether to get the real-time password for specifying validity period, the validity period includes current time;Not
In the case where getting the real-time password for specifying validity period, determine whether the authentication code of user's input is activation
Code;In the case where the authentication code is activation code, the activation code is verified, and is opened after being verified
Lock.New order of moving in can be being generated, and when door lock is in offline, unlocked using the activation code of update, it can be to avoid
The security risk existing for the use of original code after house user changes.
Example IV
Referring to Fig. 4, it illustrates a kind of specific steps flow charts for unlocking verification method that the embodiment of the present invention four provides.
Step 401, the authentication code of user's input is received.
The step is referred to the detailed description of step 301, and details are not described herein.
Step 402, judge whether to get the real-time password for specifying validity period, the validity period includes current time.
The step is referred to the detailed description of step 302, and details are not described herein.
Step 403, in the case where the real-time password for specifying validity period has not been obtained, the body of user's input is determined
Whether part identifying code is activation code.
The step is referred to the detailed description of step 303, and details are not described herein.
Step 404, in the case where the authentication code is activation code, the second check code is extracted from the activation code
With third check code.
Specifically, the second check code and third check code are decrypted respectively by different fragments in activation code obtains.
It is appreciated that the second check code of extraction and the algorithm of third check code and the create-rule of activation code are corresponding.Swashing
Code living is in the case that door lock service device generates, and the first check code, the second check code and third check code are all the same.
Optionally, in another embodiment of the invention, above-mentioned steps 404 include sub-step 4041 to 4043:
Sub-step 4041 obtains the data for presetting the first segment in the activation code, obtains the second check code.
Wherein, activation code is spliced by check code and validity period ciphertext, so as to extract check code from activation code.
In practical applications, validity period ciphertext is m, and check code is n, if validity period ciphertext is located at before check code,
Then the first segment is m+1 to m+n.For example, activation code is 2101933786, if m is 7, n 3, then the first segment is 8 to 10
Position, it may be assumed that the second check code is 786.
Sub-step 4042 obtains the data for presetting the second segment in the activation code, obtains the second validity period ciphertext.
Such as activation code 2101933786, the second segment is 1 to 7, i.e. the second validity period ciphertext is 2101933.
It is appreciated that the splicing sequence of validity period ciphertext and check code can change, the length of the first segment and the second segment
Degree can also be set according to practical application scene, and the embodiment of the present invention is without restriction to its.
Sub-step 4043 generates third check code according to the second validity period ciphertext and preset door lock key.
Specifically, it is decrypted by door lock key pair the second validity period ciphertext, specific algorithm and the first validity period of generation
The algorithm of ciphertext is reciprocal.
Optionally, in another embodiment of the invention, above-mentioned sub-step 4043 includes sub-step 40431 to 40434:
Sub-step 40431, the second validity period ciphertext according to preset door lock key pair are solved using symmetry algorithm
It is close, obtained for the second relative efficiency phase.
It is appreciated that the sub-step 2042 of the step and embodiment two is inter-reverse operation.
Wherein, the second relative efficiency phase corresponded to the first relative efficiency phase, the second validity period ciphertext corresponding first validity period
Ciphertext.In addition, door lock key is identical.
Sub-step 40432 calculates the sum of the second relative efficiency phase and preset reference time and obtains absolute validity period.
It is appreciated that the sub-step 2041 of the step and embodiment two is inter-reverse operation.
Wherein, fiducial time is identical, and absolute validity period corresponds to order validity period.
Sub-step 40433 is added after the absolute validity period and door lock key splicing using digest algorithm
It is close to obtain the second password.
The step and sub-step 2051 use identical digest algorithm.
Second password corresponds to first password.
Sub-step 40434 is encrypted to obtain third check code to second password using digest algorithm.
The step and sub-step 2052 use identical digest algorithm.
Third check code corresponds to the first check code.
As can be seen that sub-step 40433 to 40434 is identical as the algorithm of sub-step 2051 to 2052, it may be assumed that when decryption, adopt
With the absolute validity period decrypted from activation code, a check code (i.e. third check code) is regenerated.It is appreciated that swashing
Second check code of the first segment in code living corresponds to the first check code of door lock service device generation.
Step 405, if second check code is consistent with third check code, the activation code is verified, and is being tested
Card is unlocked after.
It is appreciated that the second check code is consistent with third check code, the activation code of user's input is represented as door lock service device
For the activation code that the target door lock generates, to be verified.
Step 406, if second check code and third check code are inconsistent, the activation code verifying does not pass through.
It is appreciated that the second check code is consistent with third check code, the activation code for representing user's input is not door lock service
Device is directed to the activation code that the target door lock generates, so that verifying does not pass through.
Step 407, in the case where the activation code is verified, second password and absolute validity period are saved.
In embodiments of the present invention, when user moves in room for the first time, if be verified by activation code, by activation code
It is middle to extract in the second obtained password and write-in of absolute validity period door lock, so that user can open subsequently through second password
Lock.
Step 408, in the case where the authentication code is password, according to second password and absolute validity period pair
The password is verified, and is unlocked after being verified.
In practical applications, there is the device of record time in door lock, so as to get current time, and judge to work as
Before the deadline whether the preceding time.
It is appreciated that current time before the deadline, then represents user and does not reach and moves in deadline, thus password just
It unlocks when really.
In conclusion the embodiment of the invention provides a kind of unlocking verification methods, which comprises receive user's input
Authentication code;Judge whether to get the real-time password for specifying validity period, the validity period includes current time;Not
In the case where getting the real-time password for specifying validity period, determine whether the authentication code of user's input is activation
Code;In the case where the authentication code is activation code, the activation code is verified, and is opened after being verified
Lock.New order of moving in can be being generated, and when door lock is in offline, unlocked using the activation code of update, it can be to avoid
The security risk existing for the use of original code after house user changes.
Embodiment five
It is specific as follows it illustrates a kind of structure chart for door lock service device that the embodiment of the present invention five provides referring to Fig. 5.
Order information obtains module 501, and for obtaining order information, the order information includes order validity period, target
Door lock.
Door lock Key Acquisition Module 502, for obtaining the corresponding door lock key of the target door lock.
Network state determining module 503, for determining whether the network state of the target door lock is in off-line state.
Activation code generation module 504 is used in the case where the target door lock is in off-line state, according to the order
Validity period and the door lock key generate activation code, and are sent to third party system, and the activation code is used to supply the target door
Lock verify and unlock after being verified.Optionally, in another embodiment of the invention, above-mentioned activation code generates
Module 504 includes:
First validity period ciphertext generates submodule 5041, for being generated according to the order validity period and the door lock key
First validity period ciphertext.
First check code generates submodule 5042, for generating first according to the order validity period and the door lock key
Check code.
Activation code splices submodule 5043, sharp for the first validity period ciphertext and first check code to be spliced into
Code living.
Optionally, in another embodiment of the invention, above-mentioned first validity period ciphertext generation submodule 5041 includes:
First relative efficiency phase computing unit, for calculating the difference between the order validity period and preset reference time
Value, obtained for the first relative efficiency phase.
First validity period ciphertext generation unit, for the first relative efficiency phase and the door lock key to be spliced it
Afterwards, it is encrypted to obtain the first validity period ciphertext using symmetry algorithm.
Optionally, in another embodiment of the invention, above-mentioned first check code generation submodule 5042 includes:
First password generation unit, after splicing the order validity period and the door lock key, using abstract
Algorithm is encrypted to obtain first password;
First check code generation unit, for being encrypted to obtain the first verification using digest algorithm to the first password
Code.
In conclusion the server includes: that order information obtains the embodiment of the invention provides a kind of door lock service device
Module, for obtaining order information, the order information includes order validity period, target door lock;Door lock Key Acquisition Module is used
In the corresponding door lock key of the acquisition target door lock;Network state determining module, for determining the network of the target door lock
Whether state is in off-line state;Activation code generation module is used for the root in the case where the target door lock is in off-line state
Activation code is generated according to the order validity period and the door lock key, and is sent to third party system, the activation code is for supplying
The target door lock verify and unlock after being verified.New order of moving in can generated, and door lock be in from
When line, user is notified to unlock using activation code by third party, it can be to avoid the original code after house user change
Use existing security risk.
Embodiment five is embodiment of the method one, two corresponding Installation practices, and details are referred to
The detailed description of embodiment one, two, details are not described herein.
Embodiment six
It is specific as follows it illustrates a kind of structure chart for intelligent door lock that the embodiment of the present invention six provides referring to Fig. 6.
Authentication code receiving module 601, for receiving the authentication code of user's input.
Real-time password judgment module 602, gets the real-time password for specifying validity period for judging whether.
Activation code determining module 603, for determining and using in the case where the real-time password for specifying validity period has not been obtained
Whether the authentication code of family input is activation code.
Unlocking module 604 is verified, for being carried out to the activation code in the case where the authentication code is activation code
Verifying, and unlock after being verified.Optionally, in embodiments of the present invention, above-mentioned verifying unlocking module 604, comprising:
Check code extracting sub-module 6041, for extracting the second check code and third check code from the activation code.
It is verified submodule 6042, if consistent with third check code for second check code, the activation code
It is verified.
Verifying is described to swash if inconsistent for second check code and third check code not by submodule 6043
Code verifying living does not pass through.
Optionally, in another embodiment of the invention, above-mentioned check code extracting sub-module 6041, comprising:
Second check code acquiring unit obtains the second school for obtaining the data for presetting the first segment in the activation code
Test code.
Second validity period ciphertext acquiring unit obtains for obtaining the data for presetting the second segment in the activation code
Two validity period ciphertexts.
Third check code generation unit, for generating third according to the second validity period ciphertext and preset door lock key
Check code.
Optionally, in another embodiment of the invention, above-mentioned third check code generation unit includes:
Second relative efficiency phase generated subelement, adopted for the second validity period ciphertext according to preset door lock key pair
It is decrypted with symmetry algorithm, obtained for the second relative efficiency phase.
Absolute validity period computation subunit, obtains for calculating the sum of the second relative efficiency phase and preset reference time
Absolute validity period;
Second password generates subelement, for will be after the absolute validity period and the door lock key splice, using plucking
Algorithm is wanted to be encrypted to obtain the second password;
Third check code generates subelement, for being encrypted to obtain third school using digest algorithm to second password
Test code.
Second password preserving module 605, for saving second password in the case where the activation code is verified
With absolute validity period.
Second password authentication module 606 is used in the case where the authentication code is password, close according to described second
Code and absolute validity period verify the password, and unlock after being verified.
In conclusion the intelligent door lock includes: that authentication code connects the embodiment of the invention provides a kind of intelligent door lock
Module is received, for receiving the authentication code of user's input;Real-time password judgment module, specifies for judging whether to get
The real-time password of validity period;Activation code determining module, in the case where the real-time password for specifying validity period has not been obtained,
Whether the authentication code for determining user's input is activation code;Unlocking module is verified, for being activation in the authentication code
In the case where code, the activation code is verified, and unlocks after being verified.Can generate it is new move in order,
And door lock is unlocked using the activation code of update when being in offline, it can be to avoid the original code after house user change
Use existing security risk.
Embodiment six is embodiment of the method three, four corresponding Installation practices, and details are referred to embodiment three, four
Detailed description, details are not described herein.
The embodiment of the invention also provides a kind of electronic equipment, comprising: processor, memory and is stored in the storage
On device and the computer program that can run on the processor, the processor realize side above-mentioned when executing described program
Method.
The embodiment of the invention also provides a kind of readable storage medium storing program for executing, when the instruction in the storage medium is by electronic equipment
Processor execute when so that electronic equipment is able to carry out method above-mentioned.
For device embodiment, since it is basically similar to the method embodiment, related so being described relatively simple
Place illustrates referring to the part of embodiment of the method.
Algorithm and display are not inherently related to any particular computer, virtual system, or other device provided herein.
Various general-purpose systems can also be used together with teachings based herein.As described above, it constructs required by this kind of system
Structure be obvious.In addition, the present invention is also not directed to any particular programming language.It should be understood that can use various
Programming language realizes summary of the invention described herein, and the description done above to language-specific is to disclose this hair
Bright preferred forms.
In the instructions provided here, numerous specific details are set forth.It is to be appreciated, however, that implementation of the invention
Example can be practiced without these specific details.In some instances, well known method, structure is not been shown in detail
And technology, so as not to obscure the understanding of this specification.
Similarly, it should be understood that in order to simplify the disclosure and help to understand one or more of the various inventive aspects,
Above in the description of exemplary embodiment of the present invention, each feature of the invention is grouped together into single implementation sometimes
In example, figure or descriptions thereof.However, the disclosed method should not be interpreted as reflecting the following intention: i.e. required to protect
Shield the present invention claims features more more than feature expressly recited in each claim.More precisely, as following
Claims reflect as, inventive aspect is all features less than single embodiment disclosed above.Therefore,
Thus the claims for following specific embodiment are expressly incorporated in the specific embodiment, wherein each claim itself
All as a separate embodiment of the present invention.
Those skilled in the art will understand that can be carried out adaptively to the module in the equipment in embodiment
Change and they are arranged in one or more devices different from this embodiment.It can be the module or list in embodiment
Member or component are combined into a module or unit or component, and furthermore they can be divided into multiple submodule or subelement or
Sub-component.Other than such feature and/or at least some of process or unit exclude each other, it can use any
Combination is to all features disclosed in this specification (including adjoint claim, abstract and attached drawing) and so disclosed
All process or units of what method or apparatus are combined.Unless expressly stated otherwise, this specification is (including adjoint power
Benefit require, abstract and attached drawing) disclosed in each feature can carry out generation with an alternative feature that provides the same, equivalent, or similar purpose
It replaces.
Various component embodiments of the invention can be implemented in hardware, or to run on one or more processors
Software module realize, or be implemented in a combination thereof.It will be understood by those of skill in the art that can be used in practice
Microprocessor or digital signal processor (DSP) come realize some in verifying equipment according to an embodiment of the present invention of unlocking or
The some or all functions of person's whole component.The present invention is also implemented as one for executing method as described herein
Point or whole device or device programs.It is such to realize that program of the invention can store in computer-readable medium
On, or may be in the form of one or more signals.Such signal can be downloaded from an internet website to obtain, or
Person is provided on the carrier signal, or is provided in any other form.
It should be noted that the above-mentioned embodiments illustrate rather than limit the invention, and ability
Field technique personnel can be designed alternative embodiment without departing from the scope of the appended claims.In the claims,
Any reference symbol between parentheses should not be configured to limitations on claims.Word "comprising" does not exclude the presence of not
Element or step listed in the claims.Word "a" or "an" located in front of the element does not exclude the presence of multiple such
Element.The present invention can be by means of including the hardware of several different elements and being come by means of properly programmed computer real
It is existing.In the unit claims listing several devices, several in these devices can be through the same hardware branch
To embody.The use of word first, second, and third does not indicate any sequence.These words can be explained and be run after fame
Claim.
It is apparent to those skilled in the art that for convenience and simplicity of description, the system of foregoing description,
The specific work process of device and unit, can refer to corresponding processes in the foregoing method embodiment, and details are not described herein.
The foregoing is merely illustrative of the preferred embodiments of the present invention, is not intended to limit the invention, all in essence of the invention
Made any modifications, equivalent replacements, and improvements etc., should all be included in the protection scope of the present invention within mind and principle.
The above description is merely a specific embodiment, but scope of protection of the present invention is not limited thereto, any
Those familiar with the art in the technical scope disclosed by the present invention, can easily think of the change or the replacement, and should all contain
Lid is within protection scope of the present invention.Therefore, protection scope of the present invention should be subject to the protection scope in claims.
Claims (14)
1. a kind of unlocking verification method, which is characterized in that the described method includes:
Order information is obtained, the order information includes order validity period, target door lock;
Obtain the corresponding door lock key of the target door lock;
Determine whether the network state of the target door lock is in off-line state;
In the case where the target door lock is in off-line state, is generated and swashed according to the order validity period and the door lock key
Code living, and it is sent to third party system, the activation code is used to carry out verifying for target door lock and after being verified
It unlocks.
2. the method according to claim 1, wherein described according to the order validity period and the door lock key
The step of generating activation code, comprising:
The first validity period ciphertext is generated according to the order validity period and the door lock key;
The first check code is generated according to the order validity period and the door lock key;
The first validity period ciphertext and first check code are spliced into activation code.
3. according to the method described in claim 2, it is characterized in that, described according to the order validity period and the door lock key
The step of generating the first validity period ciphertext, comprising:
The difference between the order validity period and preset reference time is calculated, obtained for the first relative efficiency phase;
After the first relative efficiency phase and door lock key splicing, being encrypted to obtain first using symmetry algorithm has
Effect phase ciphertext.
4. according to the method described in claim 2, it is characterized in that, described according to the order validity period and the door lock key
The step of generating the first check code, comprising:
After the order validity period and door lock key splicing, encrypted to obtain first password using digest algorithm;
The first password is encrypted to obtain the first check code using digest algorithm.
5. a kind of unlocking verification method, which is characterized in that the described method includes:
Receive the authentication code of user's input;
Judge whether to get the real-time password for specifying validity period, the validity period includes current time;
In the case where the real-time password for specifying validity period has not been obtained, determine user input authentication code whether
For activation code;
In the case where the authentication code is activation code, the activation code is verified, and is opened after being verified
Lock.
6. according to the method described in claim 5, it is characterized in that, described the step of being verified to the activation code, comprising:
The second check code and third check code are extracted from the activation code;
If second check code is consistent with third check code, the activation code is verified;
If second check code and third check code are inconsistent, the activation code verifying does not pass through.
7. according to the method described in claim 6, it is characterized in that, described extract the second check code and from the activation code
The step of three check codes, comprising:
The data for presetting the first segment in the activation code are obtained, the second check code is obtained;
The data for presetting the second segment in the activation code are obtained, the second validity period ciphertext is obtained;
Third check code is generated according to the second validity period ciphertext and preset door lock key.
8. the method according to the description of claim 7 is characterized in that described according to the second validity period ciphertext and preset door
Lock the step of key generates third check code, comprising:
The second validity period ciphertext according to preset door lock key pair is decrypted using symmetry algorithm, and obtain second has relatively
The effect phase;
It calculates the sum of the second relative efficiency phase and preset reference time and obtains absolute validity period;
After the absolute validity period and door lock key splicing, encrypted to obtain the second password using digest algorithm;
Second password is encrypted to obtain third check code using digest algorithm.
9. according to the method described in claim 8, it is characterized in that, the method also includes:
In the case where the activation code is verified, second password and absolute validity period are saved.
10. according to the method described in claim 8, it is characterized in that, the method also includes:
In the case where the authentication code is password, the password is carried out according to second password and absolute validity period
Verifying, and unlock after being verified.
11. a kind of door lock service device, which is characterized in that the server includes:
Order information obtains module, and for obtaining order information, the order information includes order validity period, target door lock;
Door lock Key Acquisition Module, for obtaining the corresponding door lock key of the target door lock;
Network state determining module, for determining whether the network state of the target door lock is in off-line state;
Activation code generation module was used in the case where the target door lock is in off-line state, according to the order validity period
Activation code is generated with the door lock key, and is sent to third party system, the activation code is used to carry out for target door lock
It verifies and unlocks after being verified.
12. a kind of intelligent door lock, which is characterized in that the door lock includes:
Authentication code receiving module, for receiving the authentication code of user's input;
Real-time password judgment module, gets the real-time password for specifying validity period for judging whether;
Activation code determining module, in the case where the real-time password for specifying validity period has not been obtained, determining that user inputs
Authentication code whether be activation code;
Unlocking module is verified, for being verified to the activation code in the case where the authentication code is activation code, and
It unlocks after being verified.
13. a kind of electronic equipment characterized by comprising
Processor, memory and it is stored in the computer program that can be run on the memory and on the processor,
It is characterized in that, the processor is realized when executing described program such as method any one of in claims 1 to 10.
14. a kind of readable storage medium storing program for executing, which is characterized in that when the instruction in the storage medium is held by the processor of electronic equipment
When row, so that electronic equipment is able to carry out such as method any one of in claims 1 to 10.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201811015487.5A CN109272617B (en) | 2018-08-31 | 2018-08-31 | Unlocking verification method, server, door lock, electronic device and storage medium |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201811015487.5A CN109272617B (en) | 2018-08-31 | 2018-08-31 | Unlocking verification method, server, door lock, electronic device and storage medium |
Publications (2)
Publication Number | Publication Date |
---|---|
CN109272617A true CN109272617A (en) | 2019-01-25 |
CN109272617B CN109272617B (en) | 2020-08-07 |
Family
ID=65187669
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201811015487.5A Active CN109272617B (en) | 2018-08-31 | 2018-08-31 | Unlocking verification method, server, door lock, electronic device and storage medium |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN109272617B (en) |
Cited By (7)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN110430055A (en) * | 2019-08-13 | 2019-11-08 | 北京百佑科技有限公司 | Offline cryptogram generation method, offline cryptogram verification method and door lock management server |
CN110990824A (en) * | 2019-11-19 | 2020-04-10 | 江苏理工学院 | Method for remotely controlling service life of non-networked machine |
CN111080847A (en) * | 2019-11-25 | 2020-04-28 | 四川研宝科技有限公司 | Encryption, decryption and authentication method for intelligent door lock in offline environment |
CN113656775A (en) * | 2021-08-19 | 2021-11-16 | 广东好太太智能家居有限公司 | Offline password verification method and system with expiration date and intelligent lock |
CN113689610A (en) * | 2021-08-31 | 2021-11-23 | 深圳指芯物联技术有限公司 | Off-line authorization method and system for rental period password of rental house tenant |
CN114033261A (en) * | 2021-11-22 | 2022-02-11 | 中国铁塔股份有限公司 | Anti-theft method, device and equipment for rectifier and storage medium |
CN114448727A (en) * | 2022-04-02 | 2022-05-06 | 中国信息通信研究院 | Information processing method and system based on industrial internet identification analysis system |
Citations (7)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN201562306U (en) * | 2009-09-11 | 2010-08-25 | 王远洲 | Intelligent door lock control system |
CN104063932A (en) * | 2014-06-18 | 2014-09-24 | 大连智慧城科技有限公司 | Non-networking access system based on mobile terminal and implementation method |
CN104631961A (en) * | 2014-02-17 | 2015-05-20 | 袁磊 | Dynamic password electronic lock system in which password changes according to random codes |
CN105046796A (en) * | 2015-08-31 | 2015-11-11 | 芝麻智能科技(北京)有限公司 | Unlocking control method, device and system for electronic lock |
CN107545637A (en) * | 2017-09-13 | 2018-01-05 | 广东亚太天能科技股份有限公司 | The Activiation method and server of a kind of electronic lock |
CN107893583A (en) * | 2017-10-16 | 2018-04-10 | 杭州软库科技有限公司 | A kind of intelligent door lock system and control method |
CN107909685A (en) * | 2017-10-27 | 2018-04-13 | 张荣斌 | A kind of unlocking system and method for unlocking based on dynamic password |
-
2018
- 2018-08-31 CN CN201811015487.5A patent/CN109272617B/en active Active
Patent Citations (7)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN201562306U (en) * | 2009-09-11 | 2010-08-25 | 王远洲 | Intelligent door lock control system |
CN104631961A (en) * | 2014-02-17 | 2015-05-20 | 袁磊 | Dynamic password electronic lock system in which password changes according to random codes |
CN104063932A (en) * | 2014-06-18 | 2014-09-24 | 大连智慧城科技有限公司 | Non-networking access system based on mobile terminal and implementation method |
CN105046796A (en) * | 2015-08-31 | 2015-11-11 | 芝麻智能科技(北京)有限公司 | Unlocking control method, device and system for electronic lock |
CN107545637A (en) * | 2017-09-13 | 2018-01-05 | 广东亚太天能科技股份有限公司 | The Activiation method and server of a kind of electronic lock |
CN107893583A (en) * | 2017-10-16 | 2018-04-10 | 杭州软库科技有限公司 | A kind of intelligent door lock system and control method |
CN107909685A (en) * | 2017-10-27 | 2018-04-13 | 张荣斌 | A kind of unlocking system and method for unlocking based on dynamic password |
Cited By (7)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN110430055A (en) * | 2019-08-13 | 2019-11-08 | 北京百佑科技有限公司 | Offline cryptogram generation method, offline cryptogram verification method and door lock management server |
CN110990824A (en) * | 2019-11-19 | 2020-04-10 | 江苏理工学院 | Method for remotely controlling service life of non-networked machine |
CN111080847A (en) * | 2019-11-25 | 2020-04-28 | 四川研宝科技有限公司 | Encryption, decryption and authentication method for intelligent door lock in offline environment |
CN113656775A (en) * | 2021-08-19 | 2021-11-16 | 广东好太太智能家居有限公司 | Offline password verification method and system with expiration date and intelligent lock |
CN113689610A (en) * | 2021-08-31 | 2021-11-23 | 深圳指芯物联技术有限公司 | Off-line authorization method and system for rental period password of rental house tenant |
CN114033261A (en) * | 2021-11-22 | 2022-02-11 | 中国铁塔股份有限公司 | Anti-theft method, device and equipment for rectifier and storage medium |
CN114448727A (en) * | 2022-04-02 | 2022-05-06 | 中国信息通信研究院 | Information processing method and system based on industrial internet identification analysis system |
Also Published As
Publication number | Publication date |
---|---|
CN109272617B (en) | 2020-08-07 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN109272617A (en) | Unlocking verification method, server, door lock, electronic equipment and storage medium | |
CN105007577B (en) | A kind of virtual SIM card parameter management method, mobile terminal and server | |
CN108768972B (en) | Vehicle data storage and access method, device, system and electronic equipment | |
CN105100102B (en) | A kind of authority configuration and information configuring methods and device | |
CN105516948B (en) | A kind of apparatus control method and device | |
CN105871558B (en) | A kind of digital control system right management method based on USB flash disk physical serial numbers | |
CN104281794A (en) | Password storing and verifying method and password storing and verifying device | |
CN108173662A (en) | The authentication method and device of a kind of equipment | |
CN109471865A (en) | A kind of off-line data management method, system, server and storage medium | |
US11824988B2 (en) | Systems and methods for inter-service authentication | |
CN112134956A (en) | Distributed Internet of things instruction management method and system based on block chain | |
CN105490997B (en) | Safe checking method, device, terminal and server | |
CN109743161B (en) | Information encryption method, electronic device and computer readable medium | |
CN109035521A (en) | Auth method, server, system, electronic equipment and readable storage medium storing program for executing | |
CN106101054A (en) | The single-point logging method of a kind of multisystem and centralized management system | |
CN106878009A (en) | Key updating method and system | |
CN108848064A (en) | authorization management method and system | |
CN109768975A (en) | Cross-platform access method, apparatus and storage medium in open source system | |
CN109995712A (en) | Data encryption/decryption method, device, equipment and medium | |
CN115580414A (en) | Data opening system and method based on privacy computation | |
CN106487505B (en) | Key management, acquisition methods and relevant apparatus and system | |
CN109446793A (en) | A kind of account based on Windows agent changes decryption method and device | |
CN107968764B (en) | Authentication method and device | |
CN108009411A (en) | Method, apparatus and computing device based on recognition of face control automobile | |
CN104753927A (en) | Unified verification method and device |
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 |