2

To my konwledge, the (voice call) audio data from micphone will be sent to PCM module for resampling, then to modem for coding before sending to air.I am here for asking in Android is it possible to intercept the audio data from PCM to modem? Because I want to encrypt them before sending out. Thank you ..

Eric
  • 31
  • 1
  • 3
  • You can record all Microphone audio but I don't think you can replace the stream with the encrypted one. Also - not all Android phones allow to capture incoming audio. It will be better if your create your own Native application and use VoiP or you will have to go and create your own Android compatible phone to do what you want; Using hardware encrypter/decrypter because it might cause really bad audio lag, and using a simple algorithm is pointless now a days.It would easier to make up your own language. – Piotr Kula Oct 23 '12 at 14:06
  • Thanks for your answer,and could you tell me the exactly reason why I can't do that? All of processing procedures to the audio data are finished by hardware? I think the audio data should go through some driver layer(but I don't know pretty much),can I do that by changing some drivers? Thanks again. – Eric Oct 24 '12 at 08:10
  • You can't because drivers are protected by the OS layer.You are at application level and can only do what the Google API allows you to do.If you can find "RedirectMIcrophoneToAuxAndThenToGSM" then good days. Otherwise you have to compile your own version of android and get your users to install it.. emm? How do you install android on a smartphone. Not easy. Like I said - I have seen VoiP application that use the Microphone to stream over VoiP. I have never seen an app on any platform that allows you to manipulate GSM Voice.(cause it is illegal too?) – Piotr Kula Oct 24 '12 at 08:27
  • Aha, Google, for security, will never provide a API like that to developers, that's a pity. So I actualy need to do some changes in Android Kernel(or on driver layer). Is it possible? I will do more research, and VoIP is worth a try if I can't manipulate GSM Voice directly. Thanks for your answer. – Eric Oct 24 '12 at 10:31
  • HI- I made an answer for you- You can up vote it if you like it and if it has answered your question please mark it as answered. PS Welcome to Electrical Engineering. See you around – Piotr Kula Oct 24 '12 at 13:04
  • 1
    I think I don't have enough reputation to vote it right now, and you are so nice. – Eric Oct 25 '12 at 08:49

1 Answers1

2

You can record all Microphone audio using the Google API with your own software. Also - note that not all Android phones allow to capture incoming audio because of hardware limitations.

It will be better if your create your own Native application and use VoiP for your outbound audio, which is easily achieved because there are many VoiP application out there.

You cannot bypass the Google API because the driver level is protected by the Operating System. You application only has access to the API that the OS exposes to you. So if there is no API similar to "RedirectMIcrophoneToAuxAndThenToGSM" - then sorry you cannot do it- even using Native Java code.

Alternatives

  • Get Android source code and make the changes you need. Compile it and programme the devices yourself. This is not an easy task for end users and would normally be done on company phones. This is great because users cannot turn of the encryption stream you are trying to force because you control the API!
  • Make your own android phone device or get a Chinese factory to make one for you with a custom GSM encrypted/decrypted module. Hardware encryption is allot faster

I think the sole reason why NO phones allow you to replace the outgoing GSM audio with a altered one is it most likely illegal. TO prevent voice masking in terror, bullying, extortion, black mail,etc ...

Since you have a legitamate reason to encrypt your voice that must mean there is high financial benefit involved- So inherently you must make your own device to do it.

Piotr Kula
  • 2,144
  • 4
  • 21
  • 44
  • 1
    This is part of my study project in my laboratory, and there is no financial benefit involved... – Eric Oct 25 '12 at 09:00