1

I am storing secure data in the keychain that should be maintained only within my app. During app running this data is retrieved to some variable. It seems like it is possible to crack my app in order to read that value or even dump the whole keychain, but my question is it possible to the "hacker" modify that data i.e. modify at runtime area of RAM that holds this variable and make my app to update keychain with new value? And I also have setter method for that property, which saves it to keychain, is it possible to investigate the address of that function and force call my method with custom value?

I already looked here and here for best practices, read answer at Quora, that and that articles, looked for ios-keychain-analyzer project at GitHub but there is no mention about changing data, only about reading

Community
  • 1
  • 1
Azat
  • 6,745
  • 5
  • 31
  • 48
  • Yes, you can update your own keychain entries. Have you looked at Apples sample code or any of the keychain wrappers available - try cocoapods or GitHub or just google... – Paulw11 Apr 18 '15 at 22:57
  • @Paulw11 I don't mean update in usual case - I am aware of that as well. I am talking about cracking my app by someone else in order to call my function with illegal parameters to update keychain entry – Azat Apr 18 '15 at 23:03
  • No other app can read your chain entries. Period! – Black Frog Apr 18 '15 at 23:09
  • @BlackFrog it is not about other apps. For example I can export app to my laptop and investigate the binary with `otool` or connect to the running app with debugger. Question is about modifying keychain by attackers to store incorrect data – Azat Apr 18 '15 at 23:13
  • 2
    @BlackFrog - This is not necessarily true if the device is jailbroken. If jailbroken then device can execute code that isn't signed by Apple - this means it may be malicious code installed in the same sandbox as the OP's app. Apple goes to a lot of effort to secure the iOS platform - much of which is described here - http://www.apple.com/business/docs/iOS_Security_Guide.pdf It isn't clear from that document, but attacking the keychain on the actual device would probably require not only modifications to the app but also the securityd daemon that manages the keychain – Paulw11 Apr 18 '15 at 23:16

0 Answers0