iOS Question keychain problem

Discussion in 'iOS Questions' started by tufanv, Oct 10, 2016.

  1. tufanv

    tufanv Expert Licensed User

    Hello,

    After upgrading to b4i 3.0 or maybe to ios10 , dont sure exactly , I have an interesting problem.
    I have 2 apps that are already on the store ( which means i am sure their package names are different )

    I always remember username and password with using keychain all in my apps. If login is succcess than i add
    p.keychainput("username",txtusername.text) and same for the password. Today i realized that after i compile my apps with b4i 3.0 beta , i logged in to my one of my apps and entered my information and logged in. Later i opened my other app and saw that , the username and password i used in my other app is remembered in this app. i use same keys all in my apps and i did this without any problem but today, it is something like all my apps use the same keychain and when i put username and password keys into keychain my other app is also getting that value from the keystore. I know it seems interesting but this is the case . What may be wrong ?

    TY
     
  2. Erel

    Erel Administrator Staff Member Licensed User

    It is related to a change in Xcode 8.

    Add this line:
    Code:
    #Entitlement: <key>keychain-access-groups</key><array><string>558J7LMQ55.*</string></array>
    Change 558J7LMQ55 with your 10 characters prefix. You can find it in the provision profile file under ApplicationIdentifierPrefix or in the app ids section of the developer console: https://developer.apple.com/account/ios/identifier/bundle
     
    Last edited: Oct 10, 2016
  3. marcick

    marcick Well-Known Member Licensed User

    I'm sure I'm misunderstanding:
    If I don't use the entitlement all the user that have a specific app installed obtain the same value from keychain ?
    The app store in the keychain "DeviceID:123456789" and all other apps obtain 123456789 reading DeviceID from the keychain ? o_Oo_O
     
    Alexander Stolte likes this.
  4. Erel

    Erel Administrator Staff Member Licensed User

    No. The question here is how to make two apps installed on one specific device share the kaychain data.
     
    marcick likes this.
Loading...
  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice