[go: up one dir, main page]

CN111506913B - Audio encryption method and device, storage medium and electronic device - Google Patents

Audio encryption method and device, storage medium and electronic device Download PDF

Info

Publication number
CN111506913B
CN111506913B CN202010318428.6A CN202010318428A CN111506913B CN 111506913 B CN111506913 B CN 111506913B CN 202010318428 A CN202010318428 A CN 202010318428A CN 111506913 B CN111506913 B CN 111506913B
Authority
CN
China
Prior art keywords
file
data
audio
audio file
original audio
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.)
Active
Application number
CN202010318428.6A
Other languages
Chinese (zh)
Other versions
CN111506913A (en
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.)
Shanghai Minglue Artificial Intelligence Group Co Ltd
Original Assignee
Shanghai Minglue Artificial Intelligence Group Co Ltd
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 Shanghai Minglue Artificial Intelligence Group Co Ltd filed Critical Shanghai Minglue Artificial Intelligence Group Co Ltd
Priority to CN202010318428.6A priority Critical patent/CN111506913B/en
Publication of CN111506913A publication Critical patent/CN111506913A/en
Application granted granted Critical
Publication of CN111506913B publication Critical patent/CN111506913B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F21/00Security arrangements for protecting computers, components thereof, programs or data against unauthorised activity
    • G06F21/60Protecting data
    • G06F21/602Providing cryptographic facilities or services

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Health & Medical Sciences (AREA)
  • Bioethics (AREA)
  • General Health & Medical Sciences (AREA)
  • Computer Hardware Design (AREA)
  • Computer Security & Cryptography (AREA)
  • Software Systems (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Storage Device Security (AREA)

Abstract

The invention discloses an audio encryption method and device, a storage medium and an electronic device. Wherein the method comprises the following steps: acquiring an original audio file to be encrypted; inserting confusion data into file data of an original audio file to obtain a first audio file, wherein the data type of the confusion data is the same as that of the file data of the original audio file; adjusting the sequence of file data in the first audio file according to a target rule to obtain a second audio file; and determining the second audio file as a file obtained by encrypting the original audio file. The invention solves the technical problem of low encryption and decryption efficiency in the prior art.

Description

Audio encryption method and device, storage medium and electronic device
Technical Field
The present invention relates to the field of data encryption, and in particular, to an audio encryption method and apparatus, a storage medium, and an electronic apparatus.
Background
In the prior art, in the process of encrypting the audio, an asymmetric encryption RSA encryption algorithm or an advanced encryption standard AES encryption standard or the like can be generally adopted.
However, the encryption calculation amount involved in the above encryption method is quite large, and even if a small file is encrypted, a large amount of calculation resources of the central processing unit CPU are required to be occupied, so that encryption and subsequent decryption are low in efficiency.
In view of the above problems, no effective solution has been proposed at present.
Disclosure of Invention
The embodiment of the invention provides an audio encryption method and device, a storage medium and an electronic device, which are used for at least solving the technical problems of low encryption and decryption efficiency in the prior art.
According to an aspect of an embodiment of the present invention, there is provided an audio encryption method including: acquiring an original audio file to be encrypted; inserting confusion data into the file data of the original audio file to obtain a first audio file, wherein the data type of the confusion data is the same as the data type of the file data of the original audio file; adjusting the sequence of file data in the first audio file according to a target rule to obtain a second audio file; and determining the second audio file as a file obtained by encrypting the original audio file.
According to another aspect of an embodiment of the present invention, there is provided an audio decryption method including: after a second audio file to be decrypted is obtained, obtaining confusion data used in the process of encrypting an original audio file, and an inserting position and a target rule of the confusion data, wherein the second audio file is a file obtained by inserting the confusion data into file data of the original audio file to obtain a first audio file, and then adjusting the sequence of the file data in the first audio file according to the target rule, and the data type of the confusion data is the same as the data type of the file data of the original audio file; reversely adjusting the sequence of file data in the second audio file according to the target rule to obtain the first audio file; and deleting the confusion data in the first audio file according to the insertion position of the confusion data to obtain the original audio file.
According to still another aspect of the embodiment of the present invention, there is also provided an audio encrypting apparatus including: the first acquisition unit is used for acquiring an original audio file to be encrypted; an inserting unit, configured to insert confusion data into file data of the original audio file to obtain a first audio file, where a data type of the confusion data is the same as a data type of the file data of the original audio file; the adjusting unit is used for adjusting the sequence of the file data in the first audio file according to the target rule to obtain a second audio file; and the determining unit is used for determining the second audio file as a file obtained by encrypting the original audio file.
According to still another aspect of the embodiment of the present invention, there is also provided an audio decryption apparatus including: the device comprises an acquisition unit, a decryption unit and a storage unit, wherein the acquisition unit is used for acquiring confusion data used in the process of encrypting an original audio file, the insertion position of the confusion data and a target rule after acquiring a second audio file to be decrypted, the second audio file is a file obtained by inserting the confusion data into file data of the original audio file to obtain a first audio file, and then adjusting the sequence of the file data in the first audio file according to the target rule, wherein the data type of the confusion data is the same as the data type of the file data of the original audio file; the adjusting unit is used for reversely adjusting the sequence of file data in the second audio file according to the target rule to obtain the first audio file; and the deleting unit is used for deleting the confusion data in the first audio file according to the insertion position of the confusion data to obtain the original audio file.
In the embodiment of the invention, the original audio file to be encrypted is acquired; inserting confusion data into the file data of the original audio file to obtain a first audio file, wherein the data type of the confusion data is the same as the data type of the file data of the original audio file; adjusting the sequence of file data in the first audio file according to a target rule to obtain a second audio file; the method for determining the second audio file as the file obtained by encrypting the original audio file does not need to use an encryption method such as an asymmetric encryption RSA encryption algorithm with large calculation amount and complex calculation or an advanced encryption standard AES encryption standard, and the like, but uses the encryption method, so that the encryption of the audio file can be realized by executing simple operation on the audio file, the security is ensured, the encryption and decryption efficiency is improved, and the technical problems of low encryption and decryption efficiency in the prior art are solved.
Drawings
The accompanying drawings, which are included to provide a further understanding of the invention and are incorporated in and constitute a part of this application, illustrate embodiments of the invention and together with the description serve to explain the invention and do not constitute a limitation on the invention. In the drawings:
FIG. 1 is a flow chart of an alternative audio encryption method according to an embodiment of the invention;
FIG. 2 is a schematic diagram of an alternative audio encryption method according to an embodiment of the invention;
FIG. 3 is a flow chart of an alternative audio decryption method according to an embodiment of the invention;
FIG. 4 is a schematic diagram of an alternative audio encryption apparatus according to an embodiment of the present invention;
fig. 5 is a schematic structural view of an alternative audio decryption device according to an embodiment of the present invention.
Detailed Description
In order that those skilled in the art will better understand the present invention, a technical solution in the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings in which it is apparent that the described embodiments are only some embodiments of the present invention, not all embodiments. All other embodiments, which can be made by those skilled in the art based on the embodiments of the present invention without making any inventive effort, shall fall within the scope of the present invention.
It should be noted that the terms "first," "second," and the like in the description and the claims of the present invention and the above figures are used for distinguishing between similar objects and not necessarily for describing a particular sequential or chronological order. It is to be understood that the data so used may be interchanged where appropriate such that the embodiments of the invention described herein may be implemented in sequences other than those illustrated or otherwise described herein. Furthermore, the terms "comprises," "comprising," and "having," and any variations thereof, are intended to cover a non-exclusive inclusion, such that a process, method, system, article, or apparatus that comprises a list of steps or elements is not necessarily limited to those steps or elements expressly listed but may include other steps or elements not expressly listed or inherent to such process, method, article, or apparatus.
According to an aspect of the embodiment of the present invention, there is provided an audio encryption method, optionally, as an optional implementation manner, the audio encryption method may include:
s102, acquiring an original audio file to be encrypted;
s104, inserting confusion data into file data of the original audio file to obtain a first audio file, wherein the data type of the confusion data is the same as that of the file data of the original audio file;
s106, adjusting the sequence of file data in the first audio file according to a target rule to obtain a second audio file;
s108, determining the second audio file as a file obtained by encrypting the original audio file.
Alternatively, the method can be applied to a terminal capable of calculating data, such as a mobile phone, a tablet computer, a notebook computer, a PC and the like, or intelligent hardware, such as intelligent tablet, intelligent recording equipment and the like. The terminal or smart device may interact with the server through a network, which may include, but is not limited to, a wireless network or a wired network. Wherein the wireless network comprises: WIFI and other networks that enable wireless communications. The wired network may include, but is not limited to: wide area network, metropolitan area network, local area network. The server may include, but is not limited to, any hardware device that can perform the calculations.
Alternatively, the above-described audio encryption method may be applied, but not limited to, in the course of audio transmission. Such as a live broadcast field, or a recording field, in which audio to be transmitted may be a service-generated sound recorded in a restaurant, a sound of a worker recorded in a store, or the like. The present embodiment is not limited.
Taking recording a sound generated by a restaurant service and carrying out encryption transmission of the sound as an example, in the scheme, after an original audio file to be encrypted recorded by recording equipment is obtained, confusion data is inserted into file data of the original audio file to obtain a first audio file, then the sequence of the file data in the first audio file is adjusted according to a target rule to obtain a second audio file, wherein the second audio file is a file which is successfully encrypted and can be transmitted, and the second audio file is further transmitted, such as being sent to a server for storage and the like.
Optionally, the original audio file in the scheme may be a file recorded in real time, or may be a file recorded completely.
Alternatively, in the scheme, a real-time recorded file or an executable file in a recorded file, such as a bin file, can be used as an original audio file, encrypted and transmitted.
Alternatively, the obfuscated data in the present scheme may be a meaningless scrambling code of the same type as the file data of the original audio file.
Alternatively, in this scheme, when the mix-up data is inserted into the original audio file, the target position may be determined in the original audio file.
There are a variety of methods for determining the location of the target.
For example, one or more positions may be randomly determined in file data of an original audio file, and the determined positions may be used as target positions, or after the file output of the original audio file is split to obtain a plurality of original audio subfiles, one or more confusion data may be inserted before and after any one or more of the original audio subfiles.
Taking splitting the original audio file into three original audio subfiles as an example, the original audio subfiles 1, 2, and 3 are respectively. The obfuscation data may be inserted before or after any one or more of the original audio subfiles 1, 2, and 3. Such as inserting the obfuscation data before the original audio subfile 1, inserting the obfuscation data before the original audio subfile 3, or inserting the obfuscation data before the original audio subfile 2 and after the original audio subfile 3, or inserting the obfuscation data after the original audio subfile 1 and before the original audio subfile 2, etc., all of which are not listed here. The method can select to insert one confusion data or insert a plurality of confusion data each time the confusion data is inserted, and can randomly determine the quantity of the confusion data inserted each time the confusion data is inserted. For example, when the mix-up data is inserted after the original audio subfile 1 and before the original audio subfile 2, three mix-up data may be inserted after the original audio subfile 1, 1 mix-up data may be inserted before the original audio subfile 2, etc.
Alternatively, after the mix-up data is inserted into the original audio file, the first audio file is obtained, and then the order of the file data in the first audio file may be adjusted. In the adjusting process, a configuration file can be obtained, and a plurality of preset rules can be pre-stored in the configuration file, wherein each preset rule is used for adjusting the sequence of file data in the first audio file. The file size of the first audio file can be obtained, then a target rule matched with the size is searched according to the file size, then the sequence of file data in the first audio file is adjusted by using the target rule, or the first audio file is split into a plurality of first audio subfiles, then a preset rule corresponding to the number is searched according to the number of the plurality of split first audio subfiles to serve as the target rule, and the sequence of the file data in the first audio file is adjusted.
For example, after splitting the first audio file into 6 pieces, the first rule is acquired as the target rule, and then the 6 first audio subfiles of the first audio file may be swapped in order according to the first rule. If the first audio sub-file and the second first audio sub-file are in the exchange order, finally obtaining the second audio file.
After the second audio file is obtained, the second audio file is transmitted to the original audio file. And sending the second audio file, the confusion data, the insertion position of the confusion data and the target rule to a receiver, and after the receiver receives the second audio file, reversely adjusting the sequence of the file data in the second audio file according to the target rule. If the target rule indicates that the first sub-file and the third sub-file in the first audio sub-file are exchanged in sequence, the first sub-file and the third sub-file in the first audio sub-file are reversely adjusted to be exchanged in sequence, so that the first audio file is obtained. And then deleting the confusion data from the first audio file according to the insertion position of the confusion data to obtain an original audio file, and realizing the decryption process of the file. After obtaining the original audio file, the recipient may play the original audio file.
The following description is made with reference to fig. 2 in conjunction with a specific example.
The scheme can be applied to the client, the client can be worn by staff, and the client can record the sound of the staff. After the recording is finished, the original audio file can be obtained.
After the original audio file is obtained, a configuration file can be obtained from the server, wherein the configuration file comprises confusion data and preset rules. After obtaining the obfuscated data, the target location is first determined in the original audio file, which may be split into multiple original audio subfiles, and then one obfuscated data is inserted before each original audio subfile. The original audio file 202 is split into a plurality of original audio subfiles 204 as shown in fig. 2, and then the obfuscated data 206 is inserted, resulting in a first audio file 208 after the obfuscated data 206 is inserted. Then, the first audio file 208 is split again to obtain a plurality of first audio subfiles 210, then the order of the plurality of first audio subfiles 210 is adjusted according to the first rule to obtain a second audio file 212, after the data is transmitted to the server in step S212, the server first restores the second audio file 2121 to the first audio file 208 according to the first rule, and the restoring process is to reversely adjust the order of the first audio subfiles 210. After the first audio file 208 is obtained, the obfuscated data in the first audio file 208 is deleted, the original audio file 202 is obtained, and the original audio file 202 is played or the original audio file 202 is stored. Optionally, before the second audio file 212 is transmitted in step S202, the second audio file 212 may be compressed and then transmitted, and the server receives the second audio file 212 and then decompresses and decodes the second audio file.
By the method, the effect of improving the encryption and decryption efficiency of the audio file is achieved.
It should be noted that, for simplicity of description, the foregoing method embodiments are all described as a series of acts, but it should be understood by those skilled in the art that the present invention is not limited by the order of acts described, as some steps may be performed in other orders or concurrently in accordance with the present invention. Further, those skilled in the art will also appreciate that the embodiments described in the specification are all preferred embodiments, and that the acts and modules referred to are not necessarily required for the present invention.
According to another aspect of the embodiment of the present invention, there is also provided an audio decryption method, optionally, as shown in fig. 3, including:
s302, after a second audio file to be decrypted is obtained, obtaining confusion data, an inserting position of the confusion data and a target rule used in the process of encrypting an original audio file, wherein the second audio file is a file obtained by inserting the confusion data into file data of the original audio file to obtain a first audio file, and then adjusting the sequence of the file data in the first audio file according to the target rule, wherein the data type of the confusion data is the same as that of the file data of the original audio file;
s304, reversely adjusting the sequence of file data in the second audio file according to a target rule to obtain a first audio file;
s306, deleting the confusion data in the first audio file according to the insertion position of the confusion data to obtain an original audio file.
Alternatively, the method may be applied, but not limited to, to a server, which may include, but is not limited to, any hardware device capable of performing calculations. The server may interact with the terminal or intelligent hardware through a network, which may include, but is not limited to, a wireless network or a wired network. Wherein the wireless network comprises: WIFI and other networks that enable wireless communications. The wired network may include, but is not limited to: wide area network, metropolitan area network, local area network. The terminal or the intelligent equipment can be a mobile phone, a tablet personal computer, a notebook personal computer, a PC (personal computer) and the like, or hardware such as an intelligent tablet, an intelligent recording device and the like.
Alternatively, the above-described audio encryption method may be applied, but not limited to, in the course of audio transmission. Such as a live broadcast field, or a recording field, in which audio to be transmitted may be a service-generated sound recorded in a restaurant, a sound of a worker recorded in a store, or the like. The present embodiment is not limited.
Taking recording a sound generated by a restaurant service and carrying out encryption transmission and decryption of the sound as an example, in the scheme, after an original audio file to be encrypted recorded by recording equipment is obtained, confusion data is inserted into file data of the original audio file to obtain a first audio file, then the sequence of the file data in the first audio file is adjusted according to a target rule to obtain a second audio file, the second audio file is a file which is successfully encrypted and can be transmitted, the second audio file is further transmitted, if the second audio file is sent to a server, after the server receives the second audio file, the sequence of the first audio sub-file is reversely adjusted according to the target rule to obtain the first audio sub-file, the confusion data in the first audio sub-file is deleted to obtain the original audio file, and the original audio file is played.
Other embodiments may be referred to the above encryption side embodiments, and will not be described herein.
By the method, the effect of improving the encryption and decryption efficiency of the audio file is achieved.
According to still another aspect of the embodiments of the present invention, there is also provided an audio encryption apparatus for implementing the above-described audio encryption method. As shown in fig. 4, the apparatus includes:
(1) A first obtaining unit 402, configured to obtain an original audio file to be encrypted;
(2) An inserting unit 404, configured to insert confusion data into file data of an original audio file to obtain a first audio file, where a data type of the confusion data is the same as a data type of the file data of the original audio file;
(3) An adjusting unit 406, configured to adjust the order of the file data in the first audio file according to the target rule, so as to obtain a second audio file;
(4) A determining unit 408, configured to determine the second audio file as a file obtained by encrypting the original audio file.
Alternatively, the audio encryption apparatus may be applied to, but not limited to, audio transmission. Such as a live broadcast field, or a recording field, in which audio to be transmitted may be a service-generated sound recorded in a restaurant, a sound of a worker recorded in a store, or the like. The present embodiment is not limited.
Taking recording a sound generated by a restaurant service and carrying out encryption transmission of the sound as an example, in the scheme, after an original audio file to be encrypted recorded by recording equipment is obtained, confusion data is inserted into file data of the original audio file to obtain a first audio file, then the sequence of the file data in the first audio file is adjusted according to a target rule to obtain a second audio file, wherein the second audio file is a file which is successfully encrypted and can be transmitted, and the second audio file is further transmitted, such as being sent to a server for storage and the like.
Optionally, the original audio file in the scheme may be a file recorded in real time, or may be a file recorded completely.
Alternatively, in the scheme, a real-time recorded file or an executable file in a recorded file, such as a bin file, can be used as an original audio file, encrypted and transmitted.
Alternatively, the obfuscated data in the present scheme may be a meaningless scrambling code of the same type as the file data of the original audio file.
Alternatively, in this scheme, when the mix-up data is inserted into the original audio file, the target position may be determined in the original audio file.
There are a variety of methods for determining the location of the target.
For example, one or more positions may be randomly determined in file data of an original audio file, and the determined positions may be used as target positions, or after the file output of the original audio file is split to obtain a plurality of original audio subfiles, one or more confusion data may be inserted before and after any one or more of the original audio subfiles.
Taking splitting the original audio file into three original audio subfiles as an example, the original audio subfiles 1, 2, and 3 are respectively. The obfuscation data may be inserted before or after any one or more of the original audio subfiles 1, 2, and 3. Such as inserting the obfuscation data before the original audio subfile 1, inserting the obfuscation data before the original audio subfile 3, or inserting the obfuscation data before the original audio subfile 2 and after the original audio subfile 3, or inserting the obfuscation data after the original audio subfile 1 and before the original audio subfile 2, etc., all of which are not listed here. The method can select to insert one confusion data or insert a plurality of confusion data each time the confusion data is inserted, and can randomly determine the quantity of the confusion data inserted each time the confusion data is inserted. For example, when the mix-up data is inserted after the original audio subfile 1 and before the original audio subfile 2, three mix-up data may be inserted after the original audio subfile 1, 1 mix-up data may be inserted before the original audio subfile 2, etc.
Alternatively, after the mix-up data is inserted into the original audio file, the first audio file is obtained, and then the order of the file data in the first audio file may be adjusted. In the adjusting process, a configuration file can be obtained, and a plurality of preset rules can be pre-stored in the configuration file, wherein each preset rule is used for adjusting the sequence of file data in the first audio file. The file size of the first audio file can be obtained, then a target rule matched with the size is searched according to the file size, then the sequence of file data in the first audio file is adjusted by using the target rule, or the first audio file is split into a plurality of first audio subfiles, then a preset rule corresponding to the number is searched according to the number of the plurality of split first audio subfiles to serve as the target rule, and the sequence of the file data in the first audio file is adjusted.
For example, after splitting the first audio file into 6 pieces, the first rule is acquired as the target rule, and then the 6 first audio subfiles of the first audio file may be swapped in order according to the first rule. If the first audio sub-file and the second first audio sub-file are in the exchange order, finally obtaining the second audio file.
After the second audio file is obtained, the second audio file is transmitted to the original audio file. And sending the second audio file, the confusion data, the insertion position of the confusion data and the target rule to a receiver, and after the receiver receives the second audio file, reversely adjusting the sequence of the file data in the second audio file according to the target rule. If the target rule indicates that the first sub-file and the third sub-file in the first audio sub-file are exchanged in sequence, the first sub-file and the third sub-file in the first audio sub-file are reversely adjusted to be exchanged in sequence, so that the first audio file is obtained. And then deleting the confusion data from the first audio file according to the insertion position of the confusion data to obtain an original audio file, and realizing the decryption process of the file. After obtaining the original audio file, the recipient may play the original audio file.
According to the embodiment, the device achieves the effect of improving the encryption and decryption efficiency of the audio file.
According to still another aspect of the embodiments of the present invention, there is also provided an audio decryption apparatus for implementing the above-described audio decryption method. As shown in fig. 5, the apparatus includes:
(1) The obtaining unit 502 is configured to obtain, after obtaining a second audio file to be decrypted, confusion data used in a process of encrypting an original audio file, an insertion position of the confusion data, and a target rule, where the second audio file is a file obtained by inserting the confusion data into file data of the original audio file to obtain a first audio file, and then adjusting an order of file data in the first audio file according to the target rule, where a data type of the confusion data is the same as a data type of file data of the original audio file;
(2) An adjusting unit 504, configured to reversely adjust the order of the file data in the second audio file according to the target rule, so as to obtain a first audio file;
(3) And a deleting unit 506, configured to delete the confusion data in the first audio file according to the insertion position of the confusion data, so as to obtain an original audio file.
Alternatively, the audio encryption apparatus may be applied to, but not limited to, audio transmission. Such as a live broadcast field, or a recording field, in which audio to be transmitted may be a service-generated sound recorded in a restaurant, a sound of a worker recorded in a store, or the like. The present embodiment is not limited.
Taking recording a sound generated by a restaurant service and carrying out encryption transmission and decryption of the sound as an example, in the scheme, after an original audio file to be encrypted recorded by recording equipment is obtained, confusion data is inserted into file data of the original audio file to obtain a first audio file, then the sequence of the file data in the first audio file is adjusted according to a target rule to obtain a second audio file, the second audio file is a file which is successfully encrypted and can be transmitted, the second audio file is further transmitted, if the second audio file is sent to a server, after the server receives the second audio file, the sequence of the first audio sub-file is reversely adjusted according to the target rule to obtain the first audio sub-file, the confusion data in the first audio sub-file is deleted to obtain the original audio file, and the original audio file is played.
Other embodiments may be referred to the above encryption side embodiments, and will not be described herein.
According to the embodiment, the device achieves the effect of improving the encryption and decryption efficiency of the audio file.
In several embodiments provided in the present application, it should be understood that the disclosed client may be implemented in other manners. The above-described embodiments of the apparatus are merely exemplary, and are merely a logical functional division, and there may be other manners of dividing the apparatus in actual implementation, for example, multiple units or components may be combined or integrated into another system, or some features may be omitted, or not performed. Alternatively, the coupling or direct coupling or communication connection shown or discussed with each other may be through some interfaces, units or modules, or may be in electrical or other forms.
The units described as separate units may or may not be physically separate, and units shown as units may or may not be physical units, may be located in one place, or may be distributed over a plurality of network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment.
In addition, each functional unit in the embodiments of the present invention may be integrated in one processing unit, or each unit may exist alone physically, or two or more units may be integrated in one unit. The integrated units may be implemented in hardware or in software functional units.
The foregoing is merely a preferred embodiment of the present invention and it should be noted that modifications and adaptations to those skilled in the art may be made without departing from the principles of the present invention, which are intended to be comprehended within the scope of the present invention.

Claims (6)

1. An audio encryption method, comprising:
acquiring an original audio file to be encrypted;
inserting confusion data into the file data of the original audio file to obtain a first audio file, wherein the data type of the confusion data is the same as the data type of the file data of the original audio file, and inserting confusion data into the file data of the original audio file to obtain the first audio file comprises: splitting file data of the original audio file to obtain a plurality of original audio subfiles, and inserting the confusion data into a target position, wherein the target position comprises: before the first original audio subfile, after the last original audio subfile and between every two adjacent original audio subfiles, or randomly determining a plurality of target positions in file data of the original audio files, and inserting confusion data into each target position;
adjusting the order of the file data in the first audio file according to the target rule to obtain a second audio file, wherein the adjusting the order of the file data in the first audio file according to the target rule to obtain the second audio file comprises: splitting file data of the first audio file to obtain a plurality of first audio subfiles under the condition that the target rule is a first rule, wherein the first rule is one of a plurality of preset rules, and the plurality of preset rules are used for adjusting the sequence of the file data in the first audio file; exchanging the ith first audio subfile and the (i+1) th first audio subfile in the plurality of first audio subfiles, wherein i is an odd number and is smaller than the number of the first audio subfiles;
and determining the second audio file as a file obtained by encrypting the original audio file.
2. The method of claim 1, wherein prior to adjusting the order of file data in the first audio file according to the target rule to obtain the second audio file, the method further comprises:
acquiring a configuration file, wherein the configuration file comprises a plurality of preset rules, and the preset rules are used for adjusting the sequence of file data in the first audio file;
selecting preset rules corresponding to intervals as the target rules according to the intervals of the file sizes of the first audio files, wherein each preset rule corresponds to one interval; or alternatively
And selecting preset rules corresponding to the number as the target rules according to the number of the first audio subfiles divided by the first audio file, wherein each preset rule corresponds to one number.
3. The method according to any one of claims 1 to 2, wherein after determining the second audio file as the encrypted original audio file, the method further comprises:
and sending the second audio file, the confusion data, the inserting position of the confusion data and the target rule to a receiver, so that the receiver decrypts the second audio file according to the confusion data, the inserting position of the confusion data and the target rule, and the original audio file is obtained.
4. An audio decryption method, comprising:
after obtaining the second audio file to be decrypted, obtaining confusion data used in the process of encrypting the original audio file, the inserting position of the confusion data and the target rule, wherein the second audio file is generated by the following steps: acquiring an original audio file to be encrypted; inserting confusion data into the file data of the original audio file to obtain a first audio file, wherein the data type of the confusion data is the same as the data type of the file data of the original audio file, and inserting confusion data into the file data of the original audio file to obtain the first audio file comprises the following steps: splitting file data of the original audio file to obtain a plurality of original audio subfiles, and inserting the confusion data into a target position, wherein the target position comprises: before the first original audio subfile, after the last original audio subfile and between every two adjacent original audio subfiles, or randomly determining a plurality of target positions in file data of the original audio files, and inserting confusion data into each target position;
adjusting the order of the file data in the first audio file according to the target rule to obtain a second audio file, wherein the adjusting the order of the file data in the first audio file according to the target rule to obtain the second audio file comprises: splitting file data of the first audio file to obtain a plurality of first audio subfiles under the condition that the target rule is a first rule, wherein the first rule is one of a plurality of preset rules, and the plurality of preset rules are used for adjusting the sequence of the file data in the first audio file; exchanging the ith first audio subfile and the (i+1) th first audio subfile in the plurality of first audio subfiles, wherein i is an odd number and is smaller than the number of the first audio subfiles; determining the second audio file as a file obtained by encrypting the original audio file, wherein the data type of the confusion data is the same as the data type of the file data of the original audio file;
reversely adjusting the sequence of file data in the second audio file according to the target rule to obtain the first audio file;
and deleting the confusion data in the first audio file according to the insertion position of the confusion data to obtain the original audio file.
5. An audio encryption apparatus, comprising:
the first acquisition unit is used for acquiring an original audio file to be encrypted;
an inserting unit, configured to insert confusion data into file data of the original audio file to obtain a first audio file, where a data type of the confusion data is the same as a data type of the file data of the original audio file, and inserting confusion data into the file data of the original audio file to obtain the first audio file includes: splitting file data of the original audio file to obtain a plurality of original audio subfiles, and inserting the confusion data into a target position, wherein the target position comprises: before the first original audio subfile, after the last original audio subfile and between every two adjacent original audio subfiles, or randomly determining a plurality of target positions in file data of the original audio files, and inserting confusion data into each target position;
the adjusting unit is configured to adjust the order of the file data in the first audio file according to the target rule to obtain a second audio file, where the adjusting the order of the file data in the first audio file according to the target rule to obtain the second audio file includes: splitting file data of the first audio file to obtain a plurality of first audio subfiles under the condition that the target rule is a first rule, wherein the first rule is one of a plurality of preset rules, and the plurality of preset rules are used for adjusting the sequence of the file data in the first audio file; exchanging the ith first audio subfile and the (i+1) th first audio subfile in the plurality of first audio subfiles, wherein i is an odd number and is smaller than the number of the first audio subfiles;
and the determining unit is used for determining the second audio file as a file obtained by encrypting the original audio file.
6. An audio decryption apparatus, comprising:
the device comprises an acquisition unit, a decryption unit and a storage unit, wherein the acquisition unit is used for acquiring confusion data used in the process of encrypting an original audio file, the insertion position of the confusion data and a target rule after acquiring a second audio file to be decrypted, and the second audio file is generated through the following steps: acquiring an original audio file to be encrypted; inserting confusion data into the file data of the original audio file to obtain a first audio file, wherein the data type of the confusion data is the same as the data type of the file data of the original audio file, and inserting confusion data into the file data of the original audio file to obtain the first audio file comprises the following steps: splitting file data of the original audio file to obtain a plurality of original audio subfiles, and inserting the confusion data into a target position, wherein the target position comprises: before the first original audio subfile, after the last original audio subfile and between every two adjacent original audio subfiles, or randomly determining a plurality of target positions in file data of the original audio files, and inserting confusion data into each target position; adjusting the order of the file data in the first audio file according to the target rule to obtain a second audio file, wherein the adjusting the order of the file data in the first audio file according to the target rule to obtain the second audio file comprises: splitting file data of the first audio file to obtain a plurality of first audio subfiles under the condition that the target rule is a first rule, wherein the first rule is one of a plurality of preset rules, and the plurality of preset rules are used for adjusting the sequence of the file data in the first audio file; exchanging the ith first audio subfile and the (i+1) th first audio subfile in the plurality of first audio subfiles, wherein i is an odd number and is smaller than the number of the first audio subfiles; determining the second audio file as a file obtained by encrypting the original audio file, wherein the data type of the confusion data is the same as the data type of the file data of the original audio file;
the adjusting unit is used for reversely adjusting the sequence of the file data in the second audio file according to the target rule to obtain the first audio file;
and the deleting unit is used for deleting the confusion data in the first audio file according to the insertion position of the confusion data to obtain the original audio file.
CN202010318428.6A 2020-04-21 2020-04-21 Audio encryption method and device, storage medium and electronic device Active CN111506913B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010318428.6A CN111506913B (en) 2020-04-21 2020-04-21 Audio encryption method and device, storage medium and electronic device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010318428.6A CN111506913B (en) 2020-04-21 2020-04-21 Audio encryption method and device, storage medium and electronic device

Publications (2)

Publication Number Publication Date
CN111506913A CN111506913A (en) 2020-08-07
CN111506913B true CN111506913B (en) 2024-03-15

Family

ID=71877875

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010318428.6A Active CN111506913B (en) 2020-04-21 2020-04-21 Audio encryption method and device, storage medium and electronic device

Country Status (1)

Country Link
CN (1) CN111506913B (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114039959B (en) * 2021-11-05 2024-04-09 北京奇艺世纪科技有限公司 TS stream transmission method and device

Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
EP1244267A2 (en) * 2000-12-21 2002-09-25 Yasumasa Uyama Protected communication system
CN103079196A (en) * 2013-01-11 2013-05-01 广东欧珀移动通信有限公司 Call encryption method and terminal
CN104091129A (en) * 2014-06-26 2014-10-08 腾讯科技(深圳)有限公司 Data processing method and device
CN104243166A (en) * 2014-09-05 2014-12-24 深圳市中兴移动通信有限公司 Recording encryption method and device
US9223995B1 (en) * 2013-12-10 2015-12-29 Progress Software Corporation Semantic obfuscation of data in real time
CN107092815A (en) * 2017-03-31 2017-08-25 武汉斗鱼网络科技有限公司 The method and server of a kind of protection module file
CN109194618A (en) * 2018-08-02 2019-01-11 广东浪潮大数据研究有限公司 A kind of file encrypting method, document encrypting apparatus and file encryption equipment
US10410000B1 (en) * 2017-12-29 2019-09-10 Entefy Inc. System and method of applying adaptive privacy control regions to bitstream data
CN110929270A (en) * 2019-10-29 2020-03-27 北京芯盾集团有限公司 Information security encryption method and device

Patent Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
EP1244267A2 (en) * 2000-12-21 2002-09-25 Yasumasa Uyama Protected communication system
CN103079196A (en) * 2013-01-11 2013-05-01 广东欧珀移动通信有限公司 Call encryption method and terminal
US9223995B1 (en) * 2013-12-10 2015-12-29 Progress Software Corporation Semantic obfuscation of data in real time
CN104091129A (en) * 2014-06-26 2014-10-08 腾讯科技(深圳)有限公司 Data processing method and device
CN104243166A (en) * 2014-09-05 2014-12-24 深圳市中兴移动通信有限公司 Recording encryption method and device
CN107092815A (en) * 2017-03-31 2017-08-25 武汉斗鱼网络科技有限公司 The method and server of a kind of protection module file
US10410000B1 (en) * 2017-12-29 2019-09-10 Entefy Inc. System and method of applying adaptive privacy control regions to bitstream data
CN109194618A (en) * 2018-08-02 2019-01-11 广东浪潮大数据研究有限公司 A kind of file encrypting method, document encrypting apparatus and file encryption equipment
CN110929270A (en) * 2019-10-29 2020-03-27 北京芯盾集团有限公司 Information security encryption method and device

Non-Patent Citations (4)

* Cited by examiner, † Cited by third party
Title
张东 ; 陈晨 ; .基于Speex编码的网络通话语音加密方法实现.通信技术.2014,(第12期),全文. *
施化吉 ; 周新法 ; 李星毅 ; 丁秋林 ; .同步数字音频盲水印.吉林大学学报(信息科学版).2006,(第01期),全文. *
李新天 ; 刘国勤 ; 王庆福 ; 杜栓平 ; .基于三重数据加密标准的目标数据保密技术.声学与电子工程.2008,(第03期),全文. *
黄超 ; .多媒体信息隐藏技术研究与应用.科技资讯.2016,(第05期),全文. *

Also Published As

Publication number Publication date
CN111506913A (en) 2020-08-07

Similar Documents

Publication Publication Date Title
CN113032357B (en) File storage method, device and server
US9037870B1 (en) Method and system for providing a rotating key encrypted file system
CN106209739A (en) Cloud storage method and system
CN112074889B (en) Hidden search device and hidden search method
CN109428710A (en) Data transmission method, device, storage medium and processor
CN111970304A (en) Message processing method and device
CN109151507B (en) Video playing system and method
CN111917555B (en) Data processing method and device
CN109218291B (en) Data transfer method, system and related equipment based on block chain
CN110598427B (en) Data processing method, system and storage medium
CN111586050A (en) Audio file transmission method and device, storage medium and electronic equipment
CN108777685B (en) Method and apparatus for processing information
CN106303615A (en) Play the methods, devices and systems of video
CN114286131A (en) Transmission method and device for anchor image model file in live broadcast wheat
CN114285575A (en) Image encryption and decryption method and device, storage medium and electronic device
CN113645025A (en) Data encryption storage method, storage device, user equipment and storage medium
CN112883388B (en) File encryption method and device, storage medium and electronic device
CN108846671B (en) Online secure transaction method and system based on block chain
CN111506913B (en) Audio encryption method and device, storage medium and electronic device
CN110719526B (en) Video playing method and device
CN111490880A (en) File receiving method and device
CN111083129A (en) Data secure transmission method, heterogeneous data transmission layer and system
CN112733684B (en) Fingerprint recognition method and device
CN111414341B (en) Data normalization description method in Internet of things environment
KR101913497B1 (en) Method for encryption key management for deduplication

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant