Questions tagged [keychainitemwrapper]

an Objective-C wrapper for accessing a single keychain item, the sample code was originally created by Apple but now available in modified & modernized (for ARC) forms from a variety of sources.

96 questions
4
votes
2 answers

iOS Keychain Sharing Data Between Devices

I have a bunch of apps using the same keychain group for sharing some sensitive data. It works fine when testing the apps in same device, they can access and edit the shared data. I wonder if it is possible to share data between iDevices, my iPad…
salamander
  • 87
  • 4
4
votes
1 answer

Can the keychain be used like a NSUserDefaults on steroids for storing NSData?

Can Keychain be used like a NSUserDefaults on steroids? I mean, for example, to store NSData used in a game? My intent is to store a NSData element that will be essentially the representation of an array or dictionaries. So the questions…
Duck
  • 34,902
  • 47
  • 248
  • 470
3
votes
2 answers

Couldn't add the Keychain Item. Error - 25299 after change the identifier with KeychainItemWrapper?

I wanna save UUID in keychain with KeychainItemWrapper, so I add the following methods in MyKeychainManager.m : #define keychain_idenentify @"com.myapp.bundle1" + (void)saveUUID:(NSString *)UUID{ if([MyKeychainManager getUUID].length > 0) { …
magic_9527
  • 243
  • 3
  • 18
3
votes
1 answer

KeychainItemWrapper error when specifying an access group

For quite some time, I have been successfully reading and writing private keychain items using the ARC version of KeychainItemWrapper. I'm now working to convert my iOS app to use a shared access group so that the keychain items can be accessed by…
Benchtop Creative
  • 583
  • 1
  • 5
  • 13
3
votes
1 answer

Keychain Item wrapper gives BAD_ACCESS_CODE=2

I want to keep my app status in keychain. So I have to put like this KeychainItemWrapper *keychainItemLog = [[KeychainItemWrapper alloc] initWithIdentifier:@"LoggedORNOT" accessGroup:nil]; [keychainItemLog setObject:@"STATUS" forKey:(__bridge…
user2889249
  • 899
  • 2
  • 13
  • 22
3
votes
2 answers

how to delete KeyChainItemData and genericPasswordQuery items from iOS keychain

I have been having some troubles with my keychain, I think mainly because I was not aware of how it worked when I first started using it, I tried several variations of adding data and strings passwords etc into my keychain thinking that when I…
HurkNburkS
  • 5,492
  • 19
  • 100
  • 183
3
votes
0 answers

change KSecAttrAccessible in KeychainItemWrapper after saving value

In my previous version of the application (iPhone) I kept value (Password) in the keychain in the following code: KeychainItemWrapper * keychain = [[KeychainItemWrapper alloc] initWithIdentifier:@"KeychainTest" …
Guy Kahlon
  • 4,510
  • 4
  • 30
  • 41
2
votes
0 answers

"SwiftKeychainWrapper.framework code signing failed" while distributing .ipa

When I want to distribute my .ipa file, I'm getting "code signing failed" error. After I updated my Xcode version to 10.0, this problem occured. Is there anyone that had this problem before ? The distribution standard log: code = 330; …
tugceaktepe
  • 195
  • 1
  • 2
  • 17
2
votes
1 answer

App crashes on saving data in keychain

I am using KeychainItemWrapper class for saving data in keychain, but my app is crashing with crash log Terminating app due to uncaught exception 'NSInternalInconsistencyException', reason: 'Couldn't add the Keychain Item.' Here is a method to write…
Mayank Jain
  • 5,663
  • 7
  • 32
  • 65
2
votes
0 answers

iOS - KeychainItemWrapper assertion failure when setting email

I am using the KeychainItemWrapper to store my logged in users email and password. With the following code: KeychainItemWrapper *keychainItem = [[KeychainItemWrapper alloc] initWithIdentifier:@"loginData" accessGroup:nil]; …
el-flor
  • 1,466
  • 3
  • 18
  • 39
2
votes
1 answer

KeychainItemWrapper not getting loaded on iOS 9 OSStatus -34018 (errSecMissingEntitlement)

I've been using KeychainItemWrapper just fine. But since I've updated my phone to iOS 9, it doesn't store the sessionID for some reason. + (BOOL)createKeychainValue:(NSString *)value forIdentifier:(NSString *)identifier { …
jonypz
  • 1,515
  • 1
  • 20
  • 35
2
votes
2 answers

how to save bool value in KeychainItemWrapper

I want to store bool value in KeychainItemWrapper, how to store ? I have tried this code, but it gives me error. [keychain setObject:YES forKey:(__bridge BOOL)kSecAttrIsInvisible];
bhumi
  • 57
  • 1
  • 8
2
votes
0 answers

Keychain is being reset itself in ios

I am using keychain class for storing some value in keychain . By using these keychain default methods KeychainItemWrapper *item = [[KeychainItemWrapper alloc] initWithIdentifier:@"identifier" accessGroup:nil]; [item setObject:@"some_value"…
Arun Kumar
  • 788
  • 5
  • 15
2
votes
0 answers

What is the scope of default keychain access group

I am exploring GenericKeyChain project for iOS. In that there is a class KeyChainItemWrapper with - (id)initWithIdentifier: (NSString *)identifier accessGroup:(NSString *) accessGroup; method. If I pass nil for accessGroup then it will consider…
sam18
  • 631
  • 1
  • 10
  • 24
2
votes
1 answer

GenericKeyChain KeychainItemWrapper.m does not compile when copied to another project

I compile and run Apple's GenericKeyChain sample code. No problems there. Now I want to use both files KeychainItemWrapper.m and KeychainItemWrapper.h in my new project and I get lots of compilation errors. I see that Apple's sample code is using…
TopRod
  • 21
  • 3