Consolidate keychain item/query code