A data authentication method, device and computer equipment

By judging the permissions and data format of the sending device in the MQTT protocol, refusing permissionless data transmission, and performing incremental data processing, the problem of poor data authentication effect in smart home communication is solved, and more efficient bandwidth utilization is achieved.

CN115766118BActive Publication Date: 2025-07-25GREE ELECTRIC APPLIANCE INC OF ZHUHAI +1
View PDF 3 Cites 0 Cited by

Patent Information

Application Number
CN202211345425.7
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-10-31
Publication Date
2025-07-25
Estimated Expiration
2042-10-31

AI Technical Summary

Technical Problem

The existing MQTT protocol has poor data authentication effect in smart home communication, resulting in greater transmission pressure on the server.

Method used

By obtaining the permission information of the sending device, it determines whether it has data transmission permissions, and refuses operations when the permissions are insufficient or the data format is inconsistent, and incremental data processing is performed to reduce bandwidth usage.

Benefits of technology

It improves the data authentication effect, reduces bandwidth usage, and improves the system's data transmission efficiency.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN115766118B_ABST
    Figure CN115766118B_ABST
Patent Text Reader

Abstract

The present invention provides a data authentication method, apparatus and computer device. The method includes obtaining a sending device of currently received data; determining whether the sending device has data sending permission based on pre-stored device permission information; if the sending device does not have device sending permission, then not performing an operation corresponding to the currently received data. The data authentication method provided by the present invention can determine the reporting permission of data based on the device that issues the data, so as to avoid the invalid transmission of unauthorized data, reduce the occupancy of bandwidth, and improve the data transmission efficiency of the system.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of communication technologies, and particularly to a data authentication method, apparatus, and computer device. Background Art

[0002] In the communication process of smart homes, each smart device can report data through the Message Queuing Telemetry Transport (MQTT) protocol. This protocol is an instant messaging protocol that can provide inter-device communication using the publish / subscribe method. The MQTT protocol supports all platforms, can connect various wireless network devices to external devices, and is suitable for remote transmitters and control devices with limited computing power and operating on low-bandwidth or unreliable networks.

[0003] Existing MQTT proxy servers can perform authentication processing and incremental processing on the reported data, but the data authentication effect is not good, and the server still faces a large transmission pressure. Summary of the Invention

[0004] To solve the problem of poor data authentication effect in the existing smart home communication process, this application provides a data authentication method, apparatus, and computer device, which can improve the data authentication effect and reduce bandwidth occupancy.

[0005] On the one hand, a data authentication method is provided. The method includes:

[0006] Obtain the sending device of the currently received data;

[0007] Based on the pre-stored device permission information, determine whether the sending device has the data sending permission;

[0008] If the sending device does not have the device sending permission, do not perform the operation corresponding to the currently received data.

[0009] In some embodiments, after determining whether the sending device has the data sending permission based on the pre-stored device permission information, the method further includes:

[0010] Based on the pre-stored account and / or password, determine whether the sending device of the currently received information has the data sending permission;

[0011] Determine whether the currently received data meets the pre-stored data format requirements;

[0012] If the sending device does not have the device sending permission and / or the currently received data does not meet the data format requirements, do not perform the operation corresponding to the currently received data.

[0013] In some embodiments, after determining whether the sending device has the data sending permission based on the pre-stored device permission information, the method further includes:

[0014] Determine whether the current received data contains target device information;

[0015] If the current received data does not contain the target device information, do not perform the operation corresponding to the current received data.

[0016] In some embodiments, the method further includes:

[0017] Obtain the data category of the current received data;

[0018] Determine the incremental data corresponding to the current received data based on the data category;

[0019] Generate sending data based on the current received data and the incremental data, and send out the sending data.

[0020] In some embodiments, before obtaining the incremental data corresponding to the current received data, the method further includes:

[0021] Determine the incremental data corresponding to the data category based on the historical data of the data category.

[0022] On the other hand, a data authentication device is provided, and the device includes:

[0023] A device acquisition module, configured to acquire the sending device of the current received data;

[0024] A first permission judgment module, configured to judge whether the sending device has the data sending permission based on the pre-stored device permission information; if the sending device does not have the device sending permission, do not perform the operation corresponding to the current received data.

[0025] In some embodiments, the data authentication device further includes:

[0026] A second permission judgment module, configured to judge whether the sending device of the current received information has the data sending permission based on the pre-stored account number and / or password;

[0027] A third permission judgment module, configured to judge whether the current received data meets the pre-stored data format requirements;

[0028] If the sending device does not have the device sending permission and / or the current received data does not meet the data format requirements, do not perform the operation corresponding to the current received data.

[0029] In some embodiments, the data authentication device further includes:

[0030] A fourth permission determination module, configured to determine whether the currently received data includes target device information;

[0031] If the currently received data does not include the target device information, the operation corresponding to the currently received data is not executed.

[0032] In some embodiments, the data authentication device provided by the present invention may further include:

[0033] Obtain the data category of the currently received data;

[0034] Determine the incremental data corresponding to the currently received data based on the data category;

[0035] An incremental module, configured to generate transmission data based on the currently received data and the incremental data, and send out the transmission data.

[0036] In some embodiments, the data authentication device provided by the present invention may further include:

[0037] An incremental data determination module, configured to determine the incremental data corresponding to the data category based on the historical data of the data category.

[0038] On the other hand, a computer device is provided, which includes a processor and a memory. At least one instruction, at least one program, a code set or an instruction set is stored in the memory. The processor can load and execute at least one instruction, at least one program, a code set or an instruction set to implement the data authentication method provided in the above application embodiments.

[0039] On the other hand, a computer-readable storage medium is provided. At least one instruction, at least one program, a code set or an instruction set is stored in the readable storage medium. The processor can load and execute at least one instruction, at least one program, a code set or an instruction set to implement the data authentication method provided in the above embodiments of the present application.

[0040] On the other hand, a computer program product or a computer program is provided. The computer program property right or the computer program includes computer program instructions, and the computer program instructions are stored in a computer-readable storage medium. The processor reads the computer instructions from the computer-readable storage medium and executes the computer instructions, so that the computer device executes the data authentication method described in any one of the above embodiments.

[0041] The beneficial effects brought by the technical solution provided in this application at least include: The embodiments of the present invention provide a data authentication method, device, and computer device. The method includes obtaining the sending device of the currently received data; determining whether the sending device has the data sending permission based on the pre-stored device permission information; if the sending device does not have the device sending permission, then do not perform the operation corresponding to the currently received data. The method provided by the embodiments of the present invention can determine the reporting permission of data based on the device that issues the data, so as to avoid the invalid transmission of unauthorized data, reduce the occupancy of bandwidth, and improve the data transmission efficiency of the system. BRIEF DESCRIPTION OF THE DRAWINGS

[0042] In order to more clearly illustrate the technical solutions in the embodiments of the present application, the following will briefly introduce the drawings required for the description of the embodiments. Obviously, the following drawings are only some embodiments of the present application. For those of ordinary skill in the art, without creative efforts, other drawings can also be obtained based on these drawings.

[0043] Figure 1 It shows a schematic flowchart of the implementation of a data authentication method provided by an exemplary embodiment of the present application;

[0044] Figure 2 It shows another schematic flowchart of the implementation of a data authentication method provided by an exemplary embodiment of the present application;

[0045] Figure 3 It shows yet another schematic flowchart of the implementation of a data authentication method provided by an exemplary embodiment of the present application;

[0046] Figure 4 It shows the structure diagram of a data authentication device provided by an exemplary embodiment of the present application;

[0047] Figure 5 It shows the structure diagram of a computer device corresponding to a data authentication method provided by an exemplary embodiment of the present application. DETAILED DESCRIPTION OF THE EMBODIMENTS

[0048] To make the objectives, technical solutions, and advantages of the present application clearer, the following will further describe the embodiments of the present application in detail in conjunction with the drawings.

[0049] The data authentication method provided by the present application can improve the data authentication effect and reduce the bandwidth occupancy.

[0050] To make the objectives, technical solutions, and advantages of this application clearer, the following will further describe this application in detail in conjunction with the accompanying drawings. The described embodiments should not be construed as limitations on this application. All other embodiments obtained by those of ordinary skill in the art without creative efforts fall within the scope of protection of this application.

[0051] In the following description, reference is made to "some embodiments", which describe a subset of all possible embodiments. However, it can be understood that "some embodiments" can be the same subset or different subsets of all possible embodiments and can be combined with each other without conflict.

[0052] If similar descriptions such as "first / second / third" appear in the application documents, the following explanation is added. In the following description, the terms "first / second / third" are merely used to distinguish similar objects and do not represent a specific order for the objects. It can be understood that "first / second / third" can be interchanged with a specific order or sequence when permitted, so that the embodiments of this application described here can be implemented in an order other than that illustrated or described here.

[0053] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as commonly understood by those of ordinary skill in the technical field to which this application belongs. The terms used herein are only for the purpose of describing the embodiments of this application and are not intended to limit this application.

[0054] Embodiment 1

[0055] Figure 1 It shows a schematic implementation flow diagram of a data authentication method provided by an embodiment of the present invention.

[0056] See Figure 1 , the data authentication method provided by the embodiment of the present invention may include steps 101 to 103.

[0057] Optionally, the method provided by the embodiment of the present invention is applied to a smart home device.

[0058] Step 101: Obtain the sending device of the currently received data.

[0059] In some embodiments, the currently received data includes corresponding sending device information.

[0060] In a specific example, the data authentication method provided by the embodiments of the present invention can be applied to the central control system of a smart home. The sending device that currently receives data can include, but is not limited to, the user's mobile terminal. Correspondingly, the currently received data is various control instructions issued by the user. The user's mobile terminal can include, but is not limited to, mobile phones, tablet computers, remote controls for various smart devices, etc. On the other hand, the sending device that currently receives data can include various smart home devices used by the user, such as air conditioners, air purifiers, kitchen appliances, various audio-visual devices, various lighting systems, etc. Correspondingly, the currently received data is the information fed back by the smart home device to the user.

[0061] In a smart home system, the methods of access and information interaction are mainly divided into four categories: WiFi, ZigBee, Bluetooth, and universal remote control; corresponding to four types of gateway devices: routers (WiFi gateways), ZigBee gateways, Bluetooth gateways, and universal remote controls. There are two ways for ordinary household appliances to access home intelligence. One is a smart socket, provided that the household appliance supports starting when powered on; the other is a universal remote control, provided that the household appliance supports infrared / RF remote control.

[0062] Step 102: Determine whether the sending device has the data sending permission based on the pre-stored device permission information.

[0063] In a specific example, multiple device information, including but not limited to information identifiers such as device models and device names, are pre-stored on a Message Queuing Telemetry Transport (MQTT) broker server for identification.

[0064] The MQTT broker server is an instant messaging protocol developed by IBM and can connect Internet of Things devices and the external world as an important part of the Internet of Things. This type of communication protocol needs to continuously poll to obtain real-time data and has the following main characteristics: uses the publish / subscribe message mode, provides one-to-many message publishing, and decouples application programs; message transmission with payload content shielding; uses TCP / IP to provide network connections; has three message publishing service qualities: small transmission, very low overhead (the fixed-length header is 2 bytes), protocol exchange minimization, which can reduce network traffic; and a mechanism that can notify all parties of abnormal client interruptions.

[0065] In some embodiments, during a certain data exchange process, the devices with data sending permissions can be determined according to the tasks of the current smart home system and the pre-stored device permission information corresponding to various tasks.

[0066] Step 103: If the sending device does not have the device sending permission, do not execute the operation corresponding to the currently received data.

[0067] In some embodiments, the server pre-stores devices with permissions. When the server receives a reported instruction, it first authenticates the device that sent the instruction. If the device has no instruction permission, the instruction is not executed. If the device has instruction permission, the instruction is further judged.

[0068] In a specific example, the same field content stored in the MQTT broker server includes, but is not limited to, the same information such as public keys. For example, the air conditioner device pre-stores the field information of the same instruction in advance and identifies it through the device model after receiving the instruction to extract the information.

[0069] In some embodiments, after step 102, the method may further include:

[0070] Judging whether the sending device of the currently received information has data sending permission based on the pre-stored account number and / or password;

[0071] Judging whether the currently received data meets the pre-stored data format requirements;

[0072] If the sending device does not have device sending permission and / or the currently received data does not meet the data format requirements, the operation corresponding to the currently received data is not executed.

[0073] The authentication process can usually be implemented based on the user name and password. The method provided in the embodiments of the present invention uses the user name, password, and message to implement authentication.

[0074] Specifically, the user name and password are returned by calling the interface service request, and both the user name and password have timeliness. At the same time, the request to call the interface uses parameter encryption for authentication to further ensure the security and reliability of the interface.

[0075] Optionally, by presetting different accounts and the fixed message content that each account can publish, the permissions of each account are determined.

[0076] Specifically, message authentication refers to authenticating the message title and message content format. The message title should contain the device information corresponding to the user, and the message content should meet the format requirements specified by the protocol. Otherwise, the message is not allowed to be sent.

[0077] The method provided in the embodiments of the present invention combines the account number, password, and message to determine whether the sending device of the currently received message has data sending permission, which can improve the effectiveness and reliability of the judgment of the sending device's permission and avoid invalid data occupying the transmission bandwidth.

[0078] In some embodiments, after step 102, the method may further include:

[0079] Determine whether the currently received data contains target device information;

[0080] If the currently received data does not contain the target device information, do not perform the operation corresponding to the currently received data.

[0081] In some embodiments, in addition to not performing the operation corresponding to the currently received data, the method may further include instructing the proxy server to clear the instruction information.

[0082] In some embodiments, after the authentication operation, an incremental operation may be further performed on the data, that is, pre-stored general and fixed data is added to the currently received data, rather than carrying this data in each data transmission, thereby further reducing the data transmission volume.

[0083] In some embodiments, the method may further include:

[0084] Obtain the data category of the currently received data;

[0085] Determine the incremental data corresponding to the currently received data based on the data category;

[0086] Generate transmission data based on the currently received data and the incremental data, and send out the transmission data.

[0087] The transmission form of the incremental data is usually to upload the full amount of data for the first time, and only upload the incremental data subsequently.

[0088] In some embodiments, before obtaining the incremental data corresponding to the currently received data, the method further includes:

[0089] Determine the incremental data corresponding to the data category based on the historical data of the data category.

[0090] In some embodiments, the incremental operation is that the proxy server pre-stores the same field information between instructions. After the device reports an instruction to the proxy server, the server sends the pre-stored fields and the instruction content to the MQTT server to reduce the bandwidth occupancy.

[0091] Specifically, the incremental processing includes adding fixed content. For example, each time information is transmitted, the current message content is saved to the database. When a new message comes in, the new message content is compared with the message content stored in the database, and only the changed content is modified. Finally, the integrated message content is sent out, thereby reducing the bandwidth occupancy.

[0092] Based on the above incremental operation, it is possible to transmit only the minimum amount of data in each data transmission without transmitting duplicate content, so as to further reduce the bandwidth occupancy and improve the data transmission efficiency.

[0093] The method provided by the embodiment of the present invention performs authentication and incremental processing on the data reported by each device by setting up a proxy server, packs and stores the instructions sent by the device based on the device permissions, and packs and sends the new and old instructions to the MQTT server together. Only necessary information is transmitted in the above process, which can effectively reduce the bandwidth occupancy.

[0094] Embodiment Two

[0095] Figure 2 It shows another implementation process schematic diagram of the data authentication method provided by the embodiment of the present invention.

[0096] See Figure 2 , in some embodiments, the process of device authentication is as follows.

[0097] First, the server stores the permission information of each device.

[0098] Specifically, the MQTT server will store in advance the permission information for the device to receive instructions and the information prohibiting the receipt of certain instructions according to the identification such as the device model.

[0099] When the device reports an instruction, the MQTT proxy server determines whether the device has permission.

[0100] Specifically, after an instruction is reported, it will first be determined whether the device has the permission to execute the instruction. After the proxy server processes it, the instruction reporting operation will be carried out. By performing the authentication operation on the instruction, the certainty of the instruction transmission can be ensured and the waste of bandwidth resources can be reduced.

[0101] If the device reporting the instruction has permission, the MQTT processes the instruction; if the device reporting the instruction has no right, the proxy server clears the instruction information.

[0102] Figure 3 It shows another implementation process schematic diagram of the data authentication method provided by the embodiment of the present invention.

[0103] See Figure 3 , in some embodiments, the process of device increment is as follows.

[0104] First, the device sends instruction information.

[0105] The proxy server stores the field information with the same instructions according to the device characteristics.

[0106] Specifically, the MQTT proxy server classifies and stores the information by the device model, such as product information of air conditioner category, water purifier category, etc.

[0107] Optionally, information is classified and stored using the device fixed identifier, and the reported information of the same instruction fields for devices in each category is stored in advance in the proxy server. Optionally, the reported information of the same instruction fields includes, but is not limited to, the same information such as the public key and the basic category.

[0108] The proxy server receives an instruction and finds the information of the same fields according to features such as the device mac.

[0109] The pre-stored information of the same fields is packaged together and sent to the MQTT server.

[0110] Specifically, the new instruction only needs to carry the necessary information. After the new instruction is sent to the proxy server, the pre-stored information of the same instruction is extracted according to the device model and packaged with the new instruction information and sent to the MQTT server to reduce the bandwidth occupancy.

[0111] In a specific example, the server sends instructions such as turning on / off and temperature adjustment to the air conditioner device.

[0112] Optionally, the product model included in the air conditioner device and the sending method of the instruction, such as the request field before the instruction, are stored in advance in the database.

[0113] When the new instruction arrives, it is compared with the pre-stored data, and the same fields can be not transmitted to reduce the bandwidth consumption. The same fields can include, but are not limited to, the device model, the request request, etc.

[0114] Optionally, the pre-stored data can be the data input in advance or the data of the previous instruction.

[0115] In summary, the data authentication method provided by the embodiments of the present invention can authenticate various messages and instructions, thereby effectively implementing screening, reducing the amount of data transmission, and reducing the bandwidth occupancy.

[0116] Embodiment III

[0117] Figure 4 The structural schematic diagram of the data authentication device provided by the embodiments of the present invention is shown.

[0118] See Figure 4 , the data authentication device provided by the embodiments of the present invention may include:

[0119] The device acquisition module 201 is used to acquire the sending device of the currently received data;

[0120] The first permission judgment module 202 is used to judge whether the sending device has the data sending permission based on the pre-stored device permission information; if the sending device does not have the device sending permission, the operation corresponding to the currently received data is not executed.

[0121] In some embodiments, the data authentication device further includes:

[0122] A second permission determination module, configured to determine whether the sending device of the currently received information has the data sending permission based on the pre-stored account number and / or password;

[0123] A third permission determination module, configured to determine whether the currently received data meets the pre-stored data format requirements;

[0124] If the sending device does not have the device sending permission and / or the currently received data does not meet the data format requirements, the operation corresponding to the currently received data is not executed.

[0125] In some embodiments, the data authentication device further includes:

[0126] A fourth permission determination module, configured to determine whether the currently received data contains the target device information;

[0127] If the currently received data does not contain the target device information, the operation corresponding to the currently received data is not executed.

[0128] In some embodiments, the data authentication device provided by the present invention may further include:

[0129] Obtain the data category of the currently received data;

[0130] Based on the data category, determine the incremental data corresponding to the currently received data;

[0131] An incremental module, configured to generate sending data based on the currently received data and the incremental data, and send out the sending data.

[0132] In some embodiments, the data authentication device provided by the present invention may further include:

[0133] An incremental data determination module, configured to determine the incremental data corresponding to the data category based on the historical data of the data category.

[0134] In summary, the data authentication device provided by the embodiments of the present invention can authenticate various types of messages and instructions, thereby effectively realizing screening, reducing the data transmission volume, and reducing the bandwidth occupancy.

[0135] Embodiment 4

[0136] Figure 5 The schematic structural diagram of a computer device provided by an exemplary embodiment of the present application is shown. The computer device includes:

[0137] The processor 301 includes one or more processing cores. The processor 301 executes various functional applications and data processing by running software programs and modules.

[0138] The receiver 302 and the transmitter 303 can be implemented as a communication component, and the communication component can be a communication chip. Optionally, the communication component can be implemented to include a signal transmission function. That is, the transmitter 303 can be used to transmit control signals to the image acquisition device and the scanning device, and the receiver 302 can be used to receive corresponding feedback instructions.

[0139] The memory 304 is connected to the processor 301 through the bus 305.

[0140] The memory 304 can be used to store at least one instruction, and the processor 301 is used to execute the at least one instruction to implement steps 101 to 103 in the data authentication method embodiment described above.

[0141] Step 101: Obtain the sending device of the currently received data;

[0142] Step 102: Determine whether the sending device has the data sending permission based on the pre-stored device permission information;

[0143] Step 103: If the sending device does not have the device sending permission, do not perform the operation corresponding to the currently received data.

[0144] In some embodiments, after determining whether the sending device has the data sending permission based on the pre-stored device permission information, the method further includes:

[0145] Determine whether the sending device of the currently received information has the data sending permission based on the pre-stored account and / or password;

[0146] Determine whether the currently received data meets the pre-stored data format requirements;

[0147] If the sending device does not have the device sending permission and / or the currently received data does not meet the data format requirements, do not perform the operation corresponding to the currently received data.

[0148] In some embodiments, after determining whether the sending device has the data sending permission based on the pre-stored device permission information, the method further includes:

[0149] Determine whether the currently received data contains the target device information;

[0150] If the currently received data does not contain the target device information, do not perform the operation corresponding to the currently received data.

[0151] In some embodiments, the method further includes:

[0152] Obtaining the data category of the currently received data;

[0153] Determining the incremental data corresponding to the currently received data based on the data category;

[0154] Generating transmission data based on the currently received data and the incremental data, and sending out the transmission data.

[0155] In some embodiments, before obtaining the incremental data corresponding to the currently received data, the method further includes:

[0156] Determining the incremental data corresponding to the data category based on the historical data of the data category.

[0157] Those skilled in the art can understand that Figure 5 merely examples of computer devices, which do not constitute a limitation on computer devices, may include more or fewer components than shown in the figure, or combine certain components, or different components. For example, the computer device may further include a network access device, etc.

[0158] The so-called processor 301 may be a central processing unit (CPU), or may also be other general-purpose processors, digital signal processors (DSPs), application-specific integrated circuits (ASICs), off-the-shelf programmable gate arrays (FPGAs), or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. The general-purpose processor may be a microprocessor or the processor may also be any conventional processor, etc.

[0159] The memory 304 may be an internal storage unit of the computer device, such as the hard disk or memory of the computer device. The memory 304 may also be an external storage device of the computer device, such as a plug-in hard disk equipped on the computer device, a Smart Media Card (SMC), a Secure Digital (SD) card, a Flash Card, etc. Further, the memory 304 may also include both the internal storage unit and the external storage device of the computer device. The memory 304 is used to store the computer program and other programs and data required by the terminal device. The memory 304 may also be used to temporarily store the data that has been output or will be output.

[0160] Embodiment Five

[0161] An embodiment of the present invention provides a smart home device, including the computer device as described above.

[0162] In some embodiments, the smart home device may include, but is not limited to, an air conditioning device, an air purifier device, a display device, an audio device, etc., where the display device may include, but is not limited to, at least one of a display, a projector, and a television device.

[0163] Embodiment Six

[0164] An embodiment of the present application also provides a computer-readable storage medium, in which at least one instruction, at least one segment of program, a code set or an instruction set is stored, to be loaded and executed by a processor to implement the above data authentication method.

[0165] The data authentication method includes:

[0166] Step 101: Obtain the sending device of the currently received data;

[0167] Step 102: Determine whether the sending device has the data sending permission based on the pre-stored device permission information;

[0168] Step 103: If the sending device does not have the device sending permission, do not perform the operation corresponding to the currently received data.

[0169] In some embodiments, after determining whether the sending device has the data sending permission based on the pre-stored device permission information, the method further includes:

[0170] Determine whether the sending device of the currently received information has the data sending permission based on the pre-stored account and / or password;

[0171] Determine whether the currently received data meets the pre-stored data format requirements;

[0172] If the sending device does not have the device sending permission and / or the current received data does not meet the data format requirements, the operation corresponding to the current received data is not executed.

[0173] In some embodiments, after determining whether the sending device has the data sending permission based on the pre-stored device permission information, the method further includes:

[0174] Determine whether the current received data contains the target device information;

[0175] If the current received data does not contain the target device information, the operation corresponding to the current received data is not executed.

[0176] In some embodiments, the method further includes:

[0177] Obtain the data category of the current received data;

[0178] Determine the incremental data corresponding to the current received data based on the data category;

[0179] Generate sending data based on the current received data and the incremental data, and send out the sending data.

[0180] In some embodiments, before obtaining the incremental data corresponding to the current received data, the method further includes:

[0181] Determine the incremental data corresponding to the data category based on the historical data of the data category.

[0182] Optionally, the computer-readable storage medium may include: read-only memory (ROM, Read Only Memory), random access memory (RAM, Random Access Memory), solid state drive (SSD, Solid State Drives), or optical disc, etc. Among them, the random access memory may include resistive random access memory (ReRAM, Resistance Random Access Memory) and dynamic random access memory (DRAM, Dynamic Random Access Memory).

[0183] Embodiment Seven

[0184] The present application also provides a computer program product or a computer program. The computer program product or the computer program includes computer instructions, and the computer instructions are stored in a computer-readable storage medium. A processor of a computer device reads the computer instructions from the computer-readable storage medium, and the processor executes the computer instructions, so that the computer device executes the data authentication method described in any one of the foregoing embodiments.

[0185] The data authentication method includes:

[0186] Step 101: Obtain the sending device of the currently received data;

[0187] Step 102: Based on pre-stored device permission information, determine whether the sending device has the data sending permission;

[0188] Step 103: If the sending device does not have the device sending permission, do not perform the operation corresponding to the currently received data.

[0189] In some embodiments, after determining whether the sending device has the data sending permission based on the pre-stored device permission information, the method further includes:

[0190] Based on pre-stored account numbers and / or passwords, determine whether the sending device of the currently received information has the data sending permission;

[0191] Determine whether the currently received data meets the pre-stored data format requirements;

[0192] If the sending device does not have the device sending permission and / or the currently received data does not meet the data format requirements, do not perform the operation corresponding to the currently received data.

[0193] In some embodiments, after determining whether the sending device has the data sending permission based on the pre-stored device permission information, the method further includes:

[0194] Determine whether the currently received data contains target device information;

[0195] If the currently received data does not contain the target device information, do not perform the operation corresponding to the currently received data.

[0196] In some embodiments, the method further includes:

[0197] Obtain the data category of the currently received data;

[0198] Based on the data category, determine the incremental data corresponding to the currently received data;

[0199] Generate sending data based on the currently received data and the incremental data, and send out the sending data.

[0200] In some embodiments, before obtaining the incremental data corresponding to the currently received data, the method further includes:

[0201] Determining the incremental data corresponding to the data category based on the historical data of the data category.

[0202] The serial numbers of the embodiments of the present application above are only for description and do not represent the advantages or disadvantages of the implementation.

[0203] Those skilled in the art can clearly understand that for the convenience and brevity of description, only the above-mentioned division of each functional unit and module is used as an example. In actual applications, the above functions can be allocated to different functional units and modules according to needs, that is, the internal structure of the device is divided into different functional units or modules to complete all or part of the functions described above. Each functional unit and module in the embodiment can be integrated into a processing unit, or each unit can exist physically alone, or two or more units can be integrated into one unit. The above-mentioned integrated unit can be implemented in the form of hardware or in the form of a software functional unit. In addition, the specific names of each functional unit and module are only for the convenience of mutual distinction and do not limit the protection scope of the present application. The specific working processes of the units and modules in the above system can refer to the corresponding processes in the foregoing method embodiments and will not be elaborated herein.

[0204] In the above embodiments, the descriptions of the respective embodiments have their own emphases. For parts not detailed or recorded in a certain embodiment, reference can be made to the relevant descriptions of other embodiments.

[0205] Those of ordinary skill in the art can realize that the units and algorithm steps of the examples described in combination with the embodiments disclosed herein can be implemented by electronic hardware, or by a combination of computer software and electronic hardware. Whether these functions are executed in a hardware or software manner depends on the specific application and design constraints of the technical solution. Professional technicians can use different methods to implement the described functions for each specific application, but such implementation should not be considered to exceed the scope of the present invention.

[0206] In the embodiments provided by the present invention, it should be understood that the disclosed device / terminal device and method can be implemented in other ways. For example, the device / terminal device embodiments described above are merely illustrative. For example, the division of the modules or units is only a logical function division. In actual implementation, there may be other division methods. For example, multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the displayed or discussed coupling or direct coupling or communication connection to each other can be through some interfaces. The indirect coupling or communication connection of the device or unit can be in electrical, mechanical or other forms.

[0207] The units described as separate components may or may not be physically separated. The components displayed as units may or may not be physical units, that is, they can be located in one place or distributed to multiple network units. Some or all of the units can be selected according to actual needs to achieve the purpose of the solution of this embodiment.

[0208] In addition, each functional unit in various embodiments of the present invention can be integrated in a processing unit, or each unit can exist physically alone, or two or more units can be integrated in one unit. The above integrated units can be implemented in the form of hardware or in the form of software functional units.

[0209] If the integrated module / unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, to implement all or part of the processes in the above method embodiments of the present invention, it can also be completed by a computer program instructing related hardware. The computer program can be stored in a computer-readable storage medium. When the computer program is executed by a processor, the steps of the above method embodiments can be implemented.

[0210] Among them, the computer program includes computer program code, and the computer program code can be in the form of source code, object code, executable file or some intermediate form, etc. The computer-readable medium may include: any entity or device capable of carrying the computer program code, recording medium, USB flash drive, mobile hard disk, magnetic disk, optical disc, computer memory, read-only memory (ROM), random access memory (RAM), electrical carrier signal, telecommunication signal, and software distribution medium, etc. It should be noted that the content included in the computer-readable medium can be appropriately increased or decreased according to the requirements of legislation and patent practice within the jurisdiction. For example, in some jurisdictions, according to legislation and patent practice, the computer-readable medium does not include electrical carrier signals and telecommunication signals.

[0211] The above-described embodiments are only used to illustrate the technical solutions of the present invention, rather than to limit them; although the present invention has been described in detail with reference to the foregoing embodiments, those of ordinary skill in the art should understand that they can still modify the technical solutions recorded in the foregoing embodiments, or perform equivalent replacements for some of the technical features; and these modifications or replacements do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the embodiments of the present invention, and should all be included in the protection scope of the present invention.

Claims

1. A data authentication method, characterized in that, The method includes: Obtain the sending device of the currently received data; Based on the pre-stored device permission information, determine whether the sending device has the data sending permission; If the sending device does not have the device sending permission, do not perform the operation corresponding to the currently received data; After determining whether the sending device has the data sending permission based on the pre-stored device permission information, the method further includes: Based on the pre-stored account number and / or password, determine whether the sending device of the currently received data has the data sending permission; Determine whether the currently received data meets the pre-stored data format requirements; If the sending device does not have the device sending permission and / or the currently received data does not meet the data format requirements, do not perform the operation corresponding to the currently received data; After determining that the sending device has the data sending permission, it further includes: Obtain the data category of the currently received data; Based on the data category, determine the incremental data corresponding to the currently received data; Generate sending data based on the currently received data and the incremental data, and send out the sending data; Wherein, the account number and the password are returned by calling the interface service request, and both the account number and the password have timeliness, and at the same time, the request to call the interface uses parameter encryption for authentication; the currently received data does not meet the data format requirements includes: the message title in the currently received data does not contain the target device information, and / or the message content does not meet the format requirements specified by the preset protocol; Each time information is transmitted, save the current message content to the database. Generating the sending data based on the currently received data and the incremental data includes: when a new message comes in again, compare the new message content with the message content stored in the database, and only modify the changed content to obtain the sending data.

2. The method according to claim 1, wherein After determining whether the sending device has the data sending permission based on the pre-stored device permission information, the method further includes: Determine whether the currently received data contains the target device information; If the currently received data does not contain the target device information, do not perform the operation corresponding to the currently received data.

3. The method according to claim 1, characterized in that Before obtaining the incremental data corresponding to the currently received data, the method further includes: Based on the historical data of the data category, determine the incremental data corresponding to the data category.

4. A data authentication device, characterized in that, The device includes: A device acquisition module, configured to obtain the sending device of the currently received data; A first permission judgment module, configured to determine whether the sending device has the data sending permission based on the pre-stored device permission information; if the sending device does not have the device sending permission, do not perform the operation corresponding to the currently received data; The data authentication device further includes: A second permission judgment module, configured to determine whether the sending device of the currently received data has the data sending permission based on the pre-stored account number and / or password; A third permission determination module, configured to determine whether the currently received data meets the requirements of a pre-stored data format; if the sending device does not have the device sending permission and / or the currently received data does not meet the data format requirements, the operation corresponding to the currently received data is not executed; After determining that the sending device has the data sending permission, the data authentication device is further configured to: Obtain the data category of the currently received data; Determine the incremental data corresponding to the currently received data based on the data category; Generate sending data based on the currently received data and the incremental data, and send out the sending data; Wherein, the account and the password are returned by invoking an interface service request, and both the account and the password have timeliness, and at the same time, the request to invoke the interface uses parameter encryption for authentication; the currently received data not meeting the data format requirements includes: the message title in the currently received data does not contain the target device information, and / or the message content does not meet the format requirements specified by a preset protocol; Each time information is transmitted, the current message content is saved to a database. The generating of the sending data based on the currently received data and the incremental data includes: when a new message comes in again, comparing the new message content with the message content stored in the database, and only modifying the changed content to obtain the sending data.

5. A computer device, characterized in that, The computer device includes a processor and a memory. At least one instruction, at least one program, a code set or an instruction set is stored in the memory, and the at least one instruction, at least one program, the code set or the instruction set is loaded and executed by the processor to implement the data authentication method according to any one of claims 1 to 3.

6. A smart home device, characterized in that, Including the computer device according to claim 5.

7. A computer-readable storage medium, characterized in that, At least one instruction, at least one program, a code set or an instruction set is stored in the readable memory medium, and the at least one instruction, at least one program, the code set or the instruction set is loaded and executed by a processor to implement the data authentication method according to any one of claims 1 to 3.

Citation Information

Patent Citations

  • Device authentication method and device, and machine readable medium

    CN109474916A

  • MQTT-based intelligent home gateway terminal device and local authentication remote service method

    CN110245032A

  • Message processing method and device, Internet of Things system and storage medium

    CN111371889A