Can information be stolen that gets transferred through the headphone jack by a backgrounded app?

StackOverflow https://stackoverflow.com/questions/21669841

  •  09-10-2022
  •  | 
  •  

Question

Can information that gets transferred through the headphone jack be stolen by a backgrounded app?

Square makes a card reader that plugs into the headphone jack of the iPhone and transfers your credit card info to your phone.

There are many devices that transfer data through the headphone jack.

Since you can run background processes now on iOS, can that information that is being transferred be intercepted or monitored by an app running in the background?

Could a random app potentially be listening and looking for credit card numbers and steal the information?

If yes, then is there a way to cancel all other app's listening connection to the headphone jack while I transfer my own data from a device?

I have looked at the AurioTouch example of how to transfer data but all I need to know right now is if my data is in jeopardy of being stolen and how I can prevent that.

Was it helpful?

Solution

See the last paragraph of "Playing and Recording Background Audio" here.

To sum it up, you can stop your app from playing or recording audio if another app wants to play/record audio. Look into AVAudioSession.

OTHER TIPS

You should be equally worried about the possibility of audio being intercepted on the outside of the device as audio. Such man-in-the-middle attacks have been reported against chip-and-pin terminals, and usually involve corrupt employees of the retailer using the device or social engineering.

The only solution is to encrypt the data. This makes the question of interception on the device irrelevant.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top