Background
Modern mobile phones have become essential information devices for individuals, and in many industries, mobile phones are used as devices for accessing related information systems, and authentication procedures are required to be completed on the mobile phones before accessing the information systems. Meanwhile, in many industries, information systems are usually designed as a multi-level authority system, and the authentication process of accessing the information systems by other people is usually controlled by an administrator. This requires that an authentication process for an account related to the information system is performed for another mobile phone through one mobile phone that has been authenticated as an administrator account, so as to allow the information system to log in on the mobile phone and complete related operations.
To achieve the above purpose, there are two techniques that are currently popular:
(1) the administrator assigns a password in advance when creating an account, and the user inputs the account and an initial password on his mobile phone to complete the authentication of the information system, which is the most traditional way.
(2) The mobile phone of the administrator and the mobile phone of the user carry out communication between the devices through NFC or Bluetooth communication, the device of the administrator transmits a section of instruction data sent by the information system to the device of the user, and the device of the user uses the instruction data to complete access verification of the information system.
The first technique has the advantages of mature and simple realization and wide application; the disadvantage is that if the pre-assigned password is too simple, security issues are likely to arise; if the pre-assigned password is too complicated, the user input is very cumbersome. Meanwhile, this approach cannot be applied to a scene where there is a requirement for the place where authentication occurs. For example, facilities that have associated confidential data in custody, require that users accessing the information system be inside the facilities and have the associated personnel, thereby avoiding external malicious attempts to access.
Compared with the first technology, the second technology can avoid the complex process of inputting the password by the user, and data transmission is carried out through NFC or Bluetooth communication, so that the equipment of the user is required to be within a certain range from the equipment of an administrator, and the scene of the place where authentication occurs and the scene of the requirement can be met. However, the second technique also has a very serious security problem because the administrator's device usually has a very high operation authority in the information system, and if the user's device attacks the administrator's device with malicious codes during data transmission, and steals information related to the information system stored on the administrator's device, malicious operations may be performed on the information system. In order to avoid the related safety hazard, ideally, there cannot be a way of data transmission between the administrator's device and the user's device.
Disclosure of Invention
The invention aims to overcome the defects of the prior art and provides a security authentication method, a system, a device, computer equipment and a storage medium by utilizing an accelerometer, which do not need to input information on the equipment or use data transmission between the equipment to complete the security verification of the equipment and ensure the security of data information.
In order to solve at least one technical problem, an embodiment of the present invention provides a security authentication method using an accelerometer, where the method includes:
receiving a first X-axis acceleration, a first Y-axis acceleration and a first Z-axis acceleration which are read by the safety equipment which passes the administrator information authentication through the first accelerometer;
receiving a second X-axis acceleration, a second Y-axis acceleration and a second Z-axis acceleration which are read by the equipment to be verified through a second accelerometer;
comparing the first X-axis acceleration to the second X-axis rate of change of angle, comparing the first Y-axis acceleration to the second Y-axis acceleration, and comparing the first Z-axis acceleration to the second Z-axis acceleration;
when the comparison result meets a preset condition, setting the equipment to be verified as safety equipment so as to complete the safety authentication of the equipment to be verified;
the first X-axis acceleration, the first Y-axis acceleration, the first Z-axis acceleration, the second X-axis acceleration, the second Y-axis acceleration and the second Z-axis acceleration are respectively read by a first accelerometer of the safety device and a second accelerometer of the equipment to be verified after the safety device is bound with the equipment to be verified and moves in space for a preset time.
Optionally, the preset condition includes that data difference values between the first X-axis acceleration, the first Y-axis acceleration, the first Z-axis acceleration and the second X-axis acceleration, the second Y-axis acceleration, and the second Z-axis acceleration are smaller than a preset value.
Optionally, when the comparison result meets a preset condition, setting the device to be verified as a security device includes:
calculating data difference values of the first X-axis acceleration, the first Y-axis acceleration, the first Z-axis acceleration, the second X-axis acceleration, the second Y-axis acceleration and the second Z-axis acceleration according to the difference values determined by a data difference formula:
wherein the data difference formula is:
Axnrepresenting a first X-axis acceleration, BxnRepresents the second X-axis acceleration, AynRepresents the first Y-axis acceleration, BynRepresents the second Y-axis acceleration, AznRepresenting first Z-axis acceleration, BznRepresenting second Z-axis acceleration, dnRepresenting the difference;
and when the data difference value is smaller than the preset value, setting the equipment to be verified as safety equipment.
Optionally, the plurality of first X-axis accelerations, the first Y-axis accelerations, the first Z-axis accelerations and the second X-axis accelerations, the second Y-axis accelerations, and the second Z-axis accelerations are respectively read by a first accelerometer of the security device and a second accelerometer of the device to be verified after the security device and the device to be verified move in space for N seconds, where N is a positive integer;
a plurality of said first X axis accelerations are
A plurality of standsThe first Y-axis acceleration is
A plurality of said first Z axis accelerations are
A plurality of said second X axis accelerations are
A plurality of said second Y-axis accelerations are
A plurality of said second Z axis accelerations are
The calculating data difference values of the first X-axis acceleration, the first Y-axis acceleration, the first Z-axis acceleration, the second X-axis acceleration, the second Y-axis acceleration, and the second Z-axis acceleration according to the difference values determined by the data difference formula includes:
determining the data difference value according to the accumulated value of the difference value, wherein the accumulated value of the difference value is
Optionally, the preset value is 3.5; when the data difference value is smaller than the preset value, setting the device to be verified as a safety device, including:
when said
And when theta is 3.5, setting the device to be verified as a safety device.
Optionally, the first X-axis acceleration has a data deviation from the second X-axis acceleration in the range of 0.5, the first Y-axis acceleration has a data deviation from the second Y-axis acceleration in the range of 0.5, and the first Z-axis acceleration has a data deviation from the second Z-axis acceleration in the range of 0.5;
when calculated said
1.7263, setting the device to be verified as a safety device.
In addition, the embodiment of the invention also provides a security authentication system using the accelerometer, wherein the security authentication system comprises security equipment which passes the authentication of the administrator information, an authentication server and equipment to be verified;
the safety device and the device to be verified are bound, after the safety device and the device to be verified move in space for a preset time, a first accelerometer of the safety device reads a first X-axis acceleration, a first Y-axis acceleration and a first Z-axis acceleration, and a second accelerometer of the device to be verified reads a second X-axis acceleration, a second Y-axis acceleration and a second Z-axis acceleration;
the security device sending the first X-axis accelerometer, the first Y-axis accelerometer and the first Z-axis accelerometer to the authentication server;
the device to be verified sends the second X-axis accelerometer, the second Y-axis accelerometer and the second Z-axis accelerometer to the authentication server;
the authentication server compares the first X-axis accelerometer with the second X-axis accelerometer, compares the first Y-axis accelerometer with the second Y-axis accelerometer, compares the first Z-axis accelerometer with the second Z-axis accelerometer, and sets the device to be verified as a safety device when a comparison result meets a preset condition so as to complete safety authentication of the device to be verified.
In addition, an embodiment of the present invention further provides a security authentication apparatus using an accelerometer, where the apparatus includes:
the first receiving module is used for receiving a first X-axis acceleration, a first Y-axis acceleration and a first Z-axis acceleration which are read by the safety equipment passing the administrator information authentication through the first accelerometer;
the second receiving module is used for receiving a second X-axis acceleration, a second Y-axis acceleration and a second Z-axis acceleration which are read by the equipment to be verified through the second accelerometer;
a comparison module for comparing the first X-axis acceleration to the second X-axis acceleration, the first Y-axis acceleration to the second Y-axis acceleration, and the first Z-axis acceleration to the second Z-axis acceleration;
the authentication module is used for setting the equipment to be verified as safety equipment when the comparison result meets a preset condition so as to complete the safety authentication of the equipment to be verified;
the first X-axis acceleration, the first Y-axis acceleration, the first Z-axis acceleration, the second X-axis acceleration, the second Y-axis acceleration and the second Z-axis acceleration are respectively read by a first accelerometer of the safety device and a second accelerometer of the equipment to be verified after the safety device is bound with the equipment to be verified and moves in space for a preset time.
In addition, an embodiment of the present invention further provides a computer device, including: the system comprises a memory, a processor and an application program stored on the memory and capable of running on the processor, wherein the processor realizes the steps of the method of any embodiment when executing the application program.
In addition, an embodiment of the present invention further provides a computer-readable storage medium, on which an application program is stored, and when the application program is executed by a processor, the steps of any one of the above-mentioned embodiments of the method are implemented.
In the embodiment of the invention, by implementing the method, after the security device is bound with the device to be verified and moves in space for a preset time, the security device reads the first accelerometer to the server for uploading the linear accelerations of the three dimensions, meanwhile, the device to be verified reads the second accelerometer to the server for uploading the linear accelerations of the three dimensions, and after the server respectively compares the linear accelerations of the three dimensions of the two devices, the server determines whether the device to be verified is the security device according to the comparison result. And if the comparison result meets the preset condition, setting the equipment to be verified as the safety equipment. Therefore, the safety verification of the device setting to be verified is realized. In the whole verification process, the safety verification of the equipment to be verified is completed without inputting information on the safety equipment and the equipment to be verified or using data transmission between the equipment, so that the safety of data information is ensured.
Detailed Description
The technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are only a part of the embodiments of the present invention, 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 invention.
An embodiment of the present invention provides a security authentication system using an accelerometer, as shown in fig. 1, the security authentication system using an accelerometer includes a security device 10 that has been authenticated by administrator information, an authentication server 20, and a device to be verified 30;
the safety device 10 and the device to be verified 30 are bound, after the preset time of spatial motion, a first accelerometer of the safety device 10 reads a first X-axis acceleration, a first Y-axis acceleration and a first Z-axis acceleration, and a second accelerometer of the device to be verified 30 reads a second X-axis acceleration, a second Y-axis acceleration and a second Z-axis acceleration;
the secure device 10 sends the first X-axis acceleration, the first Y-axis acceleration, and the first Z-axis acceleration to the authentication server 20;
the device to be verified 30 sends the second X-axis acceleration, the second Y-axis acceleration, and the second Z-axis acceleration to the authentication server;
the authentication server 20 compares the first X axis acceleration with the second X axis acceleration, compares the first Y axis acceleration with the second Y axis acceleration, compares the first Z axis acceleration with the second Z axis acceleration, and sets the device to be verified 30 as a security device when a comparison result satisfies a preset condition, so as to complete security authentication of the device to be verified 30.
Accordingly, the authentication server 20 completes the security verification of the device to be verified 30. The device to be verified 30 as a secure device can perform information interaction with the authentication server 20 within a specified range.
The embodiment of the invention provides a security authentication method using an accelerometer, which is applied to the authentication server 20 shown in fig. 1. As shown in fig. 2, the security authentication method using an accelerometer includes the following steps:
s102, receiving a first X-axis acceleration, a first Y-axis acceleration and a first Z-axis acceleration which are read by the safety equipment passing the administrator information authentication through the first accelerometer.
In this embodiment, before S102, the method further includes: receiving an information authentication request of a security request device; and when the information authentication request passes, using the safety request device as the safety device which passes the administrator information authentication.
In this embodiment, the security device is connected to the authentication server via a network, and performs security authentication of the authentication server. The safety device can read the three-dimensional linear acceleration of the safety device in the space motion through the internal accelerometer. In particular, the security device is a mobile phone. As shown in fig. 3, a rectangular coordinate system is established with the center of mass of the mobile phone as the center. As shown in fig. 4, the vector of the movement of the mobile phone in the space with the centroid as the origin of coordinates is R. In a rectangular coordinate system, the vector R is the vector detected by the accelerometer (which may be a combination of gravity or inertial forces in the above example). RX, RY, RZ are the projections of vector R on the X, Y, Z axes, respectively. Wherein, R2 ^ RX ^2+ RY ^2+ RZ ^ 2.
An accelerometer carried in a smart phone, taking an Android system as an example, can measure the change of the distance of the mobile phone in the X axis, the Y axis and the Z axis within a period of time through the following codes:
assuming that the initial X, Y, and Z coordinates of the handset are [0, 0, 0], moving the handset in space, continuously recording the reading changes, sampling every 1 second, sampling 10 times, and obtaining the following table data:
wherein the values in the table have removed the gravitational acceleration effect. The motion trajectory in space obtained from the above data is shown in fig. 5.
And S104, receiving a second X-axis acceleration, a second Y-axis acceleration and a second Z-axis acceleration which are read by the equipment to be verified through the second accelerometer.
In this embodiment, the device to be verified is connected to the authentication server via a network, and the security authentication of the authentication server is not completed. And the equipment to be verified sends a security verification request to the authentication server, and uploads the second X-axis acceleration, the second Y-axis acceleration and the second Z-axis acceleration read by the second accelerometer to the authentication server so as to perform security verification on the server to be verified. In particular, the security device is a mobile phone. The way in which the device to be authenticated reads the three-dimensional linear acceleration of the spatial motion process by using the second accelerometer is as described above, and is not described in detail here.
S106, comparing the first X-axis acceleration with the second X-axis angular change rate, comparing the first Y-axis acceleration with the second Y-axis acceleration, and comparing the first Z-axis acceleration with the second Z-axis acceleration.
In this embodiment, it should be noted that the first X axis acceleration, the first Y axis acceleration, the first Z axis acceleration, the second X axis acceleration, the second Y axis acceleration, and the second Z axis acceleration are the functions that the security device is bound with the device to be verified and is read by the first accelerometer of the security device and read by the second accelerometer of the device to be verified after a preset time period of spatial motion.
Specifically, the security device is a mobile phone a, the device to be verified is a mobile phone B, both of which are equipped with an accelerometer and are connected to the authentication server through a network. The two planes of the mobile phone A and the mobile phone B are fixed, so that the positions of the two planes are consistent in space and no sliding occurs. A simple method is to use a rubber band to tighten. The administrator holds the fixed mobile phone A and the fixed mobile phone B by hands, and moves for a period of time in the space, wherein the time can be about 5 to 30 seconds, the time is recorded as N seconds, and the mobile phone A and the mobile phone B upload the readings on the accelerometers to the authentication server. The authentication server receives the reading of the mobile phone A:
receiving the reading of the mobile phone B:
the readings received by the authentication server are three-dimensional linear accelerations on the mobile phone A and the mobile phone B respectively. Further, the two sets of three-dimensional linear accelerations received by the authentication server are compared respectively.
S108, when the comparison result meets a preset condition, setting the equipment to be verified as safety equipment so as to complete the safety authentication of the equipment to be verified; the first X-axis acceleration, the first Y-axis acceleration, the first Z-axis acceleration, the second X-axis acceleration, the second Y-axis acceleration and the second Z-axis acceleration are respectively read by a first accelerometer of the safety device and a second accelerometer of the equipment to be verified after the safety device is bound with the equipment to be verified and moves in space for a preset time.
In this embodiment, a preset condition is preset on the authentication server, and the preset condition is used for determining the matching degree of the comparison result. The preset condition may be that the matching degree of the comparison result reaches a preset value. And when the authentication server determines that the comparison result meets the preset condition, setting the equipment to be verified as safety equipment so as to complete the safety authentication of the equipment to be verified.
Specifically, the authentication server judges through comparison results and preset conditions
And
whether or not they belong to the same motion trajectory, e.g.If yes, the authorization of the mobile phone B is considered to pass.
By implementing the method, after the safety device is bound with the device to be verified and moves in space for a preset time, the safety device reads the first accelerometer to the server for uploading the linear acceleration of the three dimensions, meanwhile, the device to be verified reads the second accelerometer to the server for uploading the linear acceleration of the three dimensions, and after the server respectively compares the linear accelerations of the three dimensions of the two devices, whether the device to be verified is the safety device is determined according to the comparison result. And if the comparison result meets the preset condition, setting the equipment to be verified as the safety equipment. Therefore, the safety verification of the device setting to be verified is realized. In the whole verification process, the safety verification of the equipment to be verified is completed without inputting information on the safety equipment and the equipment to be verified or using data transmission between the equipment, so that the safety of data information is ensured.
In an embodiment, the preset condition includes that data difference values between the first X-axis acceleration, the first Y-axis acceleration, the first Z-axis acceleration and the second X-axis acceleration, the second Y-axis acceleration, and the second Z-axis acceleration are smaller than a preset value.
Preferably, when the comparison result meets a preset condition, setting the device to be verified as a security device includes: calculating data difference values of the first X-axis acceleration, the first Y-axis acceleration, the first Z-axis acceleration, the second X-axis acceleration, the second Y-axis acceleration and the second Z-axis acceleration according to the difference values determined by a data difference formula: wherein the data difference formula is:
Axnrepresenting a first X-axis acceleration, BxnRepresents the second X-axis acceleration, AynRepresents the first Y-axis acceleration, BynRepresents the second Y-axis acceleration, AznRepresenting first Z-axis acceleration, BznRepresenting second Z-axis acceleration, dnRepresenting the difference;
and when the data difference value is smaller than the preset value, setting the equipment to be verified as safety equipment.
Preferably, the plurality of first X-axis accelerations, the first Y-axis accelerations, the first Z-axis accelerations and the second X-axis accelerations, the second Y-axis accelerations, and the second Z-axis accelerations are respectively read by a first accelerometer of the security device and a second accelerometer of the device to be verified after the security device and the device to be verified move in space for N seconds, where N is a positive integer; a plurality of said first X axis accelerations are
A plurality of said first Y-axis accelerations are
A plurality of said first Z axis accelerations are
A plurality of said second X axis accelerations are
A plurality of said second Y-axis accelerations are
A plurality of said second Z axis accelerations are
The calculating data difference values of the first X-axis acceleration, the first Y-axis acceleration, the first Z-axis acceleration, the second X-axis acceleration, the second Y-axis acceleration, and the second Z-axis acceleration according to the difference values determined by the data difference formula includes: determining the data difference value according to the accumulated value of the difference value, wherein the accumulated value of the difference value is
Further, the preset value is 3.5; when the data difference value is smaller than the preset value, setting the device to be verified as a safety device, including: when said
And when theta is 3.5, setting the device to be verified as a safety device.
Specifically, whether the mobile phone A and the mobile phone B move in the space in a consistent manner or not is judged through the gyroscope to perform authorization authentication, and whether the reading of the mobile phone A and the reading of the mobile phone B are in the same movement track or not can be judged in any way. For completeness of explanation, a practical method is described herein:
and
the difference between the sampling points of (a) is:
ideally there are:
because there will be some slight differences in accuracy between the gyroscopes of the two handsets, plus possible delays of the network, a threshold θ is set, which is:
in practice, θ may be set to 3.5.
Preferably, the first X-axis acceleration has a data deviation from the second X-axis acceleration in the range of 0.5, the first Y-axis acceleration has a data deviation from the second Y-axis acceleration in the range of 0.5, and the first Z-axis acceleration has a data deviation from the second Z-axis acceleration in the range of 0.5; when calculated said
1.7263, setting the device to be verified as a safety device.
Specifically, the codes are actually written for the verification of the present invention according to the above description, wherein the accelerometer readings of the mobile phone a and the mobile phone B have a random deviation within 0.5, the following table data is obtained:
according to the error formula, the above error is 1.7263, and within the error range, it can be determined as belonging to the same motion track. In addition, the results of ten thousand tests using the simulator are shown in fig. 6.
In one embodiment, the invention also provides a security authentication device using the accelerometer. As shown in fig. 7, the apparatus includes:
the first receiving module 71 is configured to receive a first X-axis acceleration, a first Y-axis acceleration, and a first Z-axis acceleration that are read by the security device that has passed the administrator information authentication through the first accelerometer.
In this embodiment, the security authentication apparatus using a terminal gyroscope further includes a setting module, configured to receive an information authentication request from a security request device; and when the information authentication request passes, using the safety request device as the safety device which passes the administrator information authentication.
In this embodiment, the security device is connected to the authentication server via a network, and performs security authentication of the authentication server. The safety device can read the three-dimensional linear acceleration of the safety device in the space motion through the internal accelerometer. In particular, the security device is a mobile phone. As shown in fig. 3, a rectangular coordinate system is established with the center of mass of the mobile phone as the center. As shown in fig. 4, the vector of the movement of the mobile phone in the space with the centroid as the origin of coordinates is R. In a rectangular coordinate system, the vector R is the vector detected by the accelerometer (which may be a combination of gravity or inertial forces in the above example). RX, RY, RZ are the projections of vector R on the X, Y, Z axes, respectively. Wherein, R2 ^ RX ^2+ RY ^2+ RZ ^ 2.
An accelerometer carried in a smart phone, taking an Android system as an example, can measure the change of the distance of the mobile phone in the X axis, the Y axis and the Z axis within a period of time through the following codes:
assuming that the initial X, Y, and Z coordinates of the handset are [0, 0, 0], moving the handset in space, continuously recording the reading changes, sampling every 1 second, sampling 10 times, and obtaining the following table data:
wherein the values in the table have removed the gravitational acceleration effect. The motion trajectory in space obtained from the above data is shown in fig. 5.
The second receiving module 72 is configured to receive a second X-axis acceleration, a second Y-axis acceleration, and a second Z-axis acceleration, which are read by the device to be verified through the second accelerometer.
In this embodiment, the device to be verified is connected to the authentication server via a network, and the security authentication of the authentication server is not completed. And the equipment to be verified sends a security verification request to the authentication server, and uploads the second X-axis acceleration, the second Y-axis acceleration and the second Z-axis acceleration read by the second accelerometer to the authentication server so as to perform security verification on the server to be verified. In particular, the security device is a mobile phone. The way in which the device to be authenticated reads the three-dimensional linear acceleration of the spatial motion process by using the second accelerometer is as described above, and is not described in detail here.
A comparison module 73, configured to compare the first X-axis acceleration with the second X-axis angular rate of change, compare the first Y-axis acceleration with the second Y-axis acceleration, and compare the first Z-axis acceleration with the second Z-axis acceleration.
In this embodiment, it should be noted that the first X axis acceleration, the first Y axis acceleration, the first Z axis acceleration, the second X axis acceleration, the second Y axis acceleration, and the second Z axis acceleration are the functions that the security device is bound with the device to be verified and is read by the first accelerometer of the security device and read by the second accelerometer of the device to be verified after a preset time period of spatial motion.
Specifically, the security device is a mobile phone a, the device to be verified is a mobile phone B, both of which are equipped with an accelerometer and are connected to the authentication server through a network. The two planes of the mobile phone A and the mobile phone B are fixed, so that the positions of the two planes are consistent in space and no sliding occurs. A simple method is to use a rubber band to tighten. The administrator holds the fixed mobile phone A and the fixed mobile phone B by hands, and moves for a period of time in the space, wherein the time can be about 5 to 30 seconds, the time is recorded as N seconds, and the mobile phone A and the mobile phone B upload the readings on the accelerometers to the authentication server. The authentication server receives the reading of the mobile phone A:
receiving the reading of the mobile phone B:
the readings received by the authentication server are three-dimensional linear accelerations on the mobile phone A and the mobile phone B respectively. Further, the two sets of three-dimensional linear accelerations received by the authentication server are compared respectively.
The authentication module 74 is configured to set the device to be verified as a security device when the comparison result meets a preset condition, so as to complete security authentication of the device to be verified; the first X-axis acceleration, the first Y-axis acceleration, the first Z-axis acceleration, the second X-axis acceleration, the second Y-axis acceleration and the second Z-axis acceleration are respectively read by a first accelerometer of the safety device and a second accelerometer of the equipment to be verified after the safety device is bound with the equipment to be verified and moves in space for a preset time.
In this embodiment, a preset condition is preset on the authentication server, and the preset condition is used for determining the matching degree of the comparison result. The preset condition may be that the matching degree of the comparison result reaches a preset value. And when the authentication server determines that the comparison result meets the preset condition, setting the equipment to be verified as safety equipment so as to complete the safety authentication of the equipment to be verified.
Specifically, the authentication server judges through comparison results and preset conditions
And
and if the mobile phone B belongs to the same motion track, the authorization of the mobile phone B is considered to pass.
In an embodiment, the preset condition includes that data difference values between the first X-axis acceleration, the first Y-axis acceleration, the first Z-axis acceleration and the second X-axis acceleration, the second Y-axis acceleration, and the second Z-axis acceleration are smaller than a preset value.
Preferably, when the comparison result meets a preset condition, setting the device to be verified as a security device includes: calculating data difference values of the first X-axis acceleration, the first Y-axis acceleration, the first Z-axis acceleration, the second X-axis acceleration, the second Y-axis acceleration and the second Z-axis acceleration according to the difference values determined by a data difference formula: wherein the data difference formula is:
Axnrepresenting a first X-axis acceleration, BxnRepresents the second X-axis acceleration, AynRepresents the first Y-axis acceleration, BynRepresents the second Y-axis acceleration, AznRepresenting first Z-axis acceleration, BznRepresenting second Z-axis acceleration, dnRepresenting the difference;
and when the data difference value is smaller than the preset value, setting the equipment to be verified as safety equipment.
Preferably, the plurality of first X-axis accelerations, the first Y-axis accelerations, the first Z-axis accelerations and the second X-axis accelerations, the second Y-axis accelerations, and the second Z-axis accelerations are respectively read by a first accelerometer of the security device and a second accelerometer of the device to be verified after the security device and the device to be verified move in space for N seconds, where N is a positive integer; a plurality of said first X axis accelerations are
A plurality of said first Y-axis accelerations are
A plurality of said first Z axis accelerations are
A plurality of said second X axis accelerations are
A plurality of said second Y-axis accelerations are
A plurality of said second Z axis accelerations are
The calculating data difference values of the first X-axis acceleration, the first Y-axis acceleration, the first Z-axis acceleration, the second X-axis acceleration, the second Y-axis acceleration, and the second Z-axis acceleration according to the difference values determined by the data difference formula includes: determining the data difference value according to the accumulated value of the difference value, wherein the accumulated value of the difference value is
Further, the preset value is 3.5; when the data difference value is smaller than the preset value, setting the device to be verified as a safety device, including: when said
And when theta is 3.5, setting the device to be verified as a safety device.
Specifically, whether the mobile phone A and the mobile phone B move in the space in a consistent manner or not is judged through the gyroscope to perform authorization authentication, and whether the reading of the mobile phone A and the reading of the mobile phone B are in the same movement track or not can be judged in any way. For completeness of explanation, a practical method is described herein:
and
the difference between the sampling points of (a) is:
ideally there are:
because there will be some slight differences in accuracy between the gyroscopes of the two handsets, plus possible delays of the network, a threshold θ is set, which is:
in practice, θ may be set to 3.5.
Preferably, the first X-axis acceleration has a data deviation from the second X-axis acceleration in the range of 0.5, the first Y-axis acceleration has a data deviation from the second Y-axis acceleration in the range of 0.5, and the first Z-axis acceleration has a data deviation from the second Z-axis acceleration in the range of 0.5; when calculated said
1.7263, setting the device to be verified as a safety device.
Specifically, the codes are actually written for the verification of the present invention according to the above description, wherein the accelerometer readings of the mobile phone a and the mobile phone B have a random deviation within 0.5, the following table data is obtained:
according to the error formula, the above error is 1.7263, and within the error range, it can be determined as belonging to the same motion track. In addition, the results of ten thousand tests using the simulator are shown in fig. 6.
For a specific limitation of a security authentication device using an accelerometer, reference may be made to the above limitation on a security authentication method using an accelerometer, which is not described herein again. The modules in the security authentication device using the accelerometer may be wholly or partially implemented by software, hardware and a combination thereof. The modules can be embedded in a hardware form or independent from a processor in the computer device, and can also be stored in a memory in the computer device in a software form, so that the processor can call and execute operations corresponding to the modules.
The computer-readable storage medium provided by the embodiments of the present invention stores an application program thereon, and when the application program is executed by a processor, the application program implements a security authentication method using an accelerometer according to any one of the embodiments. The computer-readable storage medium includes, but is not limited to, any type of disk including floppy disks, hard disks, optical disks, CD-ROMs, and magneto-optical disks, ROMs (Read-Only memories), RAMs (Random AcceSS memories), EPROMs (EraSable Programmable Read-Only memories), EEPROMs (Electrically EraSable Programmable Read-Only memories), flash memories, magnetic cards, or optical cards. That is, a storage device includes any medium that stores or transmits information in a form readable by a device (e.g., a computer, a cellular phone), and may be a read-only memory, a magnetic or optical disk, or the like.
The embodiment of the present invention further provides a computer application program, which runs on a computer, and the computer application program is configured to execute a security authentication method using an accelerometer according to any one of the above embodiments.
Fig. 8 is a schematic structural diagram of a computer device in the embodiment of the present invention.
An embodiment of the present invention further provides a computer device, as shown in fig. 8. The computer apparatus includes devices such as a processor 802, a memory 803, an input unit 804, and a display unit 805. Those skilled in the art will appreciate that the device configuration means shown in fig. 8 do not constitute a limitation of all devices and may include more or less components than those shown, or some components in combination. The memory 803 may be used to store the application program 801 and various functional modules, and the processor 802 executes the application program 801 stored in the memory 803, thereby performing various functional applications of the device and data processing. The memory may be internal or external memory, or include both internal and external memory. The memory may comprise read-only memory (ROM), Programmable ROM (PROM), Electrically Programmable ROM (EPROM), Electrically Erasable Programmable ROM (EEPROM), flash memory, or random access memory. The external memory may include a hard disk, a floppy disk, a ZIP disk, a usb-disk, a magnetic tape, etc. The disclosed memory includes, but is not limited to, these types of memory. The disclosed memory is by way of example only and not by way of limitation.
The input unit 804 is used for receiving input of signals and receiving keywords input by a user. The input unit 804 may include a touch panel and other input devices. The touch panel can collect touch operations of a user on or near the touch panel (for example, operations of the user on or near the touch panel by using any suitable object or accessory such as a finger, a stylus and the like) and drive the corresponding connecting device according to a preset program; other input devices may include, but are not limited to, one or more of a physical keyboard, function keys (e.g., play control keys, switch keys, etc.), a trackball, a mouse, a joystick, and the like. The display unit 805 may be used to display information input by a user or information provided to the user and various menus of the terminal device. The display unit 805 may take the form of a liquid crystal display, an organic light emitting diode, or the like. The processor 802 is a control center of the terminal device, connects various parts of the entire device using various interfaces and lines, and performs various functions and processes data by operating or executing software programs and/or modules stored in the memory 803 and calling data stored in the memory.
As one embodiment, the computer device includes: one or more processors 802, memory 803, one or more applications 801, wherein the one or more applications 801 are stored in the memory 803 and configured to be executed by the one or more processors 802, the one or more applications 801 configured to perform a security authentication using an accelerometer in any of the above embodiments.
In addition, the security authentication method, system, apparatus, computer device and storage medium using an accelerometer according to the embodiments of the present invention are described in detail above, and specific examples are used herein to explain the principles and embodiments of the present invention, and the descriptions of the above embodiments are only used to help understand the method and the core ideas of the present invention; meanwhile, for a person skilled in the art, according to the idea of the present invention, there may be variations in the specific embodiments and the application scope, and in summary, the content of the present specification should not be construed as a limitation to the present invention.