[go: up one dir, main page]

CN114282246B - Audio file encryption processing method, device, storage medium and equipment - Google Patents

Audio file encryption processing method, device, storage medium and equipment Download PDF

Info

Publication number
CN114282246B
CN114282246B CN202111621065.4A CN202111621065A CN114282246B CN 114282246 B CN114282246 B CN 114282246B CN 202111621065 A CN202111621065 A CN 202111621065A CN 114282246 B CN114282246 B CN 114282246B
Authority
CN
China
Prior art keywords
encrypted
packet data
audio file
data
sampling
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
CN202111621065.4A
Other languages
Chinese (zh)
Other versions
CN114282246A (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.)
China Telecom Corp Ltd
Original Assignee
China Telecom Corp 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 China Telecom Corp Ltd filed Critical China Telecom Corp Ltd
Priority to CN202111621065.4A priority Critical patent/CN114282246B/en
Publication of CN114282246A publication Critical patent/CN114282246A/en
Application granted granted Critical
Publication of CN114282246B publication Critical patent/CN114282246B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Landscapes

  • Data Exchanges In Wide-Area Networks (AREA)
  • Storage Device Security (AREA)

Abstract

The invention discloses an encryption processing method, device, storage medium and equipment for an audio file. The method comprises the steps of obtaining a plurality of encrypted data blocks in an original audio file, dividing each encrypted data block into a plurality of encrypted packet data, wherein each encrypted packet data comprises a plurality of sampling values, and performing position exchange processing on the plurality of sampling values in each encrypted packet data, and then performing position exchange processing on the plurality of encrypted packet data in each encrypted data block to obtain the encrypted audio file. The invention solves the technical problems of single algorithm or higher operation complexity in the encryption algorithm in the prior art.

Description

Encryption processing method and device for audio files, storage medium and equipment
Technical Field
The present invention relates to the field of media file encryption and decryption technologies, and in particular, to an audio file encryption processing method, device, storage medium, and apparatus.
Background
In order to protect audio content from being stolen when transmitting, recording and storing audio files, a receiver user generally needs to encrypt the transmitted audio files, and after receiving the audio files transmitted by the sender user, the receiver user decrypts and plays the audio files.
In the prior art, the encryption mode for the audio file comprises a stream encryption algorithm with too single secret key and algorithm, a complete encryption algorithm with high operation complexity and a layered encryption algorithm, wherein the stream encryption algorithm is too simple and has low security, the calculation processes of the complete encryption algorithm and the layered encryption algorithm are complex, and inconvenience is brought to users.
In view of the above problems, no effective solution has been proposed at present.
Disclosure of Invention
The embodiment of the invention provides an encryption processing method, device, storage medium and equipment for an audio file, which at least solve the technical problems that an encryption algorithm in the prior art is too single in algorithm or high in operation complexity.
According to one aspect of the embodiment of the invention, an encryption processing method of an audio file is provided, which comprises the steps of obtaining a plurality of encryption data blocks in an original audio file, dividing each encryption data block into a plurality of encryption packet data, wherein each encryption packet data comprises a plurality of sampling values, and performing position exchange processing on the plurality of sampling values in each encryption packet data and then performing position exchange processing on the plurality of encryption packet data in each encryption data block to obtain an encrypted audio file.
Optionally, the obtaining the plurality of encrypted data blocks in the original audio file includes obtaining a sampling rate of the original audio file, and setting N consecutive sampling points in the original audio file as the encrypted data blocks according to the sampling rate, where each encrypted data block is divided into M encrypted packet data, and each encrypted packet data has a sampling point k=n/M.
Optionally, the method performs a position-shifting process on a plurality of sample values in each of the encrypted packet data by performing a position-shifting process on a first sample value and a kth sample value in each of the encrypted packet data, and performing a position-shifting process on a jth sample value and a kth+1 sample value in each of the encrypted packet data.
Optionally, the performing a position-shifting process on the plurality of encrypted packet data in each encrypted data block to obtain the encrypted audio file includes performing a position-shifting process on a first packet data and a W packet data in the encrypted data block, and performing a position-shifting process on an L packet data and a W-l+1 packet data in the encrypted data block to complete a position-shifting process on the W packet data, so as to obtain the encrypted audio file.
According to another aspect of the embodiment of the invention, an encryption processing device for an audio file is provided, which comprises an acquisition module for acquiring a plurality of encrypted data blocks in an original audio file, a division module for dividing each encrypted data block into a plurality of encrypted packet data, wherein each encrypted packet data comprises a plurality of sampling values, and a processing module for performing position exchange processing on the sampling values in each encrypted packet data and then performing position exchange processing on the encrypted packet data in each encrypted data block to obtain an encrypted audio file.
Optionally, the acquisition module comprises an acquisition unit and a processing unit, wherein the acquisition unit is used for acquiring the sampling rate of the original audio file, and the processing unit is used for setting continuous N sampling points in the original audio file as the encrypted data blocks according to the sampling rate, wherein each encrypted data block is divided into M encrypted packet data, and each encrypted packet data has sampling points K=N/M.
Optionally, the device performs a position-shifting process on a plurality of sampling values in each of the encrypted packet data by performing a position-shifting process on a first sampling value and a kth sampling value in each of the encrypted packet data, and performing a position-shifting process on a jth sampling value and a kth+1 sampling value in each of the encrypted packet data.
Optionally, the processing module is further configured to perform a position exchange on the first packet data and the W packet data in the encrypted data block, and perform a position exchange on the L packet data and the W-l+1 packet data in the encrypted data block, so as to complete a position exchange process of the W packet data, thereby obtaining the encrypted audio file.
According to another aspect of the embodiments of the present invention, there is also provided a computer readable storage medium storing a plurality of instructions adapted to be loaded by a processor and to perform any one of the above-described encryption processing methods of an audio file.
According to another aspect of the embodiments of the present invention, there is also provided an electronic device including a memory, in which a computer program is stored, and a processor configured to run the computer program to perform the encryption processing method of an audio file described in any one of the above.
In the embodiment of the invention, the encrypted data blocks in the original audio file are obtained, each encrypted data block is divided into a plurality of encrypted packet data, wherein each encrypted packet data comprises a plurality of sampling values, after the position exchange processing is carried out on the sampling values in each encrypted packet data, the position exchange processing is carried out on the encrypted packet data in each encrypted data block, so that the encrypted audio file is obtained, the purpose of encrypting the file through the position exchange is achieved, the technical effect of double encryption is achieved under the condition of less calculation amount, and the technical problem that the encryption algorithm in the prior art is too single in algorithm or higher in operation complexity is solved.
Drawings
The accompanying drawings, which are included to provide a further understanding of the application and are incorporated in and constitute a part of this specification, illustrate embodiments of the application and together with the description serve to explain the application and do not constitute a limitation on the application. In the drawings:
FIG. 1 is a flow chart of an encryption processing method of an audio file according to an embodiment of the present invention;
FIG. 2 is a schematic diagram of an alternative simple pendulum reciprocation model according to an embodiment of the present invention;
FIG. 3 is a schematic diagram of an alternative original audio file according to an embodiment of the present invention;
FIG. 4 is a schematic diagram of an alternative encrypted audio file according to an embodiment of the present invention;
FIG. 5 is a schematic diagram of an alternate encryption flow of an audio file in accordance with an embodiment of the present invention;
fig. 6 is a schematic diagram of an encryption processing apparatus for an audio file 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.
Example 1
According to an embodiment of the present invention, there is provided an embodiment of an encryption processing method for an audio file, it should be noted that the steps shown in the flowchart of the drawings may be performed in a computer system such as a set of computer executable instructions, and that although a logical order is shown in the flowchart, in some cases, the steps shown or described may be performed in an order different from that herein.
Fig. 1 is a flowchart of an encryption processing method of an audio file according to an embodiment of the present invention, as shown in fig. 1, the method includes the steps of:
Step S102, a plurality of encrypted data blocks in an original audio file are obtained;
step S104, dividing each encrypted data block into a plurality of encrypted packet data, wherein each encrypted packet data comprises a plurality of sampling values;
step S106, after the position exchange processing is performed on the plurality of sampling values in each encrypted packet data, the position exchange processing is performed on the plurality of encrypted packet data in each encrypted data block, so as to obtain the encrypted audio file.
In the embodiment of the invention, the execution main body of the encryption processing scheme of the audio file provided in the steps S102 to S106 is a server, the server is adopted to obtain a plurality of encrypted data blocks in the original audio file, the encrypted data blocks are subjected to grouping processing to obtain encrypted grouping data, a plurality of sampling values exist in each encrypted grouping data, in the encryption process, the plurality of sampling values in the encrypted grouping data are subjected to position exchange processing to obtain encrypted grouping data, the encrypted grouping data are subjected to position exchange processing to obtain the encrypted data blocks, and the encrypted audio file is finally obtained after the two different-level position exchange processing.
It should be noted that the server may be built in the sending end of the audio file, and the server may encrypt data by adopting the steps after obtaining the audio file from the sending end, and a certain buffer area needs to be set in the encryption process, where the size of the buffer area may be set according to the actual situation, but the minimum size of the buffer area must be smaller than the size of an encrypted data block.
It should be noted that, the encryption processing method of the audio file is designed according to the motion rule of the gravity simple pendulum, as shown in the schematic diagram of the simple pendulum reciprocating motion model in fig. 2, the simple pendulum motion is a motion capable of generating reciprocating swing, and the simple pendulum is an ideal physical model which consists of an ideal pendulum ball and a cycloid.
As an alternative embodiment, as shown in FIG. 2, three points A, B, C are three points through which particles of a single pendulum pass, in the embodiment of the present invention, the pendulum length and the gravity of the single pendulum are not considered, three points A, B, C are symmetrical points with a straight line from the point B to the origin of the other end of the cycloid, and the positions of the point A and the point C are identical, so that when encryption is performed, if the obtained encrypted packet data only comprises A, B, C sampling points, the sampling values of the point A and the sampling values of the point C are subjected to position exchange, the sampling values of the point B are unchanged, and if the obtained sampling points of the encrypted packet data are even sampling points, for example, A, B, C, D sampling points are subjected to position exchange, and thus A, D position exchange and B, C position exchange are completed, and the data position exchange in the encrypted packet data can be called as a single pendulum.
Optionally, after the position exchange of the encrypted packet data is completed, continuing to use the principle to perform data position exchange on the encrypted packet data, thereby completing the position exchange of the encrypted packet data in the encrypted data block, where the position exchange of the encrypted packet data in the encrypted data block may be referred to as double simple pendulum.
As an alternative embodiment, in the decryption process, the receiving end of the audio information needs to grasp the size of each encrypted packet data and the size of the encrypted data block, and according to the size of each encrypted packet data and the size of the encrypted data block, the starting position and the ending position of each encrypted packet data in the audio file can be easily calculated, and the number of sampling points in the packet can be further calculated, and according to the reverse process of encryption, the position of the encrypted packet data is firstly exchanged, and then the data position of the sampling points in the encrypted packet data is exchanged, so as to complete the decryption work.
It should be noted that the method can be applied to, but not limited to, real-time conversation of a user, and when the real-time conversation is performed, conversation audio data can be encrypted in real time, so that the safety of the conversation of the user is improved.
The encryption algorithm is simple in calculation and has no complex calculation amount, the decryption process is simple, the encryption algorithm adopts double guarantee of double keys, and only the double keys (namely the size of each encrypted grouping data and the size of an encrypted data block) are mastered to complete audio decryption, so that the encryption security of the content of an audio file is guaranteed, the purpose of encrypting the file through position exchange is achieved, the technical effect of completing double encryption under the condition of less calculation amount is achieved, and the technical problem that the encryption algorithm in the prior art is too single in algorithm or higher in operation complexity is solved.
In an alternative embodiment, the obtaining a plurality of encrypted data blocks in the original audio file includes:
Step S202, obtaining the sampling rate of the original audio file;
Step S204, setting N consecutive sampling points in the original audio file as the encrypted data blocks according to the sampling rate, where each encrypted data block is divided into M encrypted packet data, and each encrypted packet data has a sampling point k=n/M.
In the embodiment of the invention, the method acquires a plurality of encrypted data blocks in the original audio file and completes the encrypted data grouping, acquires the sampling rate of the original audio file after the encrypted grouping data is obtained, and sets continuous N sampling points in the original audio file as the encrypted data blocks according to the sampling rate.
As an alternative embodiment, the server sets each N consecutive sampling points of the original audio file as an encrypted data block according to the sampling rate of the original audio, where each encrypted data block is divided according to a preset logic, and may be finally divided into M encrypted data packets, and each encrypted data packet has k=n/M sampling points.
It should be noted that, the preset logic, that is, a preset grouping rule, is used to divide the encrypted data block into a plurality of encrypted grouping data.
In an alternative embodiment, the method performs a position-shifting process on a plurality of sampling values in each of the encrypted packet data by:
step S302, performing position exchange on a first sampling value and a Kth sampling value in each piece of the encrypted packet data, and performing position exchange on a J-th sampling value and a Kth+1 sampling value in each piece of the encrypted packet data.
In the embodiment of the invention, firstly, a plurality of sampling values in each encrypted packet data are subjected to position exchange processing, and the first sampling value and the Kth sampling value in each encrypted packet data are subjected to position exchange, and the J-th sampling value and the Kth+1 sampling value in each encrypted packet data are subjected to position exchange.
As an alternative embodiment, as shown in the original audio file structure schematic diagram in fig. 3, in each encrypted packet data, the first sampling point and the kth sampling point are subjected to position exchange, and the positions of the jth sampling point and the kth-j+1 sampling point are subjected to exchange, so that the first encryption is completed, and the encrypted audio file structure schematic diagram in fig. 4 is obtained.
It should be noted that, if the audio file size is 8bit, that is, the sampling value of each sampling point is a byte value, the 1 st byte of data and the K-j+1 th byte of data in each group may be exchanged. If the audio file size is 16bit, each sampling point is 16bit, that is, a double-byte value, and each position exchange is performed with two bytes.
In an alternative embodiment, the performing a position-shifting process on the plurality of encrypted packet data in each encrypted data block to obtain the encrypted audio file includes:
and step S402, performing position exchange on the first packet data and the W-th packet data in the encrypted data block, and performing position exchange on the L-th packet data and the W-L+1-th packet data in the encrypted data block to complete position exchange processing of the W-th packet data, thereby obtaining the encrypted audio file.
In the embodiment of the present invention, similar to the above-mentioned process of performing the position-shifting process on the plurality of sampling values in each of the encrypted packet data, the position-shifting is performed on the first packet data and the W-th packet data in the encrypted data block, and the position-shifting is performed on the L-th packet data and the W-l+1-th packet data in the encrypted data block, so as to complete the position-shifting process on the W packet data, and obtain the encrypted audio file.
As an alternative embodiment, if there are W encrypted packet groups in each encrypted data block, the first packet data and the W encrypted packet data are subjected to position exchange according to the simple pendulum rule, and the L packet data and the W-l+1 packet data in the encrypted data block are subjected to position exchange, so as to complete the second encryption, and the encryption process of the audio file is implemented through the two encryption steps.
Through the steps, the encryption and decryption method for changing the audio sampling point data based on the simple pendulum motion can be realized, as shown in an encryption flow diagram of the audio file in fig. 5, a server is used for receiving the audio file, an encryption database is obtained, the encryption data blocks are grouped, the sampling value in each group is subjected to position exchange, after the position exchange of the sampling value is completed, the encryption grouping data is subjected to position exchange processing in the same way, the encryption of the audio file is completed, the purpose of encrypting the file through the position exchange is achieved, the technical effect of double encryption under the condition of less calculation is realized, and the technical problem that an encryption algorithm in the prior art is too single in algorithm or higher in operation complexity is solved.
Example 2
According to an embodiment of the present invention, there is further provided an embodiment of an apparatus for implementing encryption processing of an audio file, and fig. 6 is a schematic structural diagram of an apparatus for encryption processing of an audio file according to an embodiment of the present invention, as shown in fig. 6, the apparatus includes an acquisition module 60, a dividing module 62, and a processing module 64, where:
an acquisition module 60 for acquiring a plurality of encrypted data blocks in an original audio file;
A dividing module 62, configured to divide each of the encrypted data blocks into a plurality of encrypted packet data, where each of the encrypted packet data includes a plurality of sampling values;
The processing module 64 is configured to perform a position-shifting process on the plurality of sampling values in each of the encrypted packet data, and then perform a position-shifting process on the plurality of encrypted packet data in each of the encrypted data blocks, so as to obtain an encrypted audio file.
Optionally, the acquisition module comprises an acquisition unit and a processing unit, wherein the acquisition unit is used for acquiring the sampling rate of the original audio file, and the processing unit is used for setting continuous N sampling points in the original audio file as the encrypted data blocks according to the sampling rate, wherein each encrypted data block is divided into M encrypted packet data, and each encrypted packet data has sampling points K=N/M.
Optionally, the device performs a position-shifting process on a plurality of sampling values in each of the encrypted packet data by performing a position-shifting process on a first sampling value and a kth sampling value in each of the encrypted packet data, and performing a position-shifting process on a jth sampling value and a kth+1 sampling value in each of the encrypted packet data.
Optionally, the processing module is further configured to perform a position exchange on the first packet data and the W packet data in the encrypted data block, and perform a position exchange on the L packet data and the W-l+1 packet data in the encrypted data block, so as to complete a position exchange process of the W packet data, thereby obtaining the encrypted audio file.
Here, the above-mentioned obtaining module 60, dividing module 62 and processing module 64 correspond to steps S102 to S106 in embodiment 1, and the three modules are the same as the examples and application scenarios implemented by the corresponding steps, but are not limited to those disclosed in embodiment 1 above.
It should be noted that, the preferred implementation manner of this embodiment may be referred to the related description in embodiment 1, and will not be repeated here.
According to an embodiment of the present invention, there is also provided an embodiment of a computer-readable storage medium. Alternatively, in this embodiment, the above-described computer-readable storage medium may be used to store program code executed by the encryption processing of the audio file provided in embodiment 1 described above.
Alternatively, in this embodiment, the above-mentioned computer readable storage medium may be located in any one of the computer terminals in the computer terminal group in the computer network, or in any one of the mobile terminals in the mobile terminal group.
Optionally, in this embodiment, the computer readable storage medium is configured to store program code for obtaining a plurality of encrypted data blocks in an original audio file, dividing each of the encrypted data blocks into a plurality of encrypted packet data, wherein each of the encrypted packet data includes a plurality of sample values, and performing a position-shifting process on the plurality of sample values in each of the encrypted packet data, and then performing a position-shifting process on the plurality of encrypted packet data in each of the encrypted data blocks to obtain an encrypted audio file.
Optionally, the computer readable storage medium may further execute the program code for obtaining a sampling rate of the original audio file, and setting N consecutive sampling points in the original audio file as the encrypted data blocks according to the sampling rate, wherein each of the encrypted data blocks is divided into M encrypted packet data, and each of the encrypted packet data has a sampling point k=n/M.
Optionally, the computer readable storage medium may further carry out program code for performing a position swap on a first sample value and a Kth sample value in each of the encrypted packet data, and performing a position swap on a J-th sample value and a K-J+1-th sample value in each of the encrypted packet data.
Optionally, the computer readable storage medium may further execute program code for performing a position-shifting of the first packet data and the W packet data in the encrypted data block, and performing a position-shifting of the L packet data and the W-l+1 packet data in the encrypted data block to complete a position-shifting process of the W packet data, to obtain the encrypted audio file.
According to an embodiment of the present invention, there is also provided an embodiment of a processor. Alternatively, in this embodiment, the above-described computer-readable storage medium may be used to store program code executed by the encryption processing of the audio file provided in embodiment 1 described above.
The embodiment of the application provides electronic equipment, which comprises a processor, a memory and a program stored in the memory and capable of running on the processor, wherein when the processor executes the program, the processor realizes the following steps of acquiring a plurality of encrypted data blocks in an original audio file, dividing each encrypted data block into a plurality of encrypted packet data, wherein each encrypted packet data comprises a plurality of sampling values, and after the position of the sampling values in each encrypted packet data is changed, the position of the encrypted packet data in each encrypted data block is changed to obtain the encrypted audio file.
Optionally, the electronic device may further execute program code for obtaining a sampling rate of the original audio file, and setting N consecutive sampling points in the original audio file as the encrypted data blocks according to the sampling rate, where each encrypted data block is divided into M encrypted packet data, and each encrypted packet data has a sampling point k=n/M.
Optionally, the electronic device may further execute program code for performing a position swap on a first sample value and a kth sample value in each of the encrypted packet data, and performing a position swap on a J-th sample value and a K-j+1-th sample value in each of the encrypted packet data.
Optionally, the electronic device may further execute program code for performing a position exchange on the first packet data and the W packet data in the encrypted data block, and performing a position exchange on the L packet data and the W-l+1 packet data in the encrypted data block to complete a position exchange process on the W packet data, so as to obtain the encrypted audio file.
The application also provides a computer program product which is suitable for executing a program initialized with the following method steps when being executed on a data processing device, wherein the program is used for acquiring a plurality of encrypted data blocks in an original audio file, dividing each encrypted data block into a plurality of encrypted packet data, wherein each encrypted packet data comprises a plurality of sampling values, and after the sampling values in each encrypted packet data are subjected to position exchange processing, the encrypted packet data in each encrypted data block are subjected to position exchange processing, so that the encrypted audio file is obtained.
The foregoing embodiment numbers of the present invention are merely for the purpose of description, and do not represent the advantages or disadvantages of the embodiments.
In the foregoing embodiments of the present invention, the descriptions of the embodiments are emphasized, and for a portion of this disclosure that is not described in detail in this embodiment, reference is made to the related descriptions of other embodiments.
In the several embodiments provided in the present application, it should be understood that the disclosed technology may be implemented in other manners. The above-described embodiments of the apparatus are merely exemplary, and the division of the units, for example, may be a logic function division, and may be implemented in another manner, for example, a plurality of units or components may be combined or may be 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 parts may or may not be physically separate, and parts displayed as units may or may not be physical units, may be located in one place, or may be distributed on a plurality of 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 integrated units, if implemented in the form of software functional units and sold or used as stand-alone products, may be stored in a computer readable storage medium. Based on such understanding, the technical solution of the present invention may be embodied essentially or in part or all of the technical solution or in part in the form of a software product stored in a storage medium, including instructions for causing a computer device (which may be a personal computer, a server, or a network device, etc.) to perform all or part of the steps of the method according to the embodiments of the present invention. The storage medium includes a U disk, a Read-Only Memory (ROM), a random access Memory (RAM, random Access Memory), a removable hard disk, a magnetic disk, or an optical disk, etc. which can store the program code.
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 (4)

1. An encryption processing method for an audio file, comprising:
Acquiring a plurality of encrypted data blocks in an original audio file;
Dividing each encrypted data block into a plurality of encrypted packet data, wherein each encrypted packet data comprises a plurality of sampling values;
After carrying out position exchange processing on a plurality of sampling values in each encrypted packet data, carrying out position exchange processing on a plurality of encrypted packet data in each encrypted data block to obtain an encrypted audio file;
Setting continuous N sampling points in the original audio file as the encrypted data blocks according to the sampling rate, wherein each encrypted data block is divided into M encrypted packet data, and the sampling point K=N/M possessed by each encrypted packet data;
The method comprises the following steps of performing position exchange processing on a plurality of sampling values in each encrypted packet data, namely performing position exchange on a first sampling value and a Kth sampling value in each encrypted packet data, and performing position exchange on a J-th sampling value and a K-J+1-th sampling value in each encrypted packet data;
The method comprises the steps of carrying out position exchange processing on a plurality of encrypted packet data in each encrypted data block to obtain the encrypted audio file, wherein the step of carrying out position exchange on the first packet data and the W-th packet data in the encrypted data block, and the step of carrying out position exchange on the L-th packet data and the W-L+1-th packet data in the encrypted data block to complete the position exchange processing on the W-th packet data to obtain the encrypted audio file.
2. An encryption processing apparatus for an audio file, comprising:
The acquisition module is used for acquiring a plurality of encrypted data blocks in an original audio file, wherein the acquisition of the plurality of encrypted data blocks in the original audio file comprises the steps of acquiring the sampling rate of the original audio file, setting continuous N sampling points in the original audio file as the encrypted data blocks according to the sampling rate, wherein each encrypted data block is divided into M encrypted grouping data, and the sampling point K=N/M possessed by each encrypted grouping data;
The dividing module is used for dividing each encrypted data block into a plurality of encrypted packet data, wherein each encrypted packet data comprises a plurality of sampling values;
The processing module is used for carrying out position exchange processing on a plurality of sampling values in each encrypted packet data, carrying out position exchange processing on a plurality of encrypted packet data in each encrypted data block to obtain an encrypted audio file, wherein the position exchange processing is carried out on a plurality of sampling values in each encrypted packet data in a manner that a first sampling value and a Kth sampling value in each encrypted packet data are subjected to position exchange, and a J-th sampling value and a Kth+1th sampling value in each encrypted packet data are subjected to position exchange, the position exchange processing is carried out on a plurality of encrypted packet data in each encrypted data block to obtain the encrypted audio file, and the method comprises the steps of carrying out position exchange on a first packet data and a W-th packet data in the encrypted data block, and carrying out position exchange on a L-th packet data and a W-L+1-th packet data in the encrypted data block to complete the position exchange of the W-th packet data to obtain the encrypted audio file.
3. A computer readable storage medium storing a plurality of instructions adapted to be loaded by a processor and to perform the method of encrypting an audio file of claim 1.
4. An electronic device comprising a memory and a processor, characterized in that the memory has stored therein a computer program, the processor being arranged to run the computer program to perform the encryption processing method of an audio file according to claim 1.
CN202111621065.4A 2021-12-27 2021-12-27 Audio file encryption processing method, device, storage medium and equipment Active CN114282246B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202111621065.4A CN114282246B (en) 2021-12-27 2021-12-27 Audio file encryption processing method, device, storage medium and equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202111621065.4A CN114282246B (en) 2021-12-27 2021-12-27 Audio file encryption processing method, device, storage medium and equipment

Publications (2)

Publication Number Publication Date
CN114282246A CN114282246A (en) 2022-04-05
CN114282246B true CN114282246B (en) 2025-01-03

Family

ID=80876798

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202111621065.4A Active CN114282246B (en) 2021-12-27 2021-12-27 Audio file encryption processing method, device, storage medium and equipment

Country Status (1)

Country Link
CN (1) CN114282246B (en)

Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113411326A (en) * 2021-06-17 2021-09-17 上海明略人工智能(集团)有限公司 Method and device for audio encryption, electronic equipment, system and readable storage medium

Family Cites Families (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
TW242206B (en) * 1993-08-27 1995-03-01 At & T Corp
CN108156056B (en) * 2017-12-28 2021-07-09 华为技术有限公司 Network quality measurement method and device

Patent Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113411326A (en) * 2021-06-17 2021-09-17 上海明略人工智能(集团)有限公司 Method and device for audio encryption, electronic equipment, system and readable storage medium

Also Published As

Publication number Publication date
CN114282246A (en) 2022-04-05

Similar Documents

Publication Publication Date Title
EP3178190B1 (en) Encoder, decoder and method
CN110266682B (en) Data encryption method, device, mobile terminal and decryption method
CN113987583B (en) Hidden query method and system
CN105320613B (en) System and method for dynamic data storage
WO2012071725A1 (en) Method and apparatus for data selective encryption and decryption
CN111310222A (en) File encryption method
CN113987584B (en) Hidden query method and system
CN104184740A (en) Credible transmission method, credible third party and credible transmission system
CN101969545A (en) Encryption method and device of multimedia file
CN108737353B (en) Data encryption method and device based on data analysis system
CN112491532A (en) Video data encryption method and device, storage medium and electronic equipment
JP2003234732A5 (en)
CN103313097B (en) Method and system for encrypting and decrypting encoded file
CN109450960A (en) Processing method, device, equipment, system and the medium of IPsec agreement
CN116545990A (en) A method and system for storing recorded audio and video
WO2023059501A1 (en) Statistically private oblivious transfer from cdh
CN104394161A (en) Algorithm reconstruction mechanism based secret key transmission method and system
Rani et al. AES+: A Modified AES Encryption with Enhanced Key Management and Distribution
CN114282246B (en) Audio file encryption processing method, device, storage medium and equipment
CN113938882B (en) Encryption and decryption method and device for wireless local area network communication system
CN114390317A (en) Encryption method and system for streaming video
CN105959106B (en) A kind of low-complexity digital encryption method
CN110730366B (en) Bit operation-based lightweight video stream encryption and decryption method and encryption and decryption method
CN118138337A (en) Encrypted transmission method, device, computer equipment and storage medium
CN106878299A (en) A voice encryption and decryption method and device

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