0

I have a unique use case here: I need to enhance a stand-alone iPhone app "EmergencyResponse" (name changed for this post) that is used by at-risk patients. Patients/Caregivers setup the app with information about their medications, physician contact info, family contact, info etc.

The app puts up a message on the iPhone lock screen with "Unlock phone and open 'EmergencyResponse' which will guide you on how to assist me"

So if the patient passes out somewhere and a good samaritan comes by, they see the message and proceed to open the app on the phone. Once the app is open - the good samaritan can then see a message "Hi my name is John Smith. If I am in trouble call my wife Jill Smith at 123-456-7890 (Cell)... etc" The good samaritan also gets to see the patients medical condition details, medications being taken etc (all things that would aid the emergency response folks)

The company that's sponsored the app wants to make sure I use encryption without compromising the usage (i.e. users cannot be asked for a password). I was thinking of storing an encryption key within the code. The data elements stored in core data fields could be encrypted with the key and unencrypted when the database needs to be accessed. There's just a limited amount of data and nothing to query so after un-encrypting the data I could keep everything in the Model objects.

Before I roll up my sleeves and begin, I was hoping to get some sound advise on whether this will work, whether it is the best option or if there is something else that will work better (I've heard of SALT lists - but never used those)! Look forward to your responses!

CoolDocMan
  • 637
  • 7
  • 29

1 Answers1

1

Two thoughts:

1) just store all the data in a dictionary in the KeyChain - I'm not sure what a reasonable limit is, but I imagine a few thousand bytes isn't going to be a problem.

2) You could create a encryption key at launch, random and salted etc, then store it in the keychain.

However, what I don't understand is why you want to encrypt at all. If this person looses the phone, the data can be read off the screen, no? So you just want to protect the data in the file system, but its OK for a random person to read it off the screen?

David H
  • 40,852
  • 12
  • 92
  • 138
  • Thanks! You're right, the use case is a bit convoluted! While the basic premise is that folks are trustworthy, the client still has angst about data privacy. Just want to make sure I have the encryption options in place so we can explore some practical solutions/alternatives ... ex. if the person was in a real emergency then the data should be open, but if the phone is lost or gets stolen the data should be inaccessible. – CoolDocMan May 16 '13 at 18:54
  • Well, guess my point is that if you design it so that the data is available to a good Samaritan, then anyone who steal the phone has it too. You could require users to wear a QR coded emblem, that has to be held up to the phone to unlock the info. At least it would not be readable from a stolen phone. I don't see how you can protect the data otherwise. – David H May 16 '13 at 19:04
  • I like the QR coded emblem idea. That works for this use case! – CoolDocMan May 16 '13 at 19:47