CN108322303A - A kind of data transmission method - Google Patents

A kind of data transmission method Download PDF

Info

Publication number
CN108322303A
CN108322303A CN201711291919.0A CN201711291919A CN108322303A CN 108322303 A CN108322303 A CN 108322303A CN 201711291919 A CN201711291919 A CN 201711291919A CN 108322303 A CN108322303 A CN 108322303A
Authority
CN
China
Prior art keywords
data
secret key
encryption
encrypted
data transmission
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN201711291919.0A
Other languages
Chinese (zh)
Inventor
杨玄
张水华
张展
冯勇强
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Ximo Inc
Original Assignee
Ximo Inc
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Ximo Inc filed Critical Ximo Inc
Priority to CN201711291919.0A priority Critical patent/CN108322303A/en
Publication of CN108322303A publication Critical patent/CN108322303A/en
Pending legal-status Critical Current

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L9/00Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols
    • H04L9/06Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols the encryption apparatus using shift registers or memories for block-wise or stream coding, e.g. DES systems or RC4; Hash functions; Pseudorandom sequence generators
    • H04L9/0618Block ciphers, i.e. encrypting groups of characters of a plain text message using fixed encryption transformation
    • H04L9/0631Substitution permutation network [SPN], i.e. cipher composed of a number of stages or rounds each involving linear and nonlinear transformations, e.g. AES algorithms
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L63/00Network architectures or network communication protocols for network security
    • H04L63/04Network architectures or network communication protocols for network security for providing a confidential data exchange among entities communicating through data packet networks
    • H04L63/0428Network architectures or network communication protocols for network security for providing a confidential data exchange among entities communicating through data packet networks wherein the data content is protected, e.g. by encrypting or encapsulating the payload
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L9/00Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols
    • H04L9/06Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols the encryption apparatus using shift registers or memories for block-wise or stream coding, e.g. DES systems or RC4; Hash functions; Pseudorandom sequence generators
    • H04L9/0618Block ciphers, i.e. encrypting groups of characters of a plain text message using fixed encryption transformation
    • H04L9/0625Block ciphers, i.e. encrypting groups of characters of a plain text message using fixed encryption transformation with splitting of the data block into left and right halves, e.g. Feistel based algorithms, DES, FEAL, IDEA or KASUMI

Abstract

The present invention provides a kind of data transmission methods, encryption secret key is obtained by the first encryption method, then the encrypted encryption secret key of first encryption method is recycled, transmission is encrypted in the data transmitted to needs according to the second encryption method, that is, in intelligent home network, make control in intelligence, operation and the application program on user terminal and between high in the clouds, data are transmitted between above-mentioned three with ciphertext, data are encrypted using two kinds of encryption methods, further improve the safety of data.

Description

A kind of data transmission method
Technical field
This specification is related to smart home field more particularly to a kind of data transmission method.
Background technology
The data in smart machine in transmission process need that the data of transmission are encrypted at present.Specifically, data Sender is encrypted data with an encryption method, and for data receiver after receiving encrypted data, use is same Encryption method is decrypted, since encrypted method is single, the safety of data is not high enough.
Based on the prior art, there is an urgent need for a kind of higher data transmission methods of safety.
Invention content
This specification embodiment provides a kind of data transmission method, to improve the safety of data transmission in the prior art Property.
In order to solve the above technical problems, what this specification embodiment was realized in:
The present invention provides a kind of data transmission method, the data transmission in the network formed for smart home device, Including:
Generate plaintext secret key;
According to the plaintext secret key, encryption secret key is obtained by the first encryption method;
According to the second encryption method, needs the data transmitted to be encrypted with the encryption secret key pair, send out encrypted Data.
Preferably, it in above-mentioned data transmission method, according to the plaintext secret key, is obtained and is added by the first encryption method Close secret key, including:
The plaintext secret key is encrypted using first encryption method, obtains pre-encrypt secret key;
The data of presetting digit capacity are obtained from the pre-encrypt secret key;
According to the data of the presetting digit capacity, the encryption secret key is obtained.
Preferably, in above-mentioned data transmission method, first encryption method includes base64 Encryption Algorithm.
Preferably, in above-mentioned data transmission method, the presetting digit capacity is 2NPosition;
The data that presetting digit capacity is obtained from the pre-encrypt secret key, including:
2 are obtained from the pre-encrypt secret keyNPosition data, wherein N is the integer more than or equal to 6.
Preferably, in above-mentioned data transmission method, second encryption method includes AES encryption method.
The present invention provides a kind of data transmission methods, including:
Data sending terminal is encrypted using encryption secret key with the data that the second encryption method transmits needs, and is sent and added Data after close, wherein the encryption secret key is to encrypt to obtain by the first encryption method;
Data receiver after receiving encrypted data, using encrypted data described in the encryption secret key pair into Row decryption.
Preferably, in above-mentioned data transmission method, data sending terminal obtains the process of encryption secret key, including:
Generate plaintext secret key;
The plaintext secret key is encrypted using first encryption method, obtains pre-encrypt secret key;
The data of presetting digit capacity are obtained from the pre-encrypt secret key;
According to the data of the presetting digit capacity, the encryption secret key is obtained.
Preferably, in above-mentioned data transmission method, first encryption method includes base64 Encryption Algorithm.
Preferably, in above-mentioned data transmission method, the presetting digit capacity is 2NPosition;
The data that presetting digit capacity is obtained from the pre-encrypt secret key, including:
2 are obtained from the pre-encrypt secret keyNPosition data, wherein N is the integer more than or equal to 6.
Preferably, in above-mentioned data transmission method, second encryption method includes AES encryption method.
The present invention provides a kind of data transmission method, encryption secret key is obtained by the first encryption method, it is then sharp again With the encrypted encryption secret key of first encryption method, biography is encrypted in the data transmitted to needs according to the second encryption method It is defeated, that is to say, that in intelligent home network, make in intelligence control, run with user terminal on application program and high in the clouds it Between, data are transmitted between above-mentioned three with ciphertext, are encrypted, are further increased to data using two kinds of encryption methods The safeties of data.
Description of the drawings
In order to illustrate more clearly of this specification embodiment or technical solution in the prior art, below will to embodiment or Attached drawing needed to be used in the description of the prior art is briefly described, it should be apparent that, the accompanying drawings in the following description is only Some embodiments described in this specification, for those of ordinary skill in the art, in not making the creative labor property Under the premise of, other drawings may also be obtained based on these drawings.
Fig. 1 is the flow chart of data transmission method in one embodiment of the invention;
Fig. 2 is that the flow chart of encryption secret key is obtained by the first encryption method in one embodiment of the invention;
Fig. 3 is the flow chart of data transmission method in further embodiment of this invention.
Specific implementation mode
To keep the purpose, technical scheme and advantage of the application clearer, below in conjunction with the application specific embodiment and Technical scheme is clearly and completely described in corresponding attached drawing.Obviously, described embodiment is only the application one Section Example, instead of all the embodiments.Based on the embodiment in the application, those of ordinary skill in the art are not doing Go out the every other embodiment obtained under the premise of creative work, shall fall in the protection scope of this application.
Below in conjunction with attached drawing, the technical solution that each embodiment of this specification provides is described in detail.
One embodiment of the invention provides a kind of data transmission method, for the number in the network of smart home device composition According to transmission.As shown in FIG. 1, FIG. 1 is the flow charts of data transmission method in one embodiment of the invention.Shown data transmission method packet It includes:Plaintext secret key is generated, such as the step S101 in Fig. 1;Next, according to the plaintext secret key, obtained by the first encryption method Encryption secret key is taken, such as the step S103 in Fig. 1;Then, it according to the second encryption method, is transmitted with the encryption secret key pair needs Data are encrypted, and send out encrypted data, such as the step S105 in Fig. 1.
Step S101 generates plaintext secret key.
In an embodiment of the present invention, the plaintext secret key can be user-defined any content.It specifically can be with It is the familiar content of user, for example, the word that user likes, can also be the name etc. of the pet of user family.
Step S103 obtains encryption secret key according to the plaintext secret key by the first encryption method.
Specifically, as shown in Fig. 2, Fig. 2 obtains encryption secret key in one embodiment of the invention, to pass through the first encryption method Flow chart.
Step S1032 is encrypted the plaintext secret key using first encryption method, obtains pre-encrypt secret key.
In an embodiment of the present invention, first encryption method includes but not limited to base64 Encryption Algorithm.base64 Encryption Algorithm is to be used for transmission the coding mode of 8Bit bytecodes.In other embodiments of the present invention, first encryption method It can also be other encryption methods, such as can also be DES (Data Encryption Standard, data encryption standards), Or 3DES (Triple DES, triple data encryption algorithm) encryption method.
Step S1034 obtains the data of presetting digit capacity from the pre-encrypt secret key.
Specifically, the presetting digit capacity is 2NPosition, wherein N is the integer more than or equal to 6.That is from described pre- 2 are obtained in encryption secret keyNPosition data.In an embodiment of the present invention, N values are 6, i.e., obtain 64 from the pre-encrypt secret key Position data.Certainly, in other embodiments of the invention, the presetting digit capacity can also be 128,256 or other positions Several data.Certainly with the increase of the presetting digit capacity, according to described 2NThe encryption secret key that position data are formed just is increasingly difficult to To crack, data transmission is safer, but the consumption coded and decoded to data is with regard to increasing, therefore can basis Actual conditions carry out assessment selection, such as in an embodiment of the present invention, and 64 data are obtained from the pre-encrypt secret key.
Step S1036 obtains the encryption secret key according to the data of the presetting digit capacity.
Example is connected, according to 64 data obtained from the pre-encrypt secret key, obtains the encryption secret key, specifically, According to 64 data, 64 data are combined, to form new secret key, as encrypt secret key.
Specifically, the odd bits data in 64 data are moved to left, then with the even bit in 64 data Data carry out exclusive or processing, to obtain the encryption secret key.
Certainly in other embodiments of the invention, the encryption secret key can also be other digits, for example, it may be The data of 128,192,256 or other digits, details are not described herein.
Step S105 needs the data transmitted to be encrypted, concurrently according to the second encryption method with the encryption secret key pair Go out encrypted data.
After obtaining the encryption key, needs the data transmitted to be encrypted with the encryption secret key pair, but adding In close process, first encryption method (it is base64 Encryption Algorithm to connect example) is not utilized instead of, utilizes the second encryption Method is encrypted, and in an embodiment of the present invention, second encryption method includes but not limited to AES encryption method.
That is, using the encryption key, the data transmitted to needs by AES encryption method are encrypted, so Encrypted data are transmitted again afterwards.
During above-mentioned steps S101~step S105, plaintext secret key is added by base64 Encryption Algorithm It is close, obtain encryption secret key, then using the encrypted encryption secret key of base64 Encryption Algorithm by AES encryption method to needing to pass Defeated data are encrypted, that is to say, that during data transmission, complicate encrypted need to transmit to the greatest extent Data, need the data transmitted and the encryption direct relationship of secret key, reach maximized mixed using nonlinear transformation algorithm Confuse.Further, plaintext secret key and encryption secret key often change one and will maximumlly influence the digit in encrypted data, Maximized diffusion is reached using linear transformation algorithm.
The embodiment of the present invention additionally provides a kind of data transmission method, specifically, as shown in figure 3, Fig. 3 is that the present invention is another The flow chart of data transmission method in embodiment.The data transmission method includes:Data sending terminal is using encryption secret key with the The data that two encryption methods transmit needs are encrypted, and send encrypted data, wherein the encryption secret key is to pass through The encryption of first encryption method obtains;Such as the step S301 in Fig. 3;Data receiver is after receiving encrypted data, profit Encrypted data are decrypted described in the encryption secret key pair, such as the step S303 in Fig. 3.
Step S301, data sending terminal are added using encryption secret key with the data that the second encryption method transmits needs It is close, and send encrypted data.
First, data sending terminal obtains encryption secret key.Specifically, the data sending terminal obtains the mistake of the encryption secret key Journey includes:Generate plaintext secret key;The plaintext secret key is encrypted using first encryption method, it is secret to obtain pre-encrypt Key;The data of presetting digit capacity are obtained from the pre-encrypt secret key;According to the data of the presetting digit capacity, it is secret to obtain the encryption Key.Then the pre-encrypt secret key is written in configuration file, and the configuration file is transmitted to the smart home device Each terminal device in the network of composition.
Specifically, in an embodiment of the present invention, first encryption method includes but not limited to base64 Encryption Algorithm. Base64 Encryption Algorithm is to be used for transmission the coding mode of 8Bit bytecodes.In other embodiments of the present invention, described first adds Decryption method can also be other encryption methods, such as can also be DES (Data Encryption Standard, data encryption Standard) or 3DES (Triple DES, triple data encryption algorithm) encryption method.
Then, the data of presetting digit capacity are obtained from the pre-encrypt secret key.
Specifically, the presetting digit capacity is 2NPosition, wherein N is the integer more than or equal to 6.That is from described pre- 2 are obtained in encryption secret keyNPosition data.In an embodiment of the present invention, N values are 6, i.e., obtain 64 from the pre-encrypt secret key Position data.Certainly, in other embodiments of the invention, the presetting digit capacity can also be 128,256 or other positions Several data.Certainly with the increase of the presetting digit capacity, according to described 2NThe encryption secret key that position data are formed just is increasingly difficult to To crack, data transmission is safer, but the consumption coded and decoded to data is with regard to increasing, therefore can basis Actual conditions carry out assessment selection, such as in an embodiment of the present invention, and 64 data are obtained from the pre-encrypt secret key.
Finally, according to the data of the presetting digit capacity, the encryption secret key is obtained.
Example is connected, according to 64 data obtained from the pre-encrypt secret key, obtains the encryption secret key, specifically, According to 64 data, 64 data are combined, to form new secret key, as encrypt secret key.
Specifically, the odd bits data in 64 data are moved to left, then with the even bit in 64 data Data carry out exclusive or processing, to obtain the encryption secret key.
After obtaining the encryption key, needs the data transmitted to be encrypted with the encryption secret key pair, but adding In close process, first encryption method (it is base64 Encryption Algorithm to connect example) is not utilized instead of, utilizes the second encryption Method is encrypted, and in an embodiment of the present invention, second encryption method includes but not limited to AES encryption method.
That is, using the encryption key, the data transmitted to needs by AES encryption method are encrypted, so Encrypted data are transmitted again afterwards.
Further include institute it should be noted that including not only encrypted data in the data that the data sending terminal is sent State encryption secret key.
Step S303, data receiver are encrypted after receiving encrypted data using described in the encryption secret key pair Data afterwards are decrypted.
Specifically, the data receiver obtains the pre-encrypt secret key from configuration file, and according to the pre-encrypt Secret key obtains the encryption secret key.Specifically, 64 data obtained from the pre-encrypt secret key, it is secret to obtain the encryption Key, specifically, the odd bits data in 64 data are moved to left, then with the even bit data in 64 data into The processing of row exclusive or encrypts secret key to obtain receiving terminal.
After the data receiver receives the data that the data sending terminal is sent, obtained from the data received Receiving terminal encryption secret key is matched with encryption secret key is received, when successful match, utilizes institute by the encryption secret key The encrypted data that data sending terminal is sent described in encryption secret key pair are stated to be decrypted.
Further, it is obtained when the configuration file is the data receiver initialization.
In a kind of data transmission method provided in an embodiment of the present invention, encryption secret key is obtained by the first encryption method, Then recycle the encrypted encryption secret key of first encryption method, according to the second encryption method to the data transmitted of needs into Row encrypted transmission, that is to say, that in intelligent home network, make in intelligence control, run with user terminal on application program with And between high in the clouds, data are transmitted between above-mentioned three with ciphertext, and data are encrypted using two kinds of encryption methods, into One step improves the safety of data.
The application can describe in the general context of computer-executable instructions executed by a computer, such as program Module.Usually, program module includes routines performing specific tasks or implementing specific abstract data types, program, object, group Part, data structure etc..The application can also be put into practice in a distributed computing environment, in these distributed computing environments, by Task is executed by the connected remote processing devices of communication network.In a distributed computing environment, program module can be with In the local and remote computer storage media including storage device.
Each embodiment in this specification is described in a progressive manner, identical similar portion between each embodiment Point just to refer each other, and each embodiment focuses on the differences from other embodiments.Especially for system reality For applying example, since it is substantially similar to the method embodiment, so description is fairly simple, related place is referring to embodiment of the method Part explanation.
Above is only an example of the present application, it is not intended to limit this application.For those skilled in the art For, the application can have various modifications and variations.It is all within spirit herein and principle made by any modification, equivalent Replace, improve etc., it should be included within the scope of claims hereof.

Claims (10)

1. a kind of data transmission method, for the data transmission in the network of smart home device composition, which is characterized in that packet It includes:
Generate plaintext secret key;
According to the plaintext secret key, encryption secret key is obtained by the first encryption method;
According to the second encryption method, needs the data transmitted to be encrypted with the encryption secret key pair, send out encrypted data.
2. data transmission method according to claim 1, which is characterized in that according to the plaintext secret key, add by first Decryption method obtains encryption secret key, including:
The plaintext secret key is encrypted using first encryption method, obtains pre-encrypt secret key;
The data of presetting digit capacity are obtained from the pre-encrypt secret key;
According to the data of the presetting digit capacity, the encryption secret key is obtained.
3. data transmission method according to claim 1 or 2, which is characterized in that first encryption method includes Base64 Encryption Algorithm.
4. data transmission method according to claim 2, which is characterized in that the presetting digit capacity is 2NPosition;
The data that presetting digit capacity is obtained from the pre-encrypt secret key, including:
2 are obtained from the pre-encrypt secret keyNPosition data, wherein N is the integer more than or equal to 6.
5. data transmission method according to claim 1, which is characterized in that second encryption method includes AES encryption Method.
6. a kind of data transmission method, which is characterized in that including:
Data sending terminal using encryption secret key with the second encryption method to needing the data transmitted to be encrypted, and after sending encryption Data, wherein the encryption secret key be by the first encryption method encrypt obtain;
Data receiver is solved after receiving encrypted data using encrypted data described in the encryption secret key pair It is close.
7. data transmission method according to claim 6, which is characterized in that data sending terminal obtains the mistake of encryption secret key Journey, including:
Generate plaintext secret key;
The plaintext secret key is encrypted using first encryption method, obtains pre-encrypt secret key;
The data of presetting digit capacity are obtained from the pre-encrypt secret key;
According to the data of the presetting digit capacity, the encryption secret key is obtained.
8. the data transmission method described according to claim 6 or 7, which is characterized in that first encryption method includes Base64 Encryption Algorithm.
9. data transmission method according to claim 7, which is characterized in that the presetting digit capacity is 2NPosition;
The data that presetting digit capacity is obtained from the pre-encrypt secret key, including:
2 are obtained from the pre-encrypt secret keyNPosition data, wherein N is the integer more than or equal to 6.
10. data transmission method according to claim 6, which is characterized in that second encryption method includes AES encryption Method.
CN201711291919.0A 2017-12-07 2017-12-07 A kind of data transmission method Pending CN108322303A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201711291919.0A CN108322303A (en) 2017-12-07 2017-12-07 A kind of data transmission method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201711291919.0A CN108322303A (en) 2017-12-07 2017-12-07 A kind of data transmission method

Publications (1)

Publication Number Publication Date
CN108322303A true CN108322303A (en) 2018-07-24

Family

ID=62892567

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201711291919.0A Pending CN108322303A (en) 2017-12-07 2017-12-07 A kind of data transmission method

Country Status (1)

Country Link
CN (1) CN108322303A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110730366A (en) * 2019-10-30 2020-01-24 杭州叙简科技股份有限公司 Bit operation-based lightweight video stream encryption and decryption method and encryption and decryption mechanism

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104253684A (en) * 2014-09-23 2014-12-31 深圳市汇顶科技股份有限公司 Encryption method and encryption device
US20160380775A1 (en) * 2013-09-27 2016-12-29 Amazon Technologies, Inc. Robot mitigation
CN106301774A (en) * 2015-05-29 2017-01-04 联芯科技有限公司 Safety chip, its encryption key generate method and encryption method
CN107332666A (en) * 2017-08-17 2017-11-07 创元网络技术股份有限公司 Terminal document encryption method

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20160380775A1 (en) * 2013-09-27 2016-12-29 Amazon Technologies, Inc. Robot mitigation
CN104253684A (en) * 2014-09-23 2014-12-31 深圳市汇顶科技股份有限公司 Encryption method and encryption device
CN106301774A (en) * 2015-05-29 2017-01-04 联芯科技有限公司 Safety chip, its encryption key generate method and encryption method
CN107332666A (en) * 2017-08-17 2017-11-07 创元网络技术股份有限公司 Terminal document encryption method

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110730366A (en) * 2019-10-30 2020-01-24 杭州叙简科技股份有限公司 Bit operation-based lightweight video stream encryption and decryption method and encryption and decryption mechanism

Similar Documents

Publication Publication Date Title
CN1319294A (en) Adapter having secure function and computer secure system using it
CN104144049A (en) Encryption communication method, system and device
CN101316424A (en) Information transmission method, system and device
CN104468095A (en) Data transmission method and device
CN103886263A (en) Method and system for protecting data in mobile terminal
CN107707562B (en) Method and device for encrypting and decrypting algorithm of asymmetric dynamic token
CN109194701B (en) Data processing method and device
CN101707767B (en) Data transmission method and devices
CN103458400A (en) Key management method for voice encryption communication system
CN104901803A (en) Data interaction safety protection method based on CPK identity authentication technology
CN1649295A (en) Device and its method for end-to-end enciphering and deenciphering in clony system
CN102724205A (en) Method for encrypting communication process in industrial field and data collection device
CN114499990A (en) Vehicle control method, device, equipment and storage medium
CN116488919B (en) Data processing method, communication node and storage medium
CN108322303A (en) A kind of data transmission method
CN107094036A (en) A kind of cipher key processing method and Bluetooth terminal based on bluetooth communication
CN102882897A (en) Cookie protecting method and device
CN113746642B (en) Method and system for communication between computers
CN110035061A (en) Trust server information processing method and system
CN104243141A (en) Information segmented encryption communication method
US9596218B1 (en) Methods and systems of encrypting messages using rateless codes
CN106357390A (en) Dynamic encryption method and device
Cao A security communication device based on narrowband internet of things
CN110650121A (en) Stream media data security system based on distributed system
CN102256246A (en) Data transfer encryption method for mobile communication

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
WD01 Invention patent application deemed withdrawn after publication
WD01 Invention patent application deemed withdrawn after publication

Application publication date: 20180724