Questions tagged [keychain]

A keychain is an encrypted container that holds passwords for multiple applications and secure services. Apple Inc. uses keychains as password management system in Mac OS and iOS.

Keychain is Apple Inc.'s password management system in Mac OS and iOS. It was introduced with Mac OS 8.6, and has been included in all subsequent versions of Mac OS, including Mac OS X. A Keychain can contain various types of data: passwords (for Websites, FTP servers, SSH accounts, network shares, wireless networks, groupware applications, encrypted disk images), private keys, certificates, and secure notes.

In Mac OS X, keychain files are stored in ~/Library/Keychains/, /Library/Keychains/, and /Network/Library/Keychains/, and the Keychain Access GUI application is located in the Utilities folder in the Applications folder. It is free, open source software released under the terms of the APSL. The command line equivalent of Keychain Access is /usr/bin/security. The keychain file(s) stores a variety of data fields including a title, URL, notes and password. Other than Secure Notes created with Keychain Access, only the password is encrypted, with Triple DES. The contents of Secure Notes are also encrypted.

Source: Keychain

1969 questions
18
votes
2 answers

Xcode 7 with El Capitan unable to sign binary for export - can't press "allow" button

I'm running into an issue where a Mac OSX 10.11 El Capitan is unable to codesign a binary for adhoc distribution. The issue is bizarre: I've transferred a distribution cert on this mac XCode asks me if it can use a private key to sign the…
Alex Stone
  • 46,408
  • 55
  • 231
  • 407
18
votes
1 answer

How can I store keychain credentials for multiple Github accounts?

I am running Git on OSX Mavericks and have not had issues until now. What has changed is that I'm trying to use two Github accounts on different repos on the same computer. The problem is that the osx-keychain is storing the login information from…
Dylan
  • 1,026
  • 1
  • 10
  • 20
18
votes
5 answers

NSUserDefaults or keychain is better to save username and password in iPhone app

In my iphone app there is some confidential data like username, password and some urls to a webservice. Which one is better NSUserdefaults or keychain. Somebody says NSUserdefaults is insecure. Why it is insecure? and can any one give the pros and…
Johnykutty
  • 12,091
  • 13
  • 59
  • 100
17
votes
6 answers

Couldn't find github in keychain MacOS

August 13th, github no longer accepts password for git actions. So, to update the token, I would have to change the password field in the keychain (github keychain) to token as recommend. But, Unfortunately I couldn't find my keychain related to…
Sai Krishnadas
  • 2,863
  • 9
  • 36
  • 69
17
votes
7 answers

"iPhone Distribution" certificate is not trusted

I just installed a new iPhone Distribution certificate that was exported as a .p12 from someone else's computer. When I try to archive with a provisioning profile that's tied to this new certificate I get this Invalid trust settings error: Restore…
Adam Zarn
  • 1,868
  • 1
  • 16
  • 42
17
votes
1 answer

ASPasswordCredential - from where?

When using Sign in with Apple there's an ASPasswordCredential option which will pull the password from the iCloud keychain. I can't find details though on "where" in the keychain you store things. i.e. how do I know what keys to store the user or…
Gargoyle
  • 9,590
  • 16
  • 80
  • 145
17
votes
2 answers

Is it possible to use Touch-ID Authentication AND Keychain sharing in an iOS app?

I’ve been successfully able to implement TouchID with keychain as well as Keychain Sharing (syncing keychain items between multiple devices) separately. When I try to do them both, I get an error “-50“ which is invalid parameters. From the below…
SuPotter
  • 762
  • 1
  • 8
  • 16
17
votes
3 answers

Querying iOS Keychain using Swift

I'm stuck converting the Keychain query result using Swift. My request seems to be working: let queryAttributes = NSDictionary(objects: [kSecClassGenericPassword, "MyService", "MyAccount", true], forKeys:…
Damien
  • 660
  • 6
  • 15
16
votes
3 answers

Cocoa interface to MacOS X Keychain

I've got a bit of Mac code that needs to store, access and update passwords in order to connect users with a web API. The right place to put this information should be the Mac Keychain, but there doesn't seem to be a cocoa interface (see this…
Noah
  • 21,451
  • 8
  • 63
  • 71
16
votes
7 answers

SFHFKeychainUtils. iOS keychain. ARC compatible

I was wondering if anyone that was using the SFHFKeychainUtils managed to modify them to be compatible for ARC. More exactly the NSDictionary *attributeResult = NULL; NSMutableDictionary *attributeQuery = [query mutableCopy]; [attributeQuery…
Roland
  • 388
  • 1
  • 4
  • 21
16
votes
4 answers

Error when accessing keychain with Firebase iOS 10

I'm having issues with keychain on iOS 10 devices. Failed to retrieve saved users, only happens with iOS 10 users, authentication is with Firebase. This is the error: Error loading saved user when starting up: Error Domain=FIRAuthErrorDomain…
Tal Zion
  • 6,308
  • 3
  • 50
  • 73
16
votes
2 answers

Using Touch ID on iOS to encrypt data

What I'm trying to do Basically what I'm trying to do is figure out a way to encrypt data using Touch ID. Sadly I've not found a way to create an encryptionKey with Touch ID, since the LAContext API only returns a aye/nay response. Why I'm trying…
Gerald Eersteling
  • 1,244
  • 14
  • 28
16
votes
2 answers

Error (internetKeychainItemForServer:withUsername:path:port:protocol:) - The specified item could not be found in the keychain

I get the following error while I try to push my code to github using Sourcetree: Pushing to http://github.myOrg.com/my-repo/my-proj.git 2014-09-23 13:05:20.500 git-credential-sourcetree[6744:507] Error…
tech_human
  • 6,592
  • 16
  • 65
  • 107
16
votes
3 answers

How do I sign a Java applet using a certificate in my Mac keychain?

I have a self-signed root certificate with just the code signing extension (no other extensions) in my Mac keychain; I use it to sign all code coming out of ∞labs using Apple's codesign tool and it works great. I was looking to expand myself a…
millenomi
  • 6,569
  • 4
  • 31
  • 34
16
votes
2 answers

How do I programmatically import a certificate into my iOS app's keychain and pass the identity to a server when needed?

I am working on an iOS5 application that will facilitate mobile payments between two users. As part of the payment process, the sender and the recipient need to communicate with a server. The server requires that both parties present their…
derekmckinnon
  • 524
  • 1
  • 5
  • 15