This repository was archived by the owner on Dec 15, 2018. It is now read-only.

Description
Calling
[[PDKeychainBindings sharedKeychainBindings] removeObjectForKey:@"myKey"];
returns
Could not store(Delete) string. Error was:-25300
While investigating it, I've found that this is a custom NSLog string, logged when the following operation fails:
OSStatus result=SecItemDelete((__bridge CFDictionaryRef)spec);
if (result!=0) {
NSLog(@"Could not store(Delete) string. Error was:%i",(int)result);
}
The error code from OSStatus enum declared in <Security/SecBase.h>has this description:
errSecItemNotFound = -25300, /* The specified item could not be found in the keychain. */
...which points out, that it's just the value being not found for respective key upon deleting.
Question
I wonder, what option here would be more preferable?
- I have to check for key existence, before attempting to delete it?
- The
PDKeychainBindingsController has to have a fix to check the key, before deleting
- The
PDKeychainBindingsController has to have a fix to make error codes processing and logging more accurate
- Ignore everything here (which was the way, it worked before this bug report was submitted)