Background
The cash boxes of the banks are very important articles in the banks, and cash of the banks needs to be put into the cash boxes for storage after counting is completed, so that the security of the cash boxes is very important for the banks, and if the cash boxes of the banks are opened by lawbreakers, the cash in the cash boxes is stolen, and very serious loss can be brought to the banks.
Due to banking needs, it is often necessary for a worker to open a cash box to arrange cash, such as to deposit or withdraw cash. However, the current bank has a single safe unlocking mode for the cash box, the cash box can be opened only by holding a key or knowing a fixed password, the identity of a worker cannot be effectively verified, and only manual supervision is needed, so that a machine which can be used by some lawbreakers to steal cash in the cash box is provided. Therefore, potential safety hazards exist in the money box, and workload of related workers is increased.
Disclosure of Invention
In view of this, the present application provides a method and an apparatus for controlling a banknote box, an electronic device, and a storage medium, so as to solve the problems that in the prior art, a security unlocking manner for a banknote box by a bank is relatively single, the banknote box can be opened only by holding a key or knowing a fixed password, and the identity of a worker cannot be effectively verified, and only manual supervision can be performed.
In order to achieve the above purpose, the present application provides the following technical solutions:
the application discloses in a first aspect a control method for a banknote cassette, comprising:
when unlocking request information of a money box sent by a user is received, checking the rationality of the unlocking request information; the unlocking request information comprises identity information of a user, an unlocking application place and unlocking application time;
if the rationality of the unlocking request information passes the verification, randomly generating an unlocking password of the coded lock of the money box;
comparing an unlocking password input by the user on the password lock of the cash box with the randomly generated unlocking password;
if the unlocking password input by the user on the password lock of the cash box is correct, controlling the password lock of the cash box to be opened, and detecting the state of the cash box; if the cash box is detected not to be opened within the preset time or the cash box is detected to be opened and then closed again, controlling the coded lock of the cash box to be locked again and setting the unlocking code to be invalid;
and if the unlocking password input by the user on the password lock of the cash box is incorrect, generating prompt information that the unlocking password is incorrect.
Optionally, in the above method, if the rationality check of the unlocking request information passes, randomly generating an unlocking password of the password lock of the banknote cassette includes:
and if the rationality of the unlocking request information passes the verification, generating a random number by using a random number generation algorithm, and using the random number as an unlocking password of the coded lock of the cash box.
Optionally, in the method, the controlling the coded lock of the banknote box to be unlocked includes:
and sending an unlocking instruction to the coded lock of the cash box to control the coded lock of the cash box to unlock.
Optionally, in the method, the detecting the state of the banknote box includes:
and when the coded lock of the cash box is detected to be opened, controlling a laser detection device to emit laser to detect the state of the cash box.
Optionally, in the above method, after the coded lock controlling the banknote box is unlocked, the method further includes:
generating record information for opening a coded lock of the cash box and uploading the record information to a server; the record information comprises the identity information of the user, the information of the cash box and the opening time of the coded lock of the cash box.
A second aspect of the present application discloses a control device for a banknote cassette, comprising:
the checking unit is used for checking the reasonability of the unlocking request information when the unlocking request information of the cash box sent by a user is received; the unlocking request information comprises identity information of a user, an unlocking application place and unlocking application time;
the password generation unit is used for randomly generating an unlocking password of the password lock of the cash box if the rationality of the unlocking request information is verified;
the comparison unit is used for comparing an unlocking password input by the user on the password lock of the cash box with the randomly generated unlocking password;
the control unit is used for controlling the coded lock of the cash box to be opened and detecting the state of the cash box if the unlocking code input by the user on the coded lock of the cash box is correct; if the cash box is detected not to be opened within the preset time or the cash box is detected to be opened and then closed again, controlling the coded lock of the cash box to be locked again and setting the unlocking code to be invalid;
and the information generating unit is used for generating prompt information that the unlocking password is wrong if the unlocking password input by the user on the password lock of the cash box is incorrect.
Optionally, in the foregoing apparatus, the password generating unit includes:
and the password generation subunit is used for generating a random number by using a random number generation algorithm if the rationality of the unlocking request information passes the verification, and taking the random number as the unlocking password of the coded lock of the cash box.
Optionally, in the above apparatus, the control unit includes:
and the unlocking subunit is used for sending an unlocking instruction to the coded lock of the cash box and controlling the coded lock of the cash box to unlock.
Optionally, in the above apparatus, the control unit includes:
and the detection subunit is used for controlling the laser detection device to emit laser to detect the state of the cash box when detecting that the coded lock of the cash box is opened.
Optionally, the above apparatus further includes:
the recording unit is used for generating recording information for opening the coded lock of the cash box and uploading the recording information to the server; the record information comprises the identity information of the user, the information of the cash box and the opening time of the coded lock of the cash box.
A third aspect of the present application discloses an electronic device, comprising:
one or more processors;
a storage device having one or more programs stored thereon;
the one or more programs, when executed by the one or more processors, cause the one or more processors to implement the method of any of the first aspects of the present invention.
A fourth aspect of the present application discloses a computer storage medium having a computer program stored thereon, wherein the computer program, when executed by a processor, implements the method according to any one of the first aspect of the present invention.
According to the technical scheme, when the unlocking request information of the cash box sent by the user is received, the rationality of the unlocking request information is verified. The unlocking request information comprises identity information of a user, an unlocking application place and unlocking application time. And if the rationality of the unlocking request information passes the verification, randomly generating an unlocking password of the password lock of the cash box. And comparing the unlocking password input by the user on the password lock of the cash box with the randomly generated unlocking password. And if the unlocking password input by the user on the password lock of the cash box is correct, controlling the password lock of the cash box to be opened, and detecting the state of the cash box. If the cash box is detected not to be opened within the preset time or the cash box is detected to be closed again after being opened, the coded lock of the cash box is controlled to be locked again, and the unlocking code is set to be invalid. And if the unlocking password input by the user on the password lock of the cash box is incorrect, generating prompt information that the unlocking password is incorrect. Therefore, the method can not only ensure the safety of the cash box, but also effectively verify and record the identity information of the user, and solves the problems that the safe unlocking mode of the cash box by a bank in the prior art is single, the cash box can be opened only by holding a key or knowing a fixed password, the identity of a worker cannot be effectively verified, and only manual supervision can be carried out.
Detailed Description
The technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the drawings in the embodiments of the present application, and it is obvious that the described embodiments are only a part of the embodiments of the present application, and not all of the embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present application.
In this application, the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising an … …" does not exclude the presence of other identical elements in a process, method, article, or apparatus that comprises the element.
Moreover, in this document, relational terms such as first and second, and the like may be used solely to distinguish one entity or action from another entity or action without necessarily requiring or implying any actual such relationship or order between such entities or actions.
The background technology shows that the safe unlocking mode of the bank for the bank note box is single at present, the bank note box can be opened only by holding a key or knowing a fixed password, the identity of a worker cannot be effectively verified, and only manual supervision is needed, so that a machine which can be used by some lawbreakers to steal cash in the bank note box is provided. Therefore, potential safety hazards exist in the money box, and workload of related workers is increased.
In view of this, embodiments of the present application provide a method and an apparatus for controlling a banknote box, an electronic device, and a storage medium, so as to solve the problems that in the prior art, a security unlocking manner for a banknote box by a bank is relatively single, the banknote box can be opened only by holding a key or knowing a fixed password, and the identity of a worker cannot be effectively verified, and only manual supervision is available.
The embodiment of the application discloses a method for switching a network link, which specifically includes, as shown in fig. 1:
s101, when unlocking request information of a money box sent by a user is received, checking the reasonability of the unlocking request information; the unlocking request information comprises identity information of a user, an unlocking application place and unlocking application time.
It should be noted that a bank worker logs in a system of a bank or a related application developed by a bank such as a mobile phone bank, and then can send an unlocking request of a bank note box at a related function module for opening the bank note box, where the unlocking request information includes identity information of a user, an unlocking application place, and an unlocking application time. When the system receives unlocking request information of the cash box sent by a user, the rationality of the unlocking request information needs to be checked. Whether the identity of the user is a bank worker or not is verified according to the identity information, the unlocking application place and the unlocking application time of the user in the unlocking request information, whether the operation related to the cash box, the unlocking application place and the unlocking application time meet the work arrangement of the bank or not can be executed. In this case, as long as one check result fails, the validity check of the unlocking request information does not pass, and only if each check result passes, the validity check of the unlocking request information is calculated to pass.
And S102, if the rationality of the unlocking request information is verified, randomly generating an unlocking password of the coded lock of the cash box.
It should be noted that after the identity information of the user, the unlocking application place and the unlocking application time are verified, if the result shows that the rationality verification of the unlocking request information passes, the unlocking password of the coded lock of the cash box is randomly generated. In the embodiment of the application, the password of the password lock of the cash box is not unlocked by a fixed password, but the password lock of the cash box can be unlocked by using the unlocking password of the password lock of the cash box randomly generated at each time, so that before the rationality check of the unlocking request information is passed, anyone does not know the password, certain lawbreakers can be effectively prevented from opening the password lock of the cash box without passing through a normal flow, and the security of the cash box is further enhanced by using the mode of the random password.
Optionally, in another embodiment of the present application, an implementation manner of step S102 specifically includes:
and if the rationality of the unlocking request information passes the verification, generating a random number by using a random number generation algorithm, and taking the random number as an unlocking password of the coded lock of the cash box.
It should be noted that after the identity information of the user, the location where the unlocking is applied and the time when the unlocking is applied are checked, if the result shows that the validity check of the unlocking request information passes, a random number with a specific number of digits, which can be generally set as a number with 6 digits, is generated by using a random number generation algorithm, and the random number is used as the unlocking password of the coded lock of the cash box. Therefore, the randomness of the unlocking password can be kept to a great extent, so that a lawbreaker can be prevented from having a machine which can be used by the lawbreaker due to the leakage of the password, and the cash in the cash box can be stolen by illegally opening the cash box.
S103, comparing an unlocking password input by the user on the password lock of the cash box with the randomly generated unlocking password.
It should be noted that after the unlocking password of the password lock of the banknote cassette is randomly generated, the system sends the unlocking password to the user, the user can check the unlocking password randomly generated by the system in the relevant function module for opening the banknote cassette, and then the user can input the unlocking password into the password lock of the banknote cassette. After the user finishes inputting the password, the unlocking password input by the user on the password lock of the cash box is compared with the randomly generated unlocking password, so that whether the unlocking password input by the user is consistent with the randomly generated unlocking password or not is verified.
S104, if the unlocking password input by the user on the password lock of the cash box is correct, controlling the password lock of the cash box to be opened, and detecting the state of the cash box; if the cash box is detected not to be opened within the preset time or the cash box is detected to be closed again after being opened, the coded lock of the cash box is controlled to be locked again, and the unlocking code is set to be invalid.
It should be noted that, after the user inputs the unlocking password into the password lock of the banknote cassette, if it is detected that the unlocking password input by the user on the password lock of the banknote cassette is correct, the system controls the password lock of the banknote cassette to be opened, and detects the state of the banknote cassette. If the cash box is detected not to be opened within the preset time or the cash box is detected to be closed again after being opened, the time can be set to be 5 seconds, the coded lock of the cash box is controlled to be locked again, and the unlocking code of the cash box is invalid. If the user needs to continue to open the combination lock of the cash box, the unlocking request information needs to be submitted again. The purpose of this is to prevent that under certain circumstances the bank staff opens the combination lock, but does not open the cash box, resulting in the combination lock always being in an open state and not automatically closing. And to prevent that in certain situations it appears that the bank staff has opened the cassette and has completed the relevant task, such as adding or removing banknotes from the cassette. But the coded lock is still in an open state and cannot be automatically closed. Therefore, after the coded lock of the cash box is controlled to be opened, the state of the cash box is detected, the safety of the coded lock of the cash box can be further improved, and the safety of the cash box and cash in the cash box can be ensured.
Optionally, in another embodiment of the present application, one implementation manner of detecting the state of the banknote cassette in step S104 specifically includes:
when the coded lock of the cash box is detected to be opened, the laser detection device is controlled to emit laser, and the state of the cash box is detected.
It should be noted that when the coded lock of the banknote box is detected to be opened, the state of the banknote box can be detected by using the laser detection device, and at this time, the system sends an opening instruction to the laser detection device, so that the laser detection device can be controlled to emit laser, the laser is emitted onto the banknote box, and the opening state and the closing state of the banknote box are detected in real time.
For convenience of understanding, the embodiment of the present application further provides a schematic view of a combination lock with a laser detection device, which is specifically shown in fig. 2. After randomly generating the unlocking password of the cash box, the bank background system can clamp the automatically generated unlocking password into the network through the SIM card and then transmit data to the wireless data receiving module, and then the wireless data receiving module transmits the data to the central processing unit, and the central processing unit obtains the information of the unlocking password. The user inputs the unlocking password into the central processing unit through the digital keys, and then the system controls the central processing unit to compare the unlocking password input by the user on the password lock of the cash box with the randomly generated unlocking password. If the unlocking password input by the user is correct, the control relay is controlled to be switched off, the magnet loses the magnetic force at the moment, and the password of the cash box is opened. After the coded lock is opened, if the laser detection device detects that the cash box is not opened within preset time, for example, the cash box is not opened within 5 seconds, the system sends a locking instruction to the central processing unit, so that the relay is controlled to be closed, the magnetic force is recovered, the coded lock of the cash box is locked again, and if the coded lock is opened again and needs to reapply the code, the last code is invalidated. If detect the paper money case in 5 seconds and opened, when laser sensing device detected the paper money case and reclosed, then the system would assign the instruction of locking to central processing unit to the control relay is closed, and magnetic force resumes this moment, and the trick lock of paper money case locks again, guarantees the safety of cash in paper money case and the paper money case, has also reached the effect of using electricity wisely simultaneously to a certain extent.
And S105, if the unlocking password input by the user on the password lock of the cash box is incorrect, generating prompt information that the unlocking password is incorrect.
It should be noted that, after the user inputs the unlocking password into the password lock of the banknote cassette, if it is detected that the unlocking password input by the user into the password lock of the banknote cassette is incorrect, the system generates a prompt message indicating that the unlocking password is incorrect and prompts the user. If the user needs to continue to open the combination lock of the cash box, the unlocking request information needs to be submitted again.
In the control method for the banknote box provided by the embodiment of the application, when the unlocking request information of the banknote box sent by a user is received, the rationality of the unlocking request information is verified. The unlocking request information comprises identity information of a user, an unlocking application place and unlocking application time. And if the rationality of the unlocking request information passes the verification, randomly generating an unlocking password of the password lock of the cash box. And comparing the unlocking password input by the user on the password lock of the cash box with the randomly generated unlocking password. And if the unlocking password input by the user on the password lock of the cash box is correct, controlling the password lock of the cash box to be opened, and detecting the state of the cash box. If the cash box is detected not to be opened within the preset time or the cash box is detected to be closed again after being opened, the coded lock of the cash box is controlled to be locked again, and the unlocking code is set to be invalid. And if the unlocking password input by the user on the password lock of the cash box is incorrect, generating prompt information that the unlocking password is incorrect. Therefore, the method can not only ensure the safety of the cash box, but also effectively verify and record the identity information of the user, and solves the problems that the safe unlocking mode of the cash box by a bank in the prior art is single, the cash box can be opened only by holding a key or knowing a fixed password, the identity of a worker cannot be effectively verified, and only manual supervision can be carried out.
Optionally, in another embodiment of the present application, the method for controlling a banknote cassette may further include:
generating record information for opening a coded lock of the cash box and uploading the record information to a server; the record information comprises identity information of a user, information of the cash box and opening time of a coded lock of the cash box.
It should be noted that, after the password lock of the banknote box is opened by the relevant staff each time, record information of the password lock for opening the banknote box is generated and uploaded to the server of the bank background system for storage. The record information comprises identity information of a user, information of the cash box and opening time of a coded lock of the cash box. Therefore, the information of related personnel for opening the coded lock of the cash box each time, the change information of cash in the cash box and the opening time of the coded lock of the cash box can be recorded. Once the cash in the cash box is abnormal, related workers can be accurately found according to the recorded information, the current data can be restored, and the bank can be helped to find out the specific reason of the abnormal data of the cash in the cash box as soon as possible.
The embodiment of the present application further discloses a control device of a banknote box, as shown in fig. 3, specifically including:
thechecking unit 301 is used for checking the reasonability of the unlocking request information when the unlocking request information of the cash box sent by a user is received; the unlocking request information comprises identity information of a user, an unlocking application place and unlocking application time.
And thepassword generating unit 302 is used for randomly generating an unlocking password of the password lock of the cash box if the rationality check of the unlocking request information passes.
Thecomparison unit 303 is configured to compare an unlocking password input by the user on the password lock of the banknote cassette with a randomly generated unlocking password.
Thecontrol unit 304 is used for controlling the coded lock of the cash box to be opened and detecting the state of the cash box if the unlocking password input by the user on the coded lock of the cash box is correct; if the cash box is detected not to be opened within the preset time or the cash box is detected to be closed again after being opened, the coded lock of the cash box is controlled to be locked again, and the unlocking code is set to be invalid.
Theinformation generating unit 305 is configured to generate a prompt message that the unlocking password is wrong if the unlocking password input by the user on the password lock of the cash cassette is incorrect.
In the control device for a banknote box provided by the embodiment of the application, when the unlocking request information of the banknote box sent by a user is received, thechecking unit 301 checks the rationality of the unlocking request information. The unlocking request information comprises identity information of a user, an unlocking application place and unlocking application time. If the validity check of the unlocking request information passes, thepassword generation unit 302 randomly generates an unlocking password of the password lock of the cash cassette. Thecomparison unit 303 compares the unlocking password input by the user on the password lock of the cash cassette with the randomly generated unlocking password. If the unlocking password input by the user on the password lock of the cash box is correct, thecontrol unit 304 controls the password lock of the cash box to be opened and detects the state of the cash box. If the cash box is detected not to be opened within the preset time or the cash box is detected to be closed again after being opened, the coded lock of the cash box is controlled to be locked again, and the unlocking code is set to be invalid. If the unlocking password input by the user on the password lock of the cash box is incorrect, theinformation generation unit 305 generates a prompt message that the unlocking password is incorrect. Therefore, the method can not only ensure the safety of the cash box, but also effectively verify and record the identity information of the user, and solves the problems that the safe unlocking mode of the cash box by a bank in the prior art is single, the cash box can be opened only by holding a key or knowing a fixed password, the identity of a worker cannot be effectively verified, and only manual supervision can be carried out.
In this embodiment, the specific implementation processes of thechecking unit 301, thepassword generating unit 302, the comparingunit 303, thecontrol unit 304, and theinformation generating unit 305 may refer to the contents of the method embodiment corresponding to fig. 1, and are not described herein again.
Optionally, in another embodiment of the present application, an implementation manner of thepassword generating unit 302 includes:
and the password generation subunit is used for generating a random number by using a random number generation algorithm if the rationality of the unlocking request information passes the verification, and taking the random number as the unlocking password of the password lock of the cash box.
In this embodiment, for the specific execution process of the password generation subunit, reference may be made to the contents of the above method embodiments, and details are not described here.
Optionally, in another embodiment of the present application, an implementation manner of thecontrol unit 304 includes:
and the unlocking subunit is used for sending an unlocking instruction to the coded lock of the cash box and controlling the coded lock of the cash box to unlock.
In this embodiment, for the specific execution process of the password generation subunit, reference may be made to the contents of the above method embodiments, and details are not described here.
Optionally, in another embodiment of the present application, an implementation manner of thecontrol unit 304 includes:
and the detection subunit is used for controlling the laser detection device to emit laser to detect the state of the cash box when detecting that the coded lock of the cash box is opened.
In this embodiment, for the specific execution process of the detecting subunit, reference may be made to the contents of the above method embodiments, and details are not described here.
Optionally, in another embodiment of the present application, the control device for a banknote cassette may further include:
the recording unit is used for generating recording information for opening a coded lock of the cash box and uploading the recording information to the server; the record information comprises identity information of a user, information of the cash box and opening time of a coded lock of the cash box.
In this embodiment, for the specific execution process of the recording unit, reference may be made to the contents of the above method embodiments, and details are not described here.
Another embodiment of the present application further provides an electronic device, as shown in fig. 4, specifically including:
one ormore processors 401.
Astorage device 402 having one or more programs stored thereon.
The one or more programs, when executed by the one ormore processors 401, cause the one ormore processors 401 to implement the method as in any one of the embodiments described above.
Another embodiment of the present application also provides a computer readable medium, on which a computer program is stored, wherein the computer program, when executed by a processor, implements the method according to any one of the above embodiments.
The embodiments in the present specification are described in a progressive manner, and the same and similar parts among the embodiments are referred to each other, and each embodiment focuses on the differences from the other embodiments. In particular, the system or system embodiments are substantially similar to the method embodiments and therefore are described in a relatively simple manner, and reference may be made to some of the descriptions of the method embodiments for related points. The above-described system and system embodiments are only illustrative, wherein the units described as separate parts may or may not be physically separate, and the parts displayed as units may or may not be physical units, may be located in one place, or may be distributed on a plurality of network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the solution of the present embodiment. One of ordinary skill in the art can understand and implement it without inventive effort.
Those of skill would further appreciate that the various illustrative elements and algorithm steps described in connection with the embodiments disclosed herein may be implemented as electronic hardware, computer software, or combinations of both, and that the various illustrative components and steps have been described above generally in terms of their functionality in order to clearly illustrate this interchangeability of hardware and software. Whether such functionality is implemented as hardware or software depends upon the particular application and design constraints imposed on the implementation. Skilled artisans may implement the described functionality in varying ways for each particular application, but such implementation decisions should not be interpreted as causing a departure from the scope of the present invention.
The previous description of the disclosed embodiments is provided to enable any person skilled in the art to make or use the present invention. Various modifications to these embodiments will be readily apparent to those skilled in the art, and the generic principles defined herein may be applied to other embodiments without departing from the spirit or scope of the application. Thus, the present application is not intended to be limited to the embodiments shown herein but is to be accorded the widest scope consistent with the principles and novel features disclosed herein.