MATLAB: How can I encrypt audio file or signal using xor

audio encryption

Processes involves, inputing audio on matlab, converting it to binary form (matrix) then encrypting using XOR (probably an otp)

Best Answer

Use the 'uint8' option of getaudiodata(): you can xor against that.
repmat() your key as many times as you need to be exactly as long as your binary signal, and then you can xor on that.