30

I use an admin account for the development. But every time I compile to a device Xcode is asking for admin username & password. I googled the issue. But none of the solutions worked. I tried the workarounds from this post, but it didn't work

Authorize a non-admin developer in Xcode / Mac OS

I also tried disabling and enabling the DevSecurityTools but it didn't work. I am using Xcode 4.3.1 installed on Mac OSX Lion 10.7.3.

Is there any way to fix this?

6
  • The sudo command should have worked. Try doing it logged in as admin. Mar 16, 2012 at 13:43
  • @Javy I am already admin. I tried sudo. I will login from another admin account and try to run terminal commands for my user. Mar 16, 2012 at 13:47
  • 1
    Hey, I am having the exact problem. I have an administrator account and every time I try to run on device I get prompted for 'Administrator' username and password. Is it possible to save this information to keychain?
    – NSRover
    May 18, 2012 at 0:58
  • I'm having the same problem. It used to work as expected, but ever since I installed "Maya" from Autodesk, it now prompts me every time I want to build to device. I tried all of the solutions of the linked post but none worked.
    – Jarson
    May 29, 2012 at 18:59
  • Issue is still there even after I installed Xcode 4.3.2 and updated Lion to 10.7.4. If anyone finds a solution please post.. :( Jun 6, 2012 at 12:59

6 Answers 6

81

For solution go to Keychain Access, and in the top left navigation, move your Developer certificate from "System" to "Login".

Actually problem is Developer certificate is under "System", and it is locked every-time, so it will require a password to unlock, whereas when certificate is in "Login" section it will resolve that.

4
  • It works for me, OSX 10.8 GM and XCode 4.5 Preview 3. Just using the "keychain access" tool to move the code sign related certifications to "Login" section will do.
    – Jerry Tian
    Jul 20, 2012 at 3:14
  • excellent! Never would have found this, works with xcode 4.5 and 10.7 Oct 7, 2012 at 21:57
  • having the same problem on OS X Mavericks with Xcode 4.6.3.i have tried the solution but failed.will u plz clearly mention name of certificates as named in keychain access for drag drop.is that single certificate or more than one certificates need to drag drop??? The Alert is "Developer tools access needs to take control of another process for debugging to continue.Type your password to allow this."
    – sanjay
    Oct 28, 2013 at 2:59
  • i don't have a developer account,am debugging my apps on simulator. thx!!
    – sanjay
    Oct 28, 2013 at 3:10
6

In keychain remove your development and distribution certificates from System and place them under Login. It will ask once and you have to select Always allow

That worked for me. Hope it works for you aswel.

5

In Xcode 7.1, I didn't find Login so I have given access to Xcode and codesign for the certificate key by following steps:

  1. Open Key Chain
  2. Go to Certificate under System
  3. Click on closure, right click on private key and select 'Get Info'
  4. Click on 'Access Control' tab
  5. Add Xcode and coding under 'Always allow access by these applications:'

It solves my problem.

1
  • Works for latest XCode too
    – IPv6
    Nov 25, 2016 at 13:54
1

Is the /Developers directory from the old Xcode still on the drive? I just had a user with this issue that was also experiencing build fails with code that other users were able to build successfully. Some of the file associations cause the new Xcode (moved to the /Applications folder) to reference components in the old /Developers folder. Once we removed the folder and emptied the trash, everything worked as expected.

0

After moving Developers certificate form "System" to "Login". If it still asks for Username and password, you need to check your code signing. Go to the Build Setting and under code signing select the respected developer's certificate. It works for me.

0

On macOS Catalina, you have to:

  1. Open Keychain Access.
  2. Find your developer cert under the System category on the left.
  3. Right or Double click the cert to open the Get Info window.
  4. Expend the Trust dropdown above the cert details.
  5. Open the drop down menu options for Code Signing.
  6. Set the value to Always Trust.

It may be a good idea to quit and restart xCode after this if it was open, but when I changed mine I didn't bother and it still worked as expected.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.