Error the specified item could not be found in the keychain

Replies

And the certs and keys are separate, don’t know why not shown in pairs

On the Mac that’s having problems, what does the following print?

% security find-identity -p codesigning -v

Share and Enjoy

Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@" + "apple.com"

OK, that’s not good )-:

In your screen shot I noticed that you have Certificates selected at the top. This, combined with the results from find-identity, suggest that you have copied across these signing certificates but not their matching private keys. Thus you have signing certificates but not signing identities.

If you don’t understand the difference — and, trust me, you’re not the only one, our industry is plagued by this problem — read Certificate Signing Requests Explained for the backstory.

Share and Enjoy

Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@" + "apple.com"

I’ve tried to copy cert and key by exporting from my personal MacBook

This should work. The trick is to export the digital identity as a .p12 file. See this post for specific instructions.

Share and Enjoy

Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@" + "apple.com"

the cert and key still not in My Certificate tab, but Certificates tab
and Keys tab separately.

Hmmm, it’s true that Keychain Access has its fair share of bugs. I know this sounds stupid, but did you try quitting and relaunching it?

Share and Enjoy

Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@" + "apple.com"

Do you know if we can re-install the keychain access?

No. Keychain Access is built in to the OS and, assuming you didn’t go out of your way to disable SIP, can’t be modified.

Just for testing purposes, create a new user account on your Mac (using System Preferences > Users & Groups), log is as that user, and then import the .p12 there. What happens?

Share and Enjoy

Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@" + "apple.com"

Good idea to have a try! Unfortunately, after a try…
The below is my new account on the same macbook and after double-clicked the .p12 file….

Are you sure that this is actually a PKCS#12 file? What does this print:

% file /path/to/my.p12

Share and Enjoy

Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@" + "apple.com"

it prints: /path/to/my.p12: data

OK, that’s what I was expecting.

So, it works in my personal macbook pro (the source), App Center for
building app, my old macbook Air, but my company’s macbook pro….

Are you missing a “not” in that last clause?

Share and Enjoy

Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@" + "apple.com"

not working in my company’s [Mac]

I recommend that you escalate this via your company’s IS department.

Importing a digital identity into a keychain should work, and we know it works on your personal machine. Moreover, the fact that it fails when you use a fresh user account means that there’s no lingering configuration issue on your main user account. All that remains is a configuration issue with the Mac itself, and that’s not something I can help you with [1].

Share and Enjoy

Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@" + "apple.com"

[1] My experience is that companies often install ‘security’ software that causes all sorts of weird and wonderful problems. The obvious next step here is to disable that software, but I’m not going to advise you to do that without talking to your IS department first.

Bug Report

Hi all
I started a new project based on Ionic5 for a mobile app, then added capacitor and opened Xcode to build it: everything goes well using simulator as target device, but an error occurs when I try to build it for a real iPhone attached on USB.

Capacitor Version

npx cap doctor output:
💊 Capacitor Doctor 💊

Latest Dependencies:

@capacitor/cli: 1.5.1

@capacitor/core: 1.5.1

@capacitor/android: 1.5.1

@capacitor/ios: 1.5.1

Installed Dependencies:

@capacitor/cli 1.5.1

@capacitor/core 1.5.1

@capacitor/android 1.5.1

@capacitor/ios 1.5.1

[success] Android looking great! 👌
Found 0 Capacitor plugins for ios:
[success] iOS looking great! 👌

Affected Platform(s)

  • Android
  • iOS
  • Electron
  • Web

Current Behavior

Running build in Xcode for real device I get the error Build failed with the message The specified item could not be found in the keychain. I googled a lot about this error founding only issues related to certificate and keychain problems. Unfortunately none of those are my case because the certificate I’m using for signing the build is the same used without any issues in another Xcode project targeting the previous version of the same mobile app (Ionic 3 + Cordova based).
Having a look at the output messages in Xcode (see all log at the end of this post) one can see the commands generating the error:

...
Codesigning /Users/Sergio/Library/Developer/Xcode/DerivedData/App-avabgaxilgqumifzfxtnugizxbks/Build/Products/Debug-iphoneos/App.app/Frameworks/libswiftos.dylib
/usr/bin/codesign --force --sign <my-signing-code-here> --verbose /Users/Sergio/Library/Developer/Xcode/DerivedData/App-avabgaxilgqumifzfxtnugizxbks/Build/Products/Debug-iphoneos/App.app/Frameworks/libswiftos.dylib
error: The specified item could not be found in the keychain.
...

More strange than ever, if I copy&paste the codesign command in a terminal, it executes without any problems:

/Users/Sergio/Library/Developer/Xcode/DerivedData/App-avabgaxilgqumifzfxtnugizxbks/Build/Products/Debug-iphoneos/App.app/Frameworks/libswiftos.dylib: replacing existing signature
/Users/Sergio/Library/Developer/Xcode/DerivedData/App-avabgaxilgqumifzfxtnugizxbks/Build/Products/Debug-iphoneos/App.app/Frameworks/libswiftos.dylib: signed Mach-O universal (armv7 armv7s arm64 arm64e) [com.apple.dt.runtime.swiftos]

Expected Behavior

I would expect the build process to complete without any errors

Sample Code or Sample Application Repo

Reproduction Steps

Other Technical Details

npm --version output:
6.13.7

node --version output:
v12.14.1

pod --version output (iOS issues only):
1.9.1

Other Information

Complete build output message list:


Showing Recent Messages
CopySwiftLibs /Users/Sergio/Library/Developer/Xcode/DerivedData/App-avabgaxilgqumifzfxtnugizxbks/Build/Products/Debug-iphoneos/App.app (in target 'App' from project 'App')
    cd /Volumes/Lavoro/Projects/sot-mobile/ios/App
    export CODESIGN_ALLOCATE=/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/codesign_allocate
    export DEVELOPER_DIR=/Applications/Xcode.app/Contents/Developer
    export SDKROOT=/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS13.2.sdk
    builtin-swiftStdLibTool --copy --verbose --sign <my-signing-code-here> --scan-executable /Users/Sergio/Library/Developer/Xcode/DerivedData/App-avabgaxilgqumifzfxtnugizxbks/Build/Products/Debug-iphoneos/App.app/App --scan-folder /Users/Sergio/Library/Developer/Xcode/DerivedData/App-avabgaxilgqumifzfxtnugizxbks/Build/Products/Debug-iphoneos/App.app/Frameworks --scan-folder /Users/Sergio/Library/Developer/Xcode/DerivedData/App-avabgaxilgqumifzfxtnugizxbks/Build/Products/Debug-iphoneos/App.app/PlugIns --scan-folder /Users/Sergio/Library/Developer/Xcode/DerivedData/App-avabgaxilgqumifzfxtnugizxbks/Build/Products/Debug-iphoneos/Pods_App.framework --platform iphoneos --toolchain /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain --destination /Users/Sergio/Library/Developer/Xcode/DerivedData/App-avabgaxilgqumifzfxtnugizxbks/Build/Products/Debug-iphoneos/App.app/Frameworks --strip-bitcode --strip-bitcode-tool /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/bitcode_strip --emit-dependency-info /Users/Sergio/Library/Developer/Xcode/DerivedData/App-avabgaxilgqumifzfxtnugizxbks/Build/Intermediates.noindex/App.build/Debug-iphoneos/App.build/SwiftStdLibToolInputDependencies.dep

Copying /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift-5.0/iphoneos/libswiftUIKit.dylib to /Users/Sergio/Library/Developer/Xcode/DerivedData/App-avabgaxilgqumifzfxtnugizxbks/Build/Products/Debug-iphoneos/App.app/Frameworks/libswiftUIKit.dylib
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/bitcode_strip /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift-5.0/iphoneos/libswiftUIKit.dylib -r -o /Users/Sergio/Library/Developer/Xcode/DerivedData/App-avabgaxilgqumifzfxtnugizxbks/Build/Products/Debug-iphoneos/App.app/Frameworks/libswiftUIKit.dylib
Copying /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift-5.0/iphoneos/libswiftCoreFoundation.dylib to /Users/Sergio/Library/Developer/Xcode/DerivedData/App-avabgaxilgqumifzfxtnugizxbks/Build/Products/Debug-iphoneos/App.app/Frameworks/libswiftCoreFoundation.dylib
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/bitcode_strip /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift-5.0/iphoneos/libswiftCoreFoundation.dylib -r -o /Users/Sergio/Library/Developer/Xcode/DerivedData/App-avabgaxilgqumifzfxtnugizxbks/Build/Products/Debug-iphoneos/App.app/Frameworks/libswiftCoreFoundation.dylib
Copying /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift-5.0/iphoneos/libswiftObjectiveC.dylib to /Users/Sergio/Library/Developer/Xcode/DerivedData/App-avabgaxilgqumifzfxtnugizxbks/Build/Products/Debug-iphoneos/App.app/Frameworks/libswiftObjectiveC.dylib
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/bitcode_strip /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift-5.0/iphoneos/libswiftObjectiveC.dylib -r -o /Users/Sergio/Library/Developer/Xcode/DerivedData/App-avabgaxilgqumifzfxtnugizxbks/Build/Products/Debug-iphoneos/App.app/Frameworks/libswiftObjectiveC.dylib
Copying /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift-5.0/iphoneos/libswiftMetal.dylib to /Users/Sergio/Library/Developer/Xcode/DerivedData/App-avabgaxilgqumifzfxtnugizxbks/Build/Products/Debug-iphoneos/App.app/Frameworks/libswiftMetal.dylib
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/bitcode_strip /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift-5.0/iphoneos/libswiftMetal.dylib -r -o /Users/Sergio/Library/Developer/Xcode/DerivedData/App-avabgaxilgqumifzfxtnugizxbks/Build/Products/Debug-iphoneos/App.app/Frameworks/libswiftMetal.dylib
Copying /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift-5.0/iphoneos/libswiftDarwin.dylib to /Users/Sergio/Library/Developer/Xcode/DerivedData/App-avabgaxilgqumifzfxtnugizxbks/Build/Products/Debug-iphoneos/App.app/Frameworks/libswiftDarwin.dylib
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/bitcode_strip /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift-5.0/iphoneos/libswiftDarwin.dylib -r -o /Users/Sergio/Library/Developer/Xcode/DerivedData/App-avabgaxilgqumifzfxtnugizxbks/Build/Products/Debug-iphoneos/App.app/Frameworks/libswiftDarwin.dylib
Copying /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift-5.0/iphoneos/libswiftFoundation.dylib to /Users/Sergio/Library/Developer/Xcode/DerivedData/App-avabgaxilgqumifzfxtnugizxbks/Build/Products/Debug-iphoneos/App.app/Frameworks/libswiftFoundation.dylib
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/bitcode_strip /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift-5.0/iphoneos/libswiftFoundation.dylib -r -o /Users/Sergio/Library/Developer/Xcode/DerivedData/App-avabgaxilgqumifzfxtnugizxbks/Build/Products/Debug-iphoneos/App.app/Frameworks/libswiftFoundation.dylib
Copying /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift-5.0/iphoneos/libswiftDispatch.dylib to /Users/Sergio/Library/Developer/Xcode/DerivedData/App-avabgaxilgqumifzfxtnugizxbks/Build/Products/Debug-iphoneos/App.app/Frameworks/libswiftDispatch.dylib
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/bitcode_strip /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift-5.0/iphoneos/libswiftDispatch.dylib -r -o /Users/Sergio/Library/Developer/Xcode/DerivedData/App-avabgaxilgqumifzfxtnugizxbks/Build/Products/Debug-iphoneos/App.app/Frameworks/libswiftDispatch.dylib
Copying /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift-5.0/iphoneos/libswiftQuartzCore.dylib to /Users/Sergio/Library/Developer/Xcode/DerivedData/App-avabgaxilgqumifzfxtnugizxbks/Build/Products/Debug-iphoneos/App.app/Frameworks/libswiftQuartzCore.dylib
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/bitcode_strip /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift-5.0/iphoneos/libswiftQuartzCore.dylib -r -o /Users/Sergio/Library/Developer/Xcode/DerivedData/App-avabgaxilgqumifzfxtnugizxbks/Build/Products/Debug-iphoneos/App.app/Frameworks/libswiftQuartzCore.dylib
Copying /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift-5.0/iphoneos/libswiftCoreGraphics.dylib to /Users/Sergio/Library/Developer/Xcode/DerivedData/App-avabgaxilgqumifzfxtnugizxbks/Build/Products/Debug-iphoneos/App.app/Frameworks/libswiftCoreGraphics.dylib
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/bitcode_strip /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift-5.0/iphoneos/libswiftCoreGraphics.dylib -r -o /Users/Sergio/Library/Developer/Xcode/DerivedData/App-avabgaxilgqumifzfxtnugizxbks/Build/Products/Debug-iphoneos/App.app/Frameworks/libswiftCoreGraphics.dylib
Copying /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift-5.0/iphoneos/libswiftos.dylib to /Users/Sergio/Library/Developer/Xcode/DerivedData/App-avabgaxilgqumifzfxtnugizxbks/Build/Products/Debug-iphoneos/App.app/Frameworks/libswiftos.dylib
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/bitcode_strip /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift-5.0/iphoneos/libswiftos.dylib -r -o /Users/Sergio/Library/Developer/Xcode/DerivedData/App-avabgaxilgqumifzfxtnugizxbks/Build/Products/Debug-iphoneos/App.app/Frameworks/libswiftos.dylib
Copying /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift-5.0/iphoneos/libswiftCoreImage.dylib to /Users/Sergio/Library/Developer/Xcode/DerivedData/App-avabgaxilgqumifzfxtnugizxbks/Build/Products/Debug-iphoneos/App.app/Frameworks/libswiftCoreImage.dylib
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/bitcode_strip /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift-5.0/iphoneos/libswiftCoreImage.dylib -r -o /Users/Sergio/Library/Developer/Xcode/DerivedData/App-avabgaxilgqumifzfxtnugizxbks/Build/Products/Debug-iphoneos/App.app/Frameworks/libswiftCoreImage.dylib
Copying /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift-5.0/iphoneos/libswiftCore.dylib to /Users/Sergio/Library/Developer/Xcode/DerivedData/App-avabgaxilgqumifzfxtnugizxbks/Build/Products/Debug-iphoneos/App.app/Frameworks/libswiftCore.dylib
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/bitcode_strip /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift-5.0/iphoneos/libswiftCore.dylib -r -o /Users/Sergio/Library/Developer/Xcode/DerivedData/App-avabgaxilgqumifzfxtnugizxbks/Build/Products/Debug-iphoneos/App.app/Frameworks/libswiftCore.dylib
Probing signature of /Users/Sergio/Library/Developer/Xcode/DerivedData/App-avabgaxilgqumifzfxtnugizxbks/Build/Products/Debug-iphoneos/App.app/Frameworks/libswiftUIKit.dylib
/usr/bin/codesign -r- --display /Users/Sergio/Library/Developer/Xcode/DerivedData/App-avabgaxilgqumifzfxtnugizxbks/Build/Products/Debug-iphoneos/App.app/Frameworks/libswiftUIKit.dylib
/Users/Sergio/Library/Developer/Xcode/DerivedData/App-avabgaxilgqumifzfxtnugizxbks/Build/Products/Debug-iphoneos/App.app/Frameworks/libswiftUIKit.dylib: code object is not signed at all

Codesigning /Users/Sergio/Library/Developer/Xcode/DerivedData/App-avabgaxilgqumifzfxtnugizxbks/Build/Products/Debug-iphoneos/App.app/Frameworks/libswiftUIKit.dylib
/usr/bin/codesign --force --sign <my-signing-code-here> --verbose /Users/Sergio/Library/Developer/Xcode/DerivedData/App-avabgaxilgqumifzfxtnugizxbks/Build/Products/Debug-iphoneos/App.app/Frameworks/libswiftUIKit.dylib
Probing signature of /Users/Sergio/Library/Developer/Xcode/DerivedData/App-avabgaxilgqumifzfxtnugizxbks/Build/Products/Debug-iphoneos/App.app/Frameworks/libswiftCoreFoundation.dylib
Probing signature of /Users/Sergio/Library/Developer/Xcode/DerivedData/App-avabgaxilgqumifzfxtnugizxbks/Build/Products/Debug-iphoneos/App.app/Frameworks/libswiftObjectiveC.dylib
Probing signature of /Users/Sergio/Library/Developer/Xcode/DerivedData/App-avabgaxilgqumifzfxtnugizxbks/Build/Products/Debug-iphoneos/App.app/Frameworks/libswiftMetal.dylib
Probing signature of /Users/Sergio/Library/Developer/Xcode/DerivedData/App-avabgaxilgqumifzfxtnugizxbks/Build/Products/Debug-iphoneos/App.app/Frameworks/libswiftDarwin.dylib
Probing signature of /Users/Sergio/Library/Developer/Xcode/DerivedData/App-avabgaxilgqumifzfxtnugizxbks/Build/Products/Debug-iphoneos/App.app/Frameworks/libswiftFoundation.dylib
Probing signature of /Users/Sergio/Library/Developer/Xcode/DerivedData/App-avabgaxilgqumifzfxtnugizxbks/Build/Products/Debug-iphoneos/App.app/Frameworks/libswiftDispatch.dylib
Probing signature of /Users/Sergio/Library/Developer/Xcode/DerivedData/App-avabgaxilgqumifzfxtnugizxbks/Build/Products/Debug-iphoneos/App.app/Frameworks/libswiftQuartzCore.dylib
Probing signature of /Users/Sergio/Library/Developer/Xcode/DerivedData/App-avabgaxilgqumifzfxtnugizxbks/Build/Products/Debug-iphoneos/App.app/Frameworks/libswiftCoreGraphics.dylib
/usr/bin/codesign -r- --display /Users/Sergio/Library/Developer/Xcode/DerivedData/App-avabgaxilgqumifzfxtnugizxbks/Build/Products/Debug-iphoneos/App.app/Frameworks/libswiftCoreFoundation.dylib
/usr/bin/codesign -r- --display /Users/Sergio/Library/Developer/Xcode/DerivedData/App-avabgaxilgqumifzfxtnugizxbks/Build/Products/Debug-iphoneos/App.app/Frameworks/libswiftObjectiveC.dylib
/usr/bin/codesign -r- --display /Users/Sergio/Library/Developer/Xcode/DerivedData/App-avabgaxilgqumifzfxtnugizxbks/Build/Products/Debug-iphoneos/App.app/Frameworks/libswiftMetal.dylib
/usr/bin/codesign -r- --display /Users/Sergio/Library/Developer/Xcode/DerivedData/App-avabgaxilgqumifzfxtnugizxbks/Build/Products/Debug-iphoneos/App.app/Frameworks/libswiftDarwin.dylib
/usr/bin/codesign -r- --display /Users/Sergio/Library/Developer/Xcode/DerivedData/App-avabgaxilgqumifzfxtnugizxbks/Build/Products/Debug-iphoneos/App.app/Frameworks/libswiftFoundation.dylib
/usr/bin/codesign -r- --display /Users/Sergio/Library/Developer/Xcode/DerivedData/App-avabgaxilgqumifzfxtnugizxbks/Build/Products/Debug-iphoneos/App.app/Frameworks/libswiftDispatch.dylib
/usr/bin/codesign -r- --display /Users/Sergio/Library/Developer/Xcode/DerivedData/App-avabgaxilgqumifzfxtnugizxbks/Build/Products/Debug-iphoneos/App.app/Frameworks/libswiftQuartzCore.dylib
/usr/bin/codesign -r- --display /Users/Sergio/Library/Developer/Xcode/DerivedData/App-avabgaxilgqumifzfxtnugizxbks/Build/Products/Debug-iphoneos/App.app/Frameworks/libswiftCoreGraphics.dylib
/Users/Sergio/Library/Developer/Xcode/DerivedData/App-avabgaxilgqumifzfxtnugizxbks/Build/Products/Debug-iphoneos/App.app/Frameworks/libswiftFoundation.dylib: code object is not signed at all

/Users/Sergio/Library/Developer/Xcode/DerivedData/App-avabgaxilgqumifzfxtnugizxbks/Build/Products/Debug-iphoneos/App.app/Frameworks/libswiftCoreFoundation.dylib: code object is not signed at all

/Users/Sergio/Library/Developer/Xcode/DerivedData/App-avabgaxilgqumifzfxtnugizxbks/Build/Products/Debug-iphoneos/App.app/Frameworks/libswiftDispatch.dylib: code object is not signed at all

/Users/Sergio/Library/Developer/Xcode/DerivedData/App-avabgaxilgqumifzfxtnugizxbks/Build/Products/Debug-iphoneos/App.app/Frameworks/libswiftObjectiveC.dylib: code object is not signed at all

/Users/Sergio/Library/Developer/Xcode/DerivedData/App-avabgaxilgqumifzfxtnugizxbks/Build/Products/Debug-iphoneos/App.app/Frameworks/libswiftDarwin.dylib: code object is not signed at all

/Users/Sergio/Library/Developer/Xcode/DerivedData/App-avabgaxilgqumifzfxtnugizxbks/Build/Products/Debug-iphoneos/App.app/Frameworks/libswiftQuartzCore.dylib: code object is not signed at all

/Users/Sergio/Library/Developer/Xcode/DerivedData/App-avabgaxilgqumifzfxtnugizxbks/Build/Products/Debug-iphoneos/App.app/Frameworks/libswiftCoreGraphics.dylib: code object is not signed at all

/Users/Sergio/Library/Developer/Xcode/DerivedData/App-avabgaxilgqumifzfxtnugizxbks/Build/Products/Debug-iphoneos/App.app/Frameworks/libswiftMetal.dylib: code object is not signed at all

Codesigning /Users/Sergio/Library/Developer/Xcode/DerivedData/App-avabgaxilgqumifzfxtnugizxbks/Build/Products/Debug-iphoneos/App.app/Frameworks/libswiftFoundation.dylib
Codesigning /Users/Sergio/Library/Developer/Xcode/DerivedData/App-avabgaxilgqumifzfxtnugizxbks/Build/Products/Debug-iphoneos/App.app/Frameworks/libswiftCoreFoundation.dylib
Codesigning /Users/Sergio/Library/Developer/Xcode/DerivedData/App-avabgaxilgqumifzfxtnugizxbks/Build/Products/Debug-iphoneos/App.app/Frameworks/libswiftDispatch.dylib
Codesigning /Users/Sergio/Library/Developer/Xcode/DerivedData/App-avabgaxilgqumifzfxtnugizxbks/Build/Products/Debug-iphoneos/App.app/Frameworks/libswiftObjectiveC.dylib
Codesigning /Users/Sergio/Library/Developer/Xcode/DerivedData/App-avabgaxilgqumifzfxtnugizxbks/Build/Products/Debug-iphoneos/App.app/Frameworks/libswiftDarwin.dylib
Codesigning /Users/Sergio/Library/Developer/Xcode/DerivedData/App-avabgaxilgqumifzfxtnugizxbks/Build/Products/Debug-iphoneos/App.app/Frameworks/libswiftQuartzCore.dylib
Codesigning /Users/Sergio/Library/Developer/Xcode/DerivedData/App-avabgaxilgqumifzfxtnugizxbks/Build/Products/Debug-iphoneos/App.app/Frameworks/libswiftCoreGraphics.dylib
Codesigning /Users/Sergio/Library/Developer/Xcode/DerivedData/App-avabgaxilgqumifzfxtnugizxbks/Build/Products/Debug-iphoneos/App.app/Frameworks/libswiftMetal.dylib
/usr/bin/codesign --force --sign <my-signing-code-here> --verbose /Users/Sergio/Library/Developer/Xcode/DerivedData/App-avabgaxilgqumifzfxtnugizxbks/Build/Products/Debug-iphoneos/App.app/Frameworks/libswiftFoundation.dylib
/usr/bin/codesign --force --sign <my-signing-code-here> --verbose /Users/Sergio/Library/Developer/Xcode/DerivedData/App-avabgaxilgqumifzfxtnugizxbks/Build/Products/Debug-iphoneos/App.app/Frameworks/libswiftCoreFoundation.dylib
/usr/bin/codesign --force --sign <my-signing-code-here> --verbose /Users/Sergio/Library/Developer/Xcode/DerivedData/App-avabgaxilgqumifzfxtnugizxbks/Build/Products/Debug-iphoneos/App.app/Frameworks/libswiftDispatch.dylib
/usr/bin/codesign --force --sign <my-signing-code-here> --verbose /Users/Sergio/Library/Developer/Xcode/DerivedData/App-avabgaxilgqumifzfxtnugizxbks/Build/Products/Debug-iphoneos/App.app/Frameworks/libswiftObjectiveC.dylib
/usr/bin/codesign --force --sign <my-signing-code-here> --verbose /Users/Sergio/Library/Developer/Xcode/DerivedData/App-avabgaxilgqumifzfxtnugizxbks/Build/Products/Debug-iphoneos/App.app/Frameworks/libswiftDarwin.dylib
/usr/bin/codesign --force --sign <my-signing-code-here> --verbose /Users/Sergio/Library/Developer/Xcode/DerivedData/App-avabgaxilgqumifzfxtnugizxbks/Build/Products/Debug-iphoneos/App.app/Frameworks/libswiftQuartzCore.dylib
/usr/bin/codesign --force --sign <my-signing-code-here> --verbose /Users/Sergio/Library/Developer/Xcode/DerivedData/App-avabgaxilgqumifzfxtnugizxbks/Build/Products/Debug-iphoneos/App.app/Frameworks/libswiftCoreGraphics.dylib
/usr/bin/codesign --force --sign <my-signing-code-here> --verbose /Users/Sergio/Library/Developer/Xcode/DerivedData/App-avabgaxilgqumifzfxtnugizxbks/Build/Products/Debug-iphoneos/App.app/Frameworks/libswiftMetal.dylib
Probing signature of /Users/Sergio/Library/Developer/Xcode/DerivedData/App-avabgaxilgqumifzfxtnugizxbks/Build/Products/Debug-iphoneos/App.app/Frameworks/libswiftos.dylib
/usr/bin/codesign -r- --display /Users/Sergio/Library/Developer/Xcode/DerivedData/App-avabgaxilgqumifzfxtnugizxbks/Build/Products/Debug-iphoneos/App.app/Frameworks/libswiftos.dylib
error: The specified item could not be found in the keychain.

error: The specified item could not be found in the keychain.

error: The specified item could not be found in the keychain.

error: The specified item could not be found in the keychain.

/Users/Sergio/Library/Developer/Xcode/DerivedData/App-avabgaxilgqumifzfxtnugizxbks/Build/Products/Debug-iphoneos/App.app/Frameworks/libswiftos.dylib: code object is not signed at all

Codesigning /Users/Sergio/Library/Developer/Xcode/DerivedData/App-avabgaxilgqumifzfxtnugizxbks/Build/Products/Debug-iphoneos/App.app/Frameworks/libswiftos.dylib
/usr/bin/codesign --force --sign <my-signing-code-here> --verbose /Users/Sergio/Library/Developer/Xcode/DerivedData/App-avabgaxilgqumifzfxtnugizxbks/Build/Products/Debug-iphoneos/App.app/Frameworks/libswiftos.dylib
error: The specified item could not be found in the keychain.

error: The specified item could not be found in the keychain.

error: Failed with exit code 1 (in target 'App' from project 'App')
  • Remove From My Forums

 locked

Xamarin cannot build to device — «The specified item could not be found in the keychain»

  • Question

  • User161578 posted

    I am trying to build an iOS app in Debug|iPhone configuration on Xamarin Mac, but I am getting:

    /Library/Frameworks/Mono.framework/External/xbuild/Xamarin/iOS/Xamarin.iOS.Common.targets: Error: Tool exited with code: 1. Output: error: The specified item could not be found in the keychain.

    This all started when I had to reset my default keychain and lost my certificates. I’ve tried fixing it by:

    • Creating a new certificate manually (ensuring I had «Apple Worldwide Developer Relations Certification Authority» when requesting the certificate from the certificate authority as suggested here
    • Creating a certificate using xcode 8.3.1 (exporting this certificate onto another machine lets me build fine on that machine)
    • Importing my certificates from my old keychain (each time I created a new certificate I ensured to update and download the provisioning profile)
    • exporting a working certificate from another user on another machine and importing it onto my machine
    • uninstalling Xamarin studio, deleting the folders mentioned here, and installing Xamarin Studio 6.1.3 + Xamarin.iOS 10.4.0.123 (was using 6.1.3 + 10.2.1.5 previously)
    • uninstalling Xcode 8.1 and installing Xcode 8.3.1
    • installing visual studio for mac (this gave me a different error «EnsureBindingRedirects task failed unexpectedly» — likely a separate bug)

    The fact it failed to build when using a known working certificate/provisioning profile combo on another machine leads me to think that Xamarin is having a problem finding the certificate when doing the build, even though it sees the certificate and provisioning profile in Project Options -> iOS Bundle Signing. There could also be an issue in the Keychain somewhere.

    Any help on this would be greatly appreciated.

Answers

  • User161578 posted

    I fixed this by doing the following:

    1. security dump-keychain -d login.keychain to list all the items in my keychain

    2. Noticed there was an extra keychain item that was not showing up in Keychain Access

    3. Deleted this item using security delete-identity

    4. Did diskutil resetUserPermissions / $(id -u) and restarted my Mac

    I’m not sure if steps 1-3 are necessary, so if you are having this issue I would try step 4 first and see if that works.

    • Marked as answer by

      Thursday, June 3, 2021 12:00 AM

Понравилась статья? Поделить с друзьями:
  • Error the specified ip address is invalid
  • Error the software protection platform service is not installed windows 10
  • Error the setup files are corrupted please obtain a new copy of the program ок
  • Error the server name or address could not be resolved roblox
  • Error the server name or address could not be resolved 0x80072ee7