title: Correct way to remove(purge) all keychain data for an iOS app
body: <p>I stored some information in the keychain, and there is a case that I need to remove all of the items, instead of doing <code>[keychain removeObjectForKey:theKey]</code> for all the keys, can I do:</p>
  
  <pre><code>NSDictionary *spec = [NSDictionary dictionaryWithObjectsAndKeys:(id)kSecClassGenericPassword, kSecClass,
                        [self serviceName], kSecAttrService, nil];
  
  return !SecItemDelete((CFDictionaryRef)spec);
  </code></pre>
  
  <p>instead?</p>
  
  <p>I tried it and it worked, just not sure if I am doing the correct thing?</p>