CN109493875B - Audio watermark adding and extracting method and terminal equipment - Google Patents
Audio watermark adding and extracting method and terminal equipment Download PDFInfo
- Publication number
- CN109493875B CN109493875B CN201811187250.5A CN201811187250A CN109493875B CN 109493875 B CN109493875 B CN 109493875B CN 201811187250 A CN201811187250 A CN 201811187250A CN 109493875 B CN109493875 B CN 109493875B
- Authority
- CN
- China
- Prior art keywords
- signal
- bit
- watermark
- value corresponding
- 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
Links
- 238000000034 method Methods 0.000 title claims abstract description 34
- 230000005236 sound signal Effects 0.000 claims description 92
- 239000011159 matrix material Substances 0.000 claims description 50
- 238000004590 computer program Methods 0.000 claims description 24
- 238000007493 shaping process Methods 0.000 claims description 23
- 238000013507 mapping Methods 0.000 claims description 22
- 238000013139 quantization Methods 0.000 claims description 8
- 238000004364 calculation method Methods 0.000 claims description 6
- 238000010586 diagram Methods 0.000 description 8
- 238000006243 chemical reaction Methods 0.000 description 7
- 230000006870 function Effects 0.000 description 6
- 238000004422 calculation algorithm Methods 0.000 description 5
- 238000000605 extraction Methods 0.000 description 4
- 230000009286 beneficial effect Effects 0.000 description 3
- 238000012986 modification Methods 0.000 description 1
- 230000004048 modification Effects 0.000 description 1
- 230000035515 penetration Effects 0.000 description 1
- 238000012847 principal component analysis method Methods 0.000 description 1
- 238000006467 substitution reaction Methods 0.000 description 1
Images
Classifications
-
- G—PHYSICS
- G10—MUSICAL INSTRUMENTS; ACOUSTICS
- G10L—SPEECH ANALYSIS TECHNIQUES OR SPEECH SYNTHESIS; SPEECH RECOGNITION; SPEECH OR VOICE PROCESSING TECHNIQUES; SPEECH OR AUDIO CODING OR DECODING
- G10L19/00—Speech or audio signals analysis-synthesis techniques for redundancy reduction, e.g. in vocoders; Coding or decoding of speech or audio signals, using source filter models or psychoacoustic analysis
- G10L19/018—Audio watermarking, i.e. embedding inaudible data in the audio signal
-
- Y—GENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
- Y02—TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
- Y02D—CLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
- Y02D30/00—Reducing energy consumption in communication networks
- Y02D30/70—Reducing energy consumption in communication networks in wireless communication networks
Landscapes
- Engineering & Computer Science (AREA)
- Computational Linguistics (AREA)
- Signal Processing (AREA)
- Health & Medical Sciences (AREA)
- Audiology, Speech & Language Pathology (AREA)
- Human Computer Interaction (AREA)
- Physics & Mathematics (AREA)
- Acoustics & Sound (AREA)
- Multimedia (AREA)
- Signal Processing For Digital Recording And Reproducing (AREA)
- Editing Of Facsimile Originals (AREA)
Abstract
The invention is suitable for the technical field of data processing, and provides an audio watermark adding method and terminal equipment.
Description
Technical Field
The invention belongs to the technical field of data processing, and particularly relates to an audio watermark adding and extracting method and terminal equipment.
Background
In recent years, along with the continuous penetration of the mobile internet into our lives, digital information represented by audio, video and pictures is greatly enriched, and people can conveniently create, acquire and spread the digital information.
But with this, the risk of theft of such digitized information has increased greatly, and there is a current need for related technical means to protect the copyright of the creator. At present, the mark of the original audio is easy to be tampered maliciously, and the tampered problem is difficult to be identified.
Disclosure of Invention
In view of the above, the embodiments of the present invention provide an audio watermark adding and extracting method and a terminal device, so as to solve the problem in the prior art that a mark for a genuine audio is easy to be tampered maliciously, and is difficult to identify the tampered mark.
A first aspect of an embodiment of the present invention provides a method for adding an audio watermark, including:
acquiring data of an original audio signal and an audio watermark, and encrypting the data of the audio watermark to generate an encrypted signal;
shaping the encrypted signal according to the original audio signal to generate a standard signal;
and adding the standard signal into the original audio signal according to the original audio signal and the numerical value corresponding to each bit in the standard signal, and generating an embedded signal added with the audio watermark.
A second aspect of an embodiment of the present invention provides a method for extracting an audio watermark, including:
acquiring an original audio signal and an embedded signal, wherein the embedded signal contains data of an audio watermark; extracting a standard signal from the embedded signal according to the original audio signal and the numerical value corresponding to each bit in the embedded signal; and shaping the standard signal according to the original audio signal, generating an encrypted signal, and decrypting the encrypted signal to obtain the data of the audio watermark.
A third aspect of the embodiment of the present invention provides a terminal device, including a memory and a processor, where the memory stores a computer program that can run on the processor, and when the processor executes the computer program, the following steps are implemented:
acquiring data of an original audio signal and an audio watermark, and encrypting the data of the audio watermark to generate an encrypted signal; shaping the encrypted signal according to the original audio signal to generate a standard signal; and adding the standard signal into the original audio signal according to the original audio signal and the numerical value corresponding to each bit in the standard signal, and generating an embedded signal added with the audio watermark.
A fourth aspect of the embodiment of the present invention provides a terminal device, including a memory and a processor, where the memory stores a computer program executable on the processor, and when the processor executes the computer program, the processor implements the following steps:
acquiring an original audio signal and an embedded signal, wherein the embedded signal contains data of an audio watermark; extracting a standard signal from the embedded signal according to the original audio signal and the numerical value corresponding to each bit in the embedded signal; and shaping the standard signal according to the original audio signal, generating an encrypted signal, and decrypting the encrypted signal to obtain the data of the audio watermark.
A fifth aspect of the embodiments of the present invention provides a computer readable storage medium storing a computer program which when executed by a processor performs the steps of:
acquiring data of an original audio signal and an audio watermark, and encrypting the data of the audio watermark to generate an encrypted signal; shaping the encrypted signal according to the original audio signal to generate a standard signal; and adding the standard signal into the original audio signal according to the original audio signal and the numerical value corresponding to each bit in the standard signal, and generating an embedded signal added with the audio watermark.
A sixth aspect of the embodiments of the present invention provides a computer readable storage medium storing a computer program which when executed by a processor performs the steps of:
acquiring an original audio signal and an embedded signal, wherein the embedded signal contains data of an audio watermark; extracting a standard signal from the embedded signal according to the original audio signal and the numerical value corresponding to each bit in the embedded signal; and shaping the standard signal according to the original audio signal, generating an encrypted signal, and decrypting the encrypted signal to obtain the data of the audio watermark.
In the embodiment of the invention, the data of the audio watermark is encrypted to generate an encrypted signal in the process of adding the audio watermark, the encrypted signal is shaped according to the acquired original audio signal to generate a standard signal, the standard signal is added into the original audio signal according to the original audio signal and the numerical value corresponding to each bit in the standard signal to generate an embedded signal, so that the data of the audio watermark in the embedded signal can be compared with the original audio watermark by comparing the audio watermark extracted from the embedded signal after the embedded signal is changed, and the situation that the original audio data is tampered can be accurately identified.
Drawings
In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the drawings that are needed in the embodiments or the description of the prior art will be briefly described below, it being obvious that the drawings in the following description are only some embodiments of the present invention, and that other drawings may be obtained according to these drawings without inventive effort for a person skilled in the art.
Fig. 1 is a flowchart of an implementation of an audio watermark adding method provided by an embodiment of the present invention;
fig. 2 is a flowchart of a specific implementation of an audio watermark adding method S101 according to an embodiment of the present invention;
fig. 3 is a flowchart of an implementation of an audio watermark extraction method provided by an embodiment of the present invention;
fig. 4 is a block diagram of an audio watermark adding apparatus according to an embodiment of the present invention;
fig. 5 is a block diagram of an audio watermark extraction apparatus according to an embodiment of the present invention;
fig. 6 is a schematic diagram of a terminal device according to an embodiment of the present invention;
fig. 7 is a schematic diagram of another terminal device according to an embodiment of the present invention;
Detailed Description
In the following description, for purposes of explanation and not limitation, specific details are set forth such as the particular system architecture, techniques, etc., in order to provide a thorough understanding of the embodiments of the present invention. It will be apparent, however, to one skilled in the art that the present invention may be practiced in other embodiments that depart from these specific details. In other instances, detailed descriptions of well-known systems, devices, circuits, and methods are omitted so as not to obscure the description of the present invention with unnecessary detail.
In order to illustrate the technical scheme of the invention, the following description is made by specific examples.
Fig. 1 shows an implementation flow of an audio watermark adding method provided by an embodiment of the present invention, where the method flow includes steps S101 to S103. The specific implementation principle of each step is as follows.
S101, acquiring data of an original audio signal and an audio watermark, and encrypting the data of the audio watermark to generate an encrypted signal.
In the embodiment of the invention, two data, namely the data of the original audio signal and the data of the audio watermark, are firstly acquired, and the data of the audio watermark is added into the original audio signal after a series of calculations, so as to generate an embedded signal added with the audio watermark.
In the embodiment of the invention, considering that the audio watermark is stolen, if the audio watermark is stolen, any stolen audio watermark can be added into the tampered original audio signal after the original audio signal is tampered, so that a right maintainer of the original audio signal is difficult to judge or prove whether an embedded signal generated based on the tampered original audio signal is the original embedded signal. Based on the above, the embodiment of the invention needs to encrypt the data of the audio watermark according to a specific preset encryption algorithm to generate an encrypted signal which can be used for representing the audio watermark so as to ensure the security of the data of the audio watermark.
Optionally, if the data of the audio watermark is encrypted according to a specific preset encryption algorithm to generate a multidimensional matrix, the multidimensional matrix needs to be converted into a one-dimensional binary sequence as an encrypted signal by a principal component analysis method.
S102, shaping the encrypted signal according to the original audio signal to generate a standard signal.
In the embodiment of the invention, the original audio signal and the digital signal are frequency domain, the encrypted signal is a one-dimensional binary sequence, and the number of bits of the characters of the original audio signal is larger than the number of bits of the characters in the sequence of the encrypted signal in the embodiment of the invention.
It will be appreciated that shaping the encrypted signal facilitates the addition of the encrypted signal to the original audio signal in a subsequent step, the particular shaping process comprising:
zero padding is performed at the tail of the encrypted signal until the bit number of the encrypted signal after bit padding is equal to the bit number of the original audio signal;
through a preset shaping formula:shaping the encrypted signal to generate a standard signal; the Sig' [ t ]]For the value corresponding to the t-th bit of the standard signal, the +.>Is a preset calculation factor; the OriSig [ t ]]For the value corresponding to the t-th bit of the original audio signal, the Sig [ t ]]And the value corresponding to the t bit of the encrypted signal after the bit compensation is given.
And S103, adding the standard signal into the original audio signal according to the original audio signal and the numerical value corresponding to each bit in the standard signal, and generating an embedded signal added with the audio watermark.
Optionally, in the embodiment of the present invention, the preset embedding formula is adopted:and calculating the numerical value corresponding to each bit in the embedded signal. Wherein, operator->Representing a downscaling operation, stepsize representing a preset quantization step, D (i) representing a value corresponding to the ith bit in the embedded signal, F (i) representing a value corresponding to the ith bit in the original audio signal, sig' [ t ]]And representing the value corresponding to the ith bit in the standard signal.
It will be appreciated that according to the algorithm for generating an embedded signal described above, when the value corresponding to the ith bit in the standard signal is 0, the algorithm is implemented byCalculating a value corresponding to the ith bit of the embedded signal; when the value corresponding to the i-th bit in the standard signal is 1, the signal is obtained by +.> And calculating the value corresponding to the ith bit of the embedded signal.
It may be appreciated that in the embodiment of the present invention, in the process of adding an audio watermark, data of the audio watermark is encrypted to generate an encrypted signal, the encrypted signal is shaped according to the obtained original audio signal to generate a standard signal, and then the standard signal is added into the original audio signal according to the original audio signal and values corresponding to each bit in the standard signal to generate an embedded signal, so that the embedded signal contains the data of the audio watermark, and after the embedded signal is changed, the situation that the original audio data is tampered can be accurately identified by comparing the audio watermark extracted from the embedded signal with the original audio watermark.
As an embodiment of the present invention, as shown in fig. 2, S101 includes:
and S011, generating a parameter sequence through a preset numerical sequence formula.
Optionally, the preset numerical sequence formula includes: seq (seq) n+1 =index×seq n ×(1-seq n ) Said seq is n And the index is a natural number greater than 1 for the nth number in the parameter sequence, wherein the 1 st number of the parameter sequence is a preset natural number greater than 0 and less than 1.
It will be appreciated that in setting index and seq n After the 1 st digit of the number sequence, a plurality of digits which are arranged in sequence can be generated through the numerical sequence formula, so that a numerical sequence is formed, and the digits in the numerical sequence have different sizes and have no clear change trend.
S1012, numbers with the same number of characters contained in the data of the audio watermark are intercepted from the parameter sequence to be used as a selected sequence.
It will be appreciated that a number sequence of any length may be generated by the above-described number sequence formula, and in the embodiment of the present invention, only numbers equal to the number of characters contained in the data of the audio watermark need to be intercepted as the selected sequence.
S1013, converting the data of the audio watermark into a watermark matrix, and converting the selected sequence into a parameter matrix, wherein the watermark matrix is equal to the number of lines of the parameter matrix.
For example, assuming that the data of the audio watermark and the selected sequence each contain 10000 numbers, the numbers contained in the data and the selected sequence are filled into the matrix according to a preset arrangement sequence, so that a watermark matrix and a parameter matrix of 100 rows and 100 columns can be generated.
S1014, rearranging the element values according to the element values in the parameter matrix to generate a mapping matrix, and generating a position mapping rule according to the position relation between the parameter matrix and the same element values in the mapping matrix.
Illustratively, in order to more clearly clarify the generation process of the location mapping rule, a parameter matrix of 3 rows and 3 columns is used herein as an example, and it is assumed that the parameter matrix is:if the element values are rearranged from small to large according to the sizes of the element values, the generated mapping matrix is: />By comparing the parameter matrix with each element value in the mapping matrix, and associating the same positions of the element values in the two matrices, it can be known that in this example, the element value of the 1 st row and 1 st column before conversion corresponds to the element value of the 3 rd row and 2 nd column after conversion; the element values of the 1 st row and the 2 nd column before conversion correspond to the element values of the 3 rd row and the 1 st column after conversion; the element values of the 1 st row and the 3 rd column before conversion correspond to the element values of the 1 st column of the first row after conversion, and so on, 9 position mapping rules are generated.
S1015, rearranging each element value in the watermark matrix through the position mapping rule, and outputting the element values in the matrix generated after rearranging in sequence according to the arrangement order to generate an encrypted signal.
It may be appreciated that, in the above example, the location mapping rule is generated, and since in the embodiment of the present invention, the watermark matrix and the parameter matrix are equal in both rows and columns, each element value in the watermark matrix may be moved by the same location mapping rule, so as to rearrange the element values, and the rearranged elements of the matrix are sequentially output according to a preset arrangement order, so as to generate the encrypted signal.
In the embodiment of the invention, the data of the audio watermark is encrypted by the encryption method, so that an unauthorized user cannot accurately obtain the encrypted signal even if knowing the data of the audio watermark, and thus, the accurate encrypted signal cannot be filled into the tampered original audio signal after the original audio signal is tampered, thereby being beneficial to judging whether the embedded signal generated based on the original audio signal is tampered.
Fig. 3 shows an implementation flow of an audio watermark extraction method according to an embodiment of the present invention, where the method flow includes steps S301 to S303. The specific implementation principle of each step is as follows.
S301, acquiring an original audio signal and an embedded signal, wherein the embedded signal contains data of an audio watermark.
In the embodiment of the invention, when it is required to verify whether an embedded signal containing data of an audio watermark has been tampered, an original audio signal based on the process of generating the embedded signal is called.
S302, extracting a standard signal from the embedded signal according to the original audio signal and the numerical value corresponding to each bit in the embedded signal.
Optionally, the formula is calculated by preset parameters:calculating discrimination parameters corresponding to each bit in the embedded signal, wherein r (i) is the discrimination parameter corresponding to the ith bit in the embedded signal, F (i) is the numerical value corresponding to the ith bit in the original audio signal, and D (i) is the numerical value corresponding to the ith bit in the embedded signalThe value of the stepsize is a preset quantization step length, operator +.>Representing a downward rounding operation;
optionally, the watermark extraction formula is preset:calculating the value corresponding to each discrimination parameter, and arranging the values corresponding to the discrimination parameters to obtain a standard signal, wherein J (i) is the value corresponding to the ith bit of the audio watermark.
It can be understood that, in the embodiment of the present invention, if the discrimination parameter corresponding to the ith bit in the embedded signal is greater than or equal to half of the quantization step, the value corresponding to the ith bit of the audio watermark is marked as 1, otherwise, the value corresponding to the ith bit of the audio watermark is marked as 0.
S303, shaping the standard signal according to the original audio signal, generating an encrypted signal, and decrypting the encrypted signal to obtain the data of the audio watermark.
In the embodiment of the invention, the shaping formula is preset:a signal is calculated as an encrypted signal; the Sig' [ t ]]For the value corresponding to the t-th bit of the standard signal, the +.>Is a preset calculation factor; the OriSig [ t ]]For the value corresponding to the t-th bit of the original audio signal, the Sig [ t ]]And the value corresponding to the t bit of the encrypted signal after the bit compensation is given.
In the embodiment of the invention, the encrypted signal is decrypted through a preset decryption algorithm to obtain the data of the audio watermark.
Optionally, a preset position mapping rule corresponding to the original audio signal is called, the position mapping rule comprises a mapping relation of each element position of a matrix before and after conversion, each numerical value in the encrypted signal is filled into the matrix to generate an encrypted matrix, and the position of each element value in the encrypted matrix is adjusted through the position mapping rule to generate a watermark matrix; and finally, sequentially outputting each element value in the watermark matrix as the data of the audio watermark.
In the embodiment of the invention, the data support is provided for verifying whether the embedded signal is tampered by extracting the data of the audio watermark from the embedded signal, which is beneficial to protecting the intellectual property of the author of the original audio signal.
Corresponding to the method for adding an audio watermark described in the foregoing embodiments, fig. 4 shows a block diagram of an apparatus for adding an audio watermark according to an embodiment of the present invention, and for convenience of explanation, only a portion related to the embodiment of the present invention is shown.
Referring to fig. 4, the apparatus includes:
an obtaining module 401, configured to obtain an original audio signal and data of an audio watermark, and encrypt the data of the audio watermark to generate an encrypted signal;
a shaping module 402, configured to shape the encrypted signal according to the original audio signal, and generate a standard signal;
and the adding module 403 is configured to add the standard signal to the original audio signal according to the original audio signal and the numerical value corresponding to each bit in the standard signal, and generate an embedded signal to which the audio watermark is added.
The encrypting the data of the audio watermark to generate an encrypted signal comprises:
through a preset numerical sequence formula: seq (seq) n+1 =index×seq n ×(1-seq n ) Generating a parameter sequence, said seq n The index is a natural number greater than 1 for the nth number in the parameter sequence, wherein the 1 st number of the parameter sequence is a preset natural number greater than 0 and less than 1;
intercepting numbers with the same number as characters contained in the data of the audio watermark from the parameter sequence as a selected sequence;
converting the data of the audio watermark into a watermark matrix, and converting the selected sequence into a parameter matrix, wherein the watermark matrix is equal to the number of lines of the parameter matrix;
rearranging the element values according to the element values in the parameter matrix to generate a mapping matrix, and generating a position mapping rule according to the position relation between the parameter matrix and the element values which are the same in the mapping matrix;
rearranging each element value in the watermark matrix through the position mapping rule, and sequentially outputting the element values in the matrix generated after rearranging according to the arrangement sequence to generate an encrypted signal.
The shaping the encrypted signal according to the original audio signal, generating a standard signal, comprising:
zero padding is performed at the tail of the encrypted signal until the bit number of the encrypted signal after bit padding is equal to the bit number of the original audio signal;
through a preset shaping formula:shaping the encrypted signal to generate a standard signal; the Sig' [ t ]]For the value corresponding to the t-th bit of the standard signal, the +.>Is a preset calculation factor; the OriSig [ t ]]For the value corresponding to the t-th bit of the original audio signal, the Sig [ t ]]And the value corresponding to the t bit of the encrypted signal after the bit compensation is given.
The adding the standard signal into the original audio signal according to the values corresponding to each bit in the original audio signal and the standard signal, generating an embedded signal added with the audio watermark, including: through a preset embedding formula:calculating the inlayAnd inputting the value corresponding to each bit in the signal. Wherein, operator->Representing a downscaling operation, stepsize representing a preset quantization step, D (i) representing a value corresponding to the ith bit in the embedded signal, F (i) representing a value corresponding to the ith bit in the original audio signal, sig' [ t ]]And representing the value corresponding to the ith bit in the standard signal.
In the embodiment of the invention, the data of the audio watermark is encrypted to generate an encrypted signal in the process of adding the audio watermark, the encrypted signal is shaped according to the acquired original audio signal to generate a standard signal, the standard signal is added into the original audio signal according to the original audio signal and the numerical value corresponding to each bit in the standard signal to generate an embedded signal, so that the data of the audio watermark in the embedded signal can be accurately identified by comparing the audio watermark extracted from the embedded signal with the original audio watermark after the embedded signal is changed.
Corresponding to the method for extracting an audio watermark described in the above embodiments, fig. 5 shows a block diagram of an apparatus for extracting an audio watermark according to an embodiment of the present invention, and for convenience of explanation, only a portion related to the embodiment of the present invention is shown.
Referring to fig. 5, the apparatus includes:
an obtaining module 501, configured to obtain an original audio signal and an embedded signal, where the embedded signal includes data of an audio watermark;
an extracting module 502, configured to extract a standard signal from the embedded signal according to the original audio signal and a value corresponding to each bit in the embedded signal;
and the generating module 503 is configured to shape the standard signal according to the original audio signal, generate an encrypted signal, and decrypt the encrypted signal to obtain data of the audio watermark.
The extracting a standard signal from the embedded signal according to the original audio signal and the numerical value corresponding to each bit in the embedded signal includes:
and calculating a formula through preset parameters:calculating discrimination parameters corresponding to each bit in the embedded signal, wherein r (i) is the discrimination parameter corresponding to the ith bit in the embedded signal, F (i) is a value corresponding to the ith bit in the original audio signal, D (i) is a value corresponding to the ith bit in the embedded signal, and step is a preset quantization step length and an operator->Representing a downward rounding operation;
and extracting a formula through a preset watermark:calculating the value corresponding to each discrimination parameter, and arranging the values corresponding to the discrimination parameters to obtain a standard signal, wherein J (i) is the value corresponding to the ith bit of the audio watermark.
In the embodiment of the invention, the data support is provided for verifying whether the embedded signal is tampered by extracting the data of the audio watermark from the embedded signal, which is beneficial to protecting the intellectual property of the author of the original audio signal.
Fig. 6 is a schematic diagram of a terminal device according to an embodiment of the present invention. As shown in fig. 6, the terminal device 6 of this embodiment includes: a processor 60, a memory 61 and a computer program 62, such as an addition program of an audio watermark, stored in said memory 61 and executable on said processor 60. The processor 60, when executing the computer program 62, implements the steps of the respective audio watermark adding method embodiments described above, such as steps 101 to 103 shown in fig. 1. Alternatively, the processor 60, when executing the computer program 62, performs the functions of the modules/modules of the apparatus embodiments described above, such as the functions of the modules 401 through 403 shown in fig. 4.
Fig. 7 is a schematic diagram of another terminal device according to an embodiment of the present invention. As shown in fig. 7, the terminal device 7 of this embodiment includes: a processor 70, a memory 71 and a computer program 72, such as an addition program of an audio watermark, stored in said memory 71 and executable on said processor 70. The processor 70, when executing the computer program 72, implements the steps of the above-described respective embodiments of the method of adding an audio watermark, such as steps 301 to 303 shown in fig. 1. Alternatively, the processor 70, when executing the computer program 72, performs the functions of the modules/modules of the apparatus embodiments described above, such as the functions of the modules 501-503 of fig. 5.
Illustratively, the computer program 62 may be partitioned into one or more modules/modules that are stored in the memory 61 and executed by the processor 60 to accomplish the present invention. The one or more modules/modules may be a series of computer program instruction segments capable of performing the specified functions describing the execution of the computer program 62 in the terminal device 6.
The terminal devices 6 and 7 may be computing devices such as desktop computers, notebooks, palmtops, cloud terminal devices, and the like.
It will be apparent to those skilled in the art that, for convenience and brevity of description, only the above-described division of each functional module and module is illustrated, and in practical application, the above-described functional allocation may be performed by different functional modules and modules according to needs, i.e. the internal structure of the apparatus is divided into different functional modules or modules to perform all or part of the above-described functions. The functional modules and the modules in the embodiment can be integrated in one processing module, or each module can exist alone physically, or two or more modules can be integrated in one module, and the integrated modules can be realized in a form of hardware or a form of a software functional module. In addition, the specific names of the functional modules and the modules are only for convenience of distinguishing each other, and are not used for limiting the protection scope of the application. The modules in the above system, and the specific working process of the modules may refer to the corresponding process in the foregoing method embodiment, which is not described herein again.
In the foregoing embodiments, the descriptions of the embodiments are emphasized, and in part, not described or illustrated in any particular embodiment, reference is made to the related descriptions of other embodiments.
The modules described as separate components may or may not be physically separate, and components shown as modules may or may not be physical modules, i.e., may be located in one place, or may be distributed over a plurality of network modules. Some or all of the modules may be selected according to actual needs to achieve the purpose of the solution of this embodiment.
The integrated modules/modules may be stored in a computer readable storage medium if implemented in the form of software functional modules and sold or used as a stand-alone product. Based on such understanding, the present invention may implement all or part of the flow of the method of the above embodiment, or may be implemented by a computer program to instruct related hardware, where the computer program may be stored in a computer readable storage medium.
The above embodiments are only for illustrating the technical solution of the present invention, and not for limiting the same; although the invention has been described in detail with reference to the foregoing embodiments, it will be understood by those of ordinary skill in the art that: the technical scheme described in the foregoing embodiments can be modified or some technical features thereof can be replaced by equivalents; such modifications and substitutions do not depart from the spirit and scope of the technical solutions of the embodiments of the present invention, and are intended to be included in the scope of the present invention.
Claims (8)
1. A method of adding an audio watermark, comprising:
acquiring data of an original audio signal and an audio watermark, and encrypting the data of the audio watermark to generate an encrypted signal;
zero padding at the end of the encrypted signal, straightThe bit number of the encrypted signal after bit filling is equal to the bit number of the original audio signal; through a preset shaping formula:shaping the encrypted signal to generate a standard signal; the Sig ′ [t]For the value corresponding to the t-th bit of the standard signal, the +.>Is a preset calculation factor; the OriSig [ t ]]For the value corresponding to the t-th bit of the original audio signal, the Sig [ t ]]The value corresponding to the t bit of the encrypted signal after the bit compensation is given;
and adding the standard signal into the original audio signal according to the original audio signal and the numerical value corresponding to each bit in the standard signal, and generating an embedded signal added with the audio watermark.
2. The method of adding an audio watermark according to claim 1, wherein encrypting the data of the audio watermark to generate an encrypted signal comprises:
through a preset numerical sequence formula: seq (seq) n+1 =index×seq n ×(1-seq n ) Generating a parameter sequence, said seq n The index is a natural number greater than 1 for the nth number in the parameter sequence, wherein the 1 st number of the parameter sequence is a preset natural number greater than 0 and less than 1;
intercepting numbers with the same number as characters contained in the data of the audio watermark from the parameter sequence as a selected sequence;
converting the data of the audio watermark into a watermark matrix, and converting the selected sequence into a parameter matrix, wherein the watermark matrix is equal to the number of lines of the parameter matrix;
rearranging the element values according to the element values in the parameter matrix to generate a mapping matrix, and generating a position mapping rule according to the position relation between the parameter matrix and the element values which are the same in the mapping matrix;
rearranging each element value in the watermark matrix through the position mapping rule, and sequentially outputting the element values in the matrix generated after rearranging according to the arrangement sequence to generate an encrypted signal.
3. The method for adding an audio watermark according to claim 1, wherein said adding the standard signal to the original audio signal based on the values corresponding to the respective bits in the original audio signal and the standard signal, generating an embedded signal to which the audio watermark is added, comprises: through a preset embedding formula:calculating the value corresponding to each bit in the embedded signal, wherein the operator +.>Representing a downscaling operation, stepsize representing a preset quantization step, D (i) representing a value corresponding to the ith bit in the embedded signal, F (i) representing a value corresponding to the ith bit in the original audio signal, sig ′ [i]And representing the value corresponding to the ith bit in the standard signal.
4. A method of extracting an audio watermark, comprising:
acquiring an original audio signal and an embedded signal, wherein the embedded signal contains data of an audio watermark;
and calculating a formula through preset parameters:calculating discrimination parameters corresponding to each bit in the embedded signal, wherein r (i) is the discrimination parameter corresponding to the ith bit in the embedded signal, F (i) is a value corresponding to the ith bit in the original audio signal, D (i) is a value corresponding to the ith bit in the embedded signal, step is a preset quantization step length, and an operator/>Representing a downward rounding operation; and extracting a formula through a preset watermark:calculating the corresponding numerical value of each discrimination parameter, and arranging the numerical values corresponding to the discrimination parameters to obtain a standard signal, wherein J (i) is the numerical value corresponding to the ith bit of the audio watermark;
and shaping the standard signal according to the original audio signal, generating an encrypted signal, and decrypting the encrypted signal to obtain the data of the audio watermark.
5. A terminal device comprising a memory and a processor, said memory storing a computer program executable on said processor, characterized in that said processor, when executing said computer program, performs the steps of:
acquiring data of an original audio signal and an audio watermark, and encrypting the data of the audio watermark to generate an encrypted signal;
zero padding is performed at the tail of the encrypted signal until the bit number of the encrypted signal after bit padding is equal to the bit number of the original audio signal; through a preset shaping formula:shaping the encrypted signal to generate a standard signal; the Sig ′ [t]For the value corresponding to the t-th bit of the standard signal, the +.>Is a preset calculation factor; the OriSig [ t ]]For the value corresponding to the t-th bit of the original audio signal, the Sig [ t ]]The value corresponding to the t bit of the encrypted signal after the bit compensation is given;
and adding the standard signal into the original audio signal according to the original audio signal and the numerical value corresponding to each bit in the standard signal, and generating an embedded signal added with the audio watermark.
6. A terminal device comprising a memory and a processor, said memory storing a computer program executable on said processor, characterized in that said processor, when executing said computer program, performs the steps of:
acquiring an original audio signal and an embedded signal, wherein the embedded signal contains data of an audio watermark;
and calculating a formula through preset parameters:calculating discrimination parameters corresponding to each bit in the embedded signal, wherein r (i) is the discrimination parameter corresponding to the ith bit in the embedded signal, F (i) is a value corresponding to the ith bit in the original audio signal, D (i) is a value corresponding to the ith bit in the embedded signal, and step is a preset quantization step length and an operator->Representing a downward rounding operation; and extracting a formula through a preset watermark:calculating the corresponding numerical value of each discrimination parameter, and arranging the numerical values corresponding to the discrimination parameters to obtain a standard signal, wherein J (i) is the numerical value corresponding to the ith bit of the audio watermark;
and shaping the standard signal according to the original audio signal to generate an encrypted signal, and decrypting the encrypted signal to generate data of the audio watermark.
7. A computer readable storage medium storing a computer program, characterized in that the computer program when executed by a processor implements the steps of the method according to any one of claims 1 to 3.
8. A computer readable storage medium storing a computer program, which when executed by a processor performs the steps of the method according to claim 4.
Priority Applications (2)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201811187250.5A CN109493875B (en) | 2018-10-12 | 2018-10-12 | Audio watermark adding and extracting method and terminal equipment |
PCT/CN2018/124303 WO2020073508A1 (en) | 2018-10-12 | 2018-12-27 | Method and device for adding and extracting audio watermark, electronic device and medium |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201811187250.5A CN109493875B (en) | 2018-10-12 | 2018-10-12 | Audio watermark adding and extracting method and terminal equipment |
Publications (2)
Publication Number | Publication Date |
---|---|
CN109493875A CN109493875A (en) | 2019-03-19 |
CN109493875B true CN109493875B (en) | 2023-07-07 |
Family
ID=65689538
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201811187250.5A Active CN109493875B (en) | 2018-10-12 | 2018-10-12 | Audio watermark adding and extracting method and terminal equipment |
Country Status (2)
Country | Link |
---|---|
CN (1) | CN109493875B (en) |
WO (1) | WO2020073508A1 (en) |
Families Citing this family (8)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN110197054B (en) * | 2019-04-26 | 2022-08-02 | 平安科技(深圳)有限公司 | MusicXML format file watermark embedding and extracting method, device and storage medium |
CN110266889B (en) * | 2019-06-26 | 2021-03-19 | 四川神琥科技有限公司 | Method for recording and preventing recorded audio from being edited and tampered |
CN110619883B (en) * | 2019-08-23 | 2023-05-23 | 平安科技(深圳)有限公司 | Information embedding method, information extracting method, information embedding device, information extracting device, terminal and storage medium |
CN111341329B (en) * | 2020-02-04 | 2022-01-21 | 北京达佳互联信息技术有限公司 | Watermark information adding method, watermark information extracting device, watermark information adding equipment and watermark information extracting medium |
CN111883108A (en) * | 2020-07-06 | 2020-11-03 | 珠海格力电器股份有限公司 | Password embedding method and device, password matching method and device and control system |
CN113012702A (en) * | 2021-02-22 | 2021-06-22 | 鹏城实验室 | Voice blind watermark injection method, device, equipment and storage medium |
CN116825116B (en) * | 2023-07-18 | 2024-03-12 | 合肥工业大学 | Robust audio watermark embedding and extracting method for resisting desynchronization attack |
CN118053435B (en) * | 2024-03-23 | 2024-09-10 | 北京富通亚讯网络信息技术有限公司 | Audio tamper-proof method, device, equipment and medium based on digital watermark technology |
Family Cites Families (8)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN100596061C (en) * | 2006-01-12 | 2010-03-24 | 大连理工大学 | Method for watermarking small wave threshold digital audio multiple mesh based on blind source separation |
US9401153B2 (en) * | 2012-10-15 | 2016-07-26 | Digimarc Corporation | Multi-mode audio recognition and auxiliary data encoding and decoding |
CN103425920A (en) * | 2013-08-26 | 2013-12-04 | 江苏物联网研究发展中心 | Audio information-based database security access control method of digital watermark |
CN104795071A (en) * | 2015-04-18 | 2015-07-22 | 广东石油化工学院 | Blind audio watermark embedding and watermark extraction processing method |
CN104810022B (en) * | 2015-05-11 | 2018-06-15 | 东北师范大学 | A kind of time domain digital audio water mark method based on audio breakpoint |
CN105608661B (en) * | 2015-12-28 | 2019-04-05 | 辽宁师范大学 | Based on the robust QR shearing wave zone audio frequency watermark insertion decomposed and detection method |
CN106504757A (en) * | 2016-11-09 | 2017-03-15 | 天津大学 | A kind of adaptive audio blind watermark method based on auditory model |
US10121477B2 (en) * | 2016-11-23 | 2018-11-06 | Ati Technologies Ulc | Video assisted digital audio watermarking |
-
2018
- 2018-10-12 CN CN201811187250.5A patent/CN109493875B/en active Active
- 2018-12-27 WO PCT/CN2018/124303 patent/WO2020073508A1/en active Application Filing
Also Published As
Publication number | Publication date |
---|---|
WO2020073508A1 (en) | 2020-04-16 |
CN109493875A (en) | 2019-03-19 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN109493875B (en) | Audio watermark adding and extracting method and terminal equipment | |
US10778441B2 (en) | Redactable document signatures | |
CN107819569B (en) | The encryption method and terminal device of log-on message | |
CN109800585B (en) | Image interpolation space completely reversible separable ciphertext domain information hiding algorithm | |
CN109547201B (en) | Encryption method of root key, computer readable storage medium and terminal equipment | |
CN103778590A (en) | Method and device for utilizing digital image to store and transmit information | |
CN108829899B (en) | Data table storage, modification, query and statistical method | |
WO2020228366A1 (en) | Picture processing method and apparatus based on block chain | |
EP2892175B1 (en) | Secure software components anti-reverse-engineering by table interleaving | |
JP7389446B2 (en) | Encryption/decryption device, encryption/decryption method, and computer program for executing the method | |
CN110225222B (en) | Image encryption method based on 3D orthogonal Latin square and chaotic system | |
US8280061B2 (en) | Methods and systems for storing and retrieving encrypted data | |
CN117294429B (en) | Public resource transaction data encryption and decryption method, system and medium based on blockchain | |
CN117714613A (en) | Image encryption method and device, electronic equipment and storage medium | |
CN114398375A (en) | Watermark embedding method, device, equipment and storage medium | |
CN114444108A (en) | Homomorphic encryption processing method and related equipment | |
CN113127911A (en) | Electric power data encryption method and device and terminal | |
CN117150532B (en) | Data security guarantee method, device, equipment and readable storage medium | |
US11971998B2 (en) | Data comparison device, data comparison system, and data comparison method | |
CN116992495B (en) | Office file encryption storage method, system, storage medium and electronic equipment | |
CN115277976B (en) | Image encryption method, device, electronic equipment and storage medium | |
CN117544292B (en) | Encryption system based on CBCT image equipment | |
CN110008657B (en) | Method, storage medium, electronic device and system for protecting webpage code | |
CN118364485A (en) | Method for embedding and extracting watermark of data table and related product | |
CN117278685A (en) | Large-capacity ciphertext domain reversible information hiding method and related equipment |
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 |