Search code examples
iosios6keychainread-write

Use iOS Keychain to store key & secret of API call


I am storing the key & secret required for API call in iOS keychain using Apple code

My key & secret keeps on changing after every call to API. So once they are changed I save them in Keychain again. So I am accessging the iOS keychain frequently. My questions are

  1. Is it ok to store key & secret in iOS keychain ?
  2. Does Apple allow this as I am accessing the keychain everytime I need to call API ?

Solution

  • Sure. That's what it's there for.

    You access your keychain every time you want to get in your car, right?