Search results for

“codesign”

3,222 results found

Post

Replies

Boosts

Views

Activity

codesign reports good but package still flagged by Gatekeeper
I'm using my 3rd Party Developer and 3rd Party Installer certs to codesign an app bundle and then the package for that app for non-MAS distribution. Both operations report success and running codesign -vv /Applications/application.app reports:/Applications/application.app: valid on disk/Applications/application.app: satisfies its Designated RequirementHowever, when I transfer the PKG file to a server and then download it onto another system, Gatekeeper tells me that the app is from an unidentified developer. I have verified my certificates in Keychain Access and they match what is included with my developer account on developer.apple.com.Anyone have pointers as to what to check next?
6
0
808
Feb ’17
Distribution certificate and codesign cli
Hello there,I am trying to import my ios distribution certificate and key to a custom keychain so I can codesign my unsigned .app file with the following script:#!/bin/bash PASS='12345' KC=$HOME/Library/Keychains/custom.keychain LKC='login.keychain' CERT_FOLDER=$PWD/certificates PROFILE_NAME='MOBPROFILE.mobileprovision' PROFILE=$CERT_FOLDER/$PROFILE_NAME KEY=$CERT_FOLDER/private_key.pem CERT=$CERT_FOLDER/ios_distribution.cer APP=$PWD/myapp.app WWDR=$CERT_FOLDER/AppleWWDRCA.cer TMP_FOLDER=$PWD/tmp CONFIG='iPhone Distribution: ORG (TEAMID)' SHARED_PROFILE_FOLDER=$HOME/Library/MobileDevice/Provisioning Profiles prepare () { mkdir -p $SHARED_PROFILE_FOLDER cp $PROFILE $SHARED_PROFILE_FOLDER mkdir -p $TMP_FOLDER security create-keychain -p $PASS $KC security list-keychains -d user -s $LKC $KC security import $WWDR -k $KC -t cert -A -P '' security import $KEY -k $KC -t priv -A -P '' security import $CERT -k $KC -t cert -A -P '' security default-keychain -d user -s $KC security unlock-keychain -p $PASS $KC
2
0
2.5k
Feb ’17
Code Sign Error
My app won't run and I get the message:Code Sign Error:SecKey API returned: -25304, (null)/Users/scottglickman/Library/Developer/Xcode/DerivedData/------------alygwtpfdrajvmaamwzrurcxzuuz/Build/Products/Debug-iphoneos/---------.app: unknown error -1=ffffffffffffffffCommand /usr/bin/codesign failed with exit code 1I've sent two separate requests to Apple for support and they just won't respond.I have an automatic manage signing and an XCode Managed Profile.I've cleaned the project and deleted derived data multiple times. I've rebooted the computer. Nothing works.Can anyone tell me how to fix this?Thanks
1
0
800
Mar ’17
Bug in codesign and SecCodeCheckValidityWithErrors?
Problem:I have a command line tool that is codesigned with a valid Developer ID Application certificate/identity (which expires in 2018)When this command line tool is checked in its build folder with codesign -vvvvvvvvv, everything is OK:mytool: valid on diskmytool: satisfies its Designated RequirementWhen this command line tool is checked in its installed location with codesign -vvvvvvvvv, there is a problem:mytool: invalid signature (code or signature have been modified)In architecture: x86_64Now, the weird part:- the md5 for the 2 instances are the same- the sha-1 for the 2 instances are the same- if I rename the instance in the installed location like this:mv mytool mytool2and then check with codesign -vvvvvvvv, everything is OK.If I put back the old name and check it with codesign -vvvvvvvv, same problem about the invalid signature.Note:If the running process mytool (in the installed location) is checked with SecCodeCheckValidityWithErrors, an error is returne
3
0
1.3k
Mar ’17
Reply to Bug in codesign and SecCodeCheckValidityWithErrors?
Of course, this error code is not documented.That’d be errSecCSSignatureFailed, from <Security/CSCommon.h>. Just FYI, QA1499 Security Framework Error Codes is a great resource for this sort of thing.If the executable is codesigned and then put inside the MacOS folder of a bundle whose CFBundleExecutable is set to the name of the executable, then the coesign validation will fail if the bundle itself is not codesigned.Ah, yes. The exact definition of a bundle has always been a bit fuzzy and code signing has to use various heuristics (guesses) for determine whether something is a bundle or not.I will file a bug report to get error -67061 be properly documented.Thanks.Share and Enjoy — Quinn “The Eskimo!” Apple Developer Relations, Developer Technical Support, Core OS/Hardware let myEmail = eskimo + 1 + @apple.com
Topic: Privacy & Security SubTopic: General Tags:
Mar ’17
Reply to How to test capabilities entitlements file?
What sort of test are you trying to do? A functionality test (that is, do the entitlements actually work)? Or just a static test of the entitlements? If it’s the latter, you can dump the entitlements with the following command:$ codesign -d --entitlements :- /path/to/your.appafter which you can verify them however you like.Share and Enjoy — Quinn “The Eskimo!” Apple Developer Relations, Developer Technical Support, Core OS/Hardware let myEmail = eskimo + 1 + @apple.com
Mar ’17
Reply to Xcode 8 can't archive “Command /usr/bin/codesign failed with exit code 1”
I bought a new Macbook pro 2015 with Sierra installed .I have been usuing xcode 8.2.1 with my macbook air with El Capitan and no problems. Now all I get is a codesign fail with exit code with my macbook pro. Maybe I missed something along the line conserning Sierra. However in my case it does not like images that are tiff. I remove all tiff images and it works. This is for both osx and ios.
Mar ’17
What's the error for this Code Sign Error and how to fix it?
Hi All,I am receiving the code sign error :I cant test with the in-built simulator or archive. CodeSign /Users/winston/Library/Developer/Xcode/DerivedData/Oddbods_Stickers-hfazfvyucidfdghkyqchigqfnpyt/Build/Products/Debug-iphonesimulator/Oddbods Stickers.app cd /Users/winston/Desktop/Oddbods Stickers export CODESIGN_ALLOCATE=/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/codesign_allocate export PATH=/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin:/Applications/Xcode.app/Contents/Developer/usr/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin Signing Identity: - /usr/bin/codesign --force --sign - --timestamp=none /Users/winston/Library/Developer/Xcode/DerivedData/Oddbods_Stickers-hfazfvyucidfdghkyqchigqfnpyt/Build/Products/Debug-iphonesimulator/Oddbods Stickers.app/Users/winston/Library/Developer/Xcode/DerivedData/Oddbods_Stickers-hfazfvyucidfdghkyqchigqfnpyt/Build/Products/Debug-iphonesimulator/Oddbods St
3
0
3.3k
Mar ’17
Kernel Extension validation did change?
Observations:In which specific version of Mac OS X, OS X, macOS did the validation code for Kernel Extension changed?In macOS Sierra 10.12.4b, trying to load a kernel extension with extra files in the _CodeSignature folder fails and codesign -vvvvv explains the reason: unsealed contents present in the bundle root.In OS X 10.11.6, the same kernel extension (with the extra files) loads fine and codesign -vvvvvv states that all the requirements are met.Question:Did this change with macOS Sierra 10.12.3? Has there been a release note about this?
0
0
460
Mar ’17
No receipt generated for sandbox App Store app
I'm trying to launch an app generated with Xcode that should get a sandbox receipt in 10.12.4 Beta (16E189a). The app checks whether it has a receipt and if it doesn't, it exits with 173 so that macOS can show the App Store login dialog and generate a receipt. This used to work.However, on said beta, when I click on the freshly built app the icon appears in the dock for a very short time, then disappears… and nothing else happens. No dialog. No receipt.In the console log, I can see this:default 11:08:20.480048 +0100 storeassetd MacOS error: -67050 default 11:08:20.480695 +0100 storeassetd MacOS error: -67050 default 11:08:20.480934 +0100 storeassetd ISCodeSignatureOperation: isDeveloperSigned = 0 default 11:08:20.485024 +0100 storeassetd MacOS error: -67050 default 11:08:20.485099 +0100 storeassetd MacOS error: -67050 default 11:08:20.485292 +0100 storeassetd ISCodeSignatureOperation: isAppleSigned = 0 default 11:08:20.485475 +0100 storeassetd Unsigned app (/path/to/test.app). default 11:08:20.485797 +0100 st
0
0
884
Mar ’17
Does Xcode handle code signing sub frameworks in umbrella frameworks?
I am attempting to ship an umbrella dynamic framework for other apps to use. I understand that Apple recommends not to use umbrella frameworks but in this case I am the owner of the umbrella framework and *all* of its subframeworks.It turns out that when a developer consumes my umbrella framework only the umbrella one ends up codesigned and the sub frameworks are not code signed. This causes a crash when launching the app.Is there a way to tell Xcode to code sign all the sub frameworks as well or a setting to enable this? Do I have to force developers to include a build phase script that re-signs the internal frameworks? The latter sounds like a bad experience and would prefer to avoid it.
3
0
914
Mar ’17
Reply to How to test capabilities entitlements file?
You certainly don’t want to look at the .entitlements file. That’s one input to the code signing process, but you really want to test the output. That output is baked into the code signature, and you can dump it like so: $ codesign -d --entitlements :- /path/to/your.appShare and Enjoy — Quinn “The Eskimo!” Apple Developer Relations, Developer Technical Support, Core OS/Hardware let myEmail = eskimo + 1 + @apple.com
Mar ’17
Reply to PacketTunnelProvider not work
You need to dump the entitlements of the built binary, not the .entitlements file or the .xcent file. That means running the codesign tool on the built binary of both the app and the extension nested within the app, as described in the Debugging Entitlement Issues post a referenced earlier. The is really important; the OS doesn’t look at your .entitlements file or your .xcent file, it looks at your built executable. Share and Enjoy — Quinn “The Eskimo!” Apple Developer Relations, Developer Technical Support, Core OS/Hardware let myEmail = eskimo + 1 + @apple.com
Mar ’17
Reply to PacketTunnelProvider not work
I sorry,This flow is the command codesign -d --entitlements output of the container app and extension app,there seens not incorrect.Executable=/Users/antonycui/Library/Developer/Xcode/DerivedData/testTunnel-cnomglujrazpnvfcbkthtcznqten/Build/Products/Debug/testTunnel.app/Contents/MacOS/testTunnel<?xml version=1.0 encoding=UTF-8?><!DOCTYPE plist PUBLIC -/<plist version=1.0><dict> <key>com.apple.application-identifier</key> <string>H3DPC4EH35.com.myTunnel.testTunnel</string> <key>com.apple.developer.networking.networkextension</key> <array> <string>packet-tunnel-provider</string> <string>app-proxy-provider</string> <string>content-filter-provider</string> </array> <key>com.apple.developer.networking.vpn.api</key> <array> <string>allow-vpn</string> </array> <key>com.apple.developer.team-identifier</key> <string>H3DPC4EH35</string> <key>
Mar ’17
codesign reports good but package still flagged by Gatekeeper
I'm using my 3rd Party Developer and 3rd Party Installer certs to codesign an app bundle and then the package for that app for non-MAS distribution. Both operations report success and running codesign -vv /Applications/application.app reports:/Applications/application.app: valid on disk/Applications/application.app: satisfies its Designated RequirementHowever, when I transfer the PKG file to a server and then download it onto another system, Gatekeeper tells me that the app is from an unidentified developer. I have verified my certificates in Keychain Access and they match what is included with my developer account on developer.apple.com.Anyone have pointers as to what to check next?
Replies
6
Boosts
0
Views
808
Activity
Feb ’17
Distribution certificate and codesign cli
Hello there,I am trying to import my ios distribution certificate and key to a custom keychain so I can codesign my unsigned .app file with the following script:#!/bin/bash PASS='12345' KC=$HOME/Library/Keychains/custom.keychain LKC='login.keychain' CERT_FOLDER=$PWD/certificates PROFILE_NAME='MOBPROFILE.mobileprovision' PROFILE=$CERT_FOLDER/$PROFILE_NAME KEY=$CERT_FOLDER/private_key.pem CERT=$CERT_FOLDER/ios_distribution.cer APP=$PWD/myapp.app WWDR=$CERT_FOLDER/AppleWWDRCA.cer TMP_FOLDER=$PWD/tmp CONFIG='iPhone Distribution: ORG (TEAMID)' SHARED_PROFILE_FOLDER=$HOME/Library/MobileDevice/Provisioning Profiles prepare () { mkdir -p $SHARED_PROFILE_FOLDER cp $PROFILE $SHARED_PROFILE_FOLDER mkdir -p $TMP_FOLDER security create-keychain -p $PASS $KC security list-keychains -d user -s $LKC $KC security import $WWDR -k $KC -t cert -A -P '' security import $KEY -k $KC -t priv -A -P '' security import $CERT -k $KC -t cert -A -P '' security default-keychain -d user -s $KC security unlock-keychain -p $PASS $KC
Replies
2
Boosts
0
Views
2.5k
Activity
Feb ’17
Code Sign Error
My app won't run and I get the message:Code Sign Error:SecKey API returned: -25304, (null)/Users/scottglickman/Library/Developer/Xcode/DerivedData/------------alygwtpfdrajvmaamwzrurcxzuuz/Build/Products/Debug-iphoneos/---------.app: unknown error -1=ffffffffffffffffCommand /usr/bin/codesign failed with exit code 1I've sent two separate requests to Apple for support and they just won't respond.I have an automatic manage signing and an XCode Managed Profile.I've cleaned the project and deleted derived data multiple times. I've rebooted the computer. Nothing works.Can anyone tell me how to fix this?Thanks
Replies
1
Boosts
0
Views
800
Activity
Mar ’17
Bug in codesign and SecCodeCheckValidityWithErrors?
Problem:I have a command line tool that is codesigned with a valid Developer ID Application certificate/identity (which expires in 2018)When this command line tool is checked in its build folder with codesign -vvvvvvvvv, everything is OK:mytool: valid on diskmytool: satisfies its Designated RequirementWhen this command line tool is checked in its installed location with codesign -vvvvvvvvv, there is a problem:mytool: invalid signature (code or signature have been modified)In architecture: x86_64Now, the weird part:- the md5 for the 2 instances are the same- the sha-1 for the 2 instances are the same- if I rename the instance in the installed location like this:mv mytool mytool2and then check with codesign -vvvvvvvv, everything is OK.If I put back the old name and check it with codesign -vvvvvvvv, same problem about the invalid signature.Note:If the running process mytool (in the installed location) is checked with SecCodeCheckValidityWithErrors, an error is returne
Replies
3
Boosts
0
Views
1.3k
Activity
Mar ’17
Reply to Bug in codesign and SecCodeCheckValidityWithErrors?
Answer to the second question:If the executable is codesigned and then put inside the MacOS folder of a bundle whose CFBundleExecutable is set to the name of the executable, then the coesign validation will fail if the bundle itself is not codesigned.I will file a bug report to get error -67061 be properly documented.
Topic: Privacy & Security SubTopic: General Tags:
Replies
Boosts
Views
Activity
Mar ’17
Reply to Bug in codesign and SecCodeCheckValidityWithErrors?
Of course, this error code is not documented.That’d be errSecCSSignatureFailed, from <Security/CSCommon.h>. Just FYI, QA1499 Security Framework Error Codes is a great resource for this sort of thing.If the executable is codesigned and then put inside the MacOS folder of a bundle whose CFBundleExecutable is set to the name of the executable, then the coesign validation will fail if the bundle itself is not codesigned.Ah, yes. The exact definition of a bundle has always been a bit fuzzy and code signing has to use various heuristics (guesses) for determine whether something is a bundle or not.I will file a bug report to get error -67061 be properly documented.Thanks.Share and Enjoy — Quinn “The Eskimo!” Apple Developer Relations, Developer Technical Support, Core OS/Hardware let myEmail = eskimo + 1 + @apple.com
Topic: Privacy & Security SubTopic: General Tags:
Replies
Boosts
Views
Activity
Mar ’17
Reply to How to test capabilities entitlements file?
What sort of test are you trying to do? A functionality test (that is, do the entitlements actually work)? Or just a static test of the entitlements? If it’s the latter, you can dump the entitlements with the following command:$ codesign -d --entitlements :- /path/to/your.appafter which you can verify them however you like.Share and Enjoy — Quinn “The Eskimo!” Apple Developer Relations, Developer Technical Support, Core OS/Hardware let myEmail = eskimo + 1 + @apple.com
Replies
Boosts
Views
Activity
Mar ’17
Reply to Xcode 8 can't archive “Command /usr/bin/codesign failed with exit code 1”
I bought a new Macbook pro 2015 with Sierra installed .I have been usuing xcode 8.2.1 with my macbook air with El Capitan and no problems. Now all I get is a codesign fail with exit code with my macbook pro. Maybe I missed something along the line conserning Sierra. However in my case it does not like images that are tiff. I remove all tiff images and it works. This is for both osx and ios.
Replies
Boosts
Views
Activity
Mar ’17
What's the error for this Code Sign Error and how to fix it?
Hi All,I am receiving the code sign error :I cant test with the in-built simulator or archive. CodeSign /Users/winston/Library/Developer/Xcode/DerivedData/Oddbods_Stickers-hfazfvyucidfdghkyqchigqfnpyt/Build/Products/Debug-iphonesimulator/Oddbods Stickers.app cd /Users/winston/Desktop/Oddbods Stickers export CODESIGN_ALLOCATE=/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/codesign_allocate export PATH=/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin:/Applications/Xcode.app/Contents/Developer/usr/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin Signing Identity: - /usr/bin/codesign --force --sign - --timestamp=none /Users/winston/Library/Developer/Xcode/DerivedData/Oddbods_Stickers-hfazfvyucidfdghkyqchigqfnpyt/Build/Products/Debug-iphonesimulator/Oddbods Stickers.app/Users/winston/Library/Developer/Xcode/DerivedData/Oddbods_Stickers-hfazfvyucidfdghkyqchigqfnpyt/Build/Products/Debug-iphonesimulator/Oddbods St
Replies
3
Boosts
0
Views
3.3k
Activity
Mar ’17
Kernel Extension validation did change?
Observations:In which specific version of Mac OS X, OS X, macOS did the validation code for Kernel Extension changed?In macOS Sierra 10.12.4b, trying to load a kernel extension with extra files in the _CodeSignature folder fails and codesign -vvvvv explains the reason: unsealed contents present in the bundle root.In OS X 10.11.6, the same kernel extension (with the extra files) loads fine and codesign -vvvvvv states that all the requirements are met.Question:Did this change with macOS Sierra 10.12.3? Has there been a release note about this?
Replies
0
Boosts
0
Views
460
Activity
Mar ’17
No receipt generated for sandbox App Store app
I'm trying to launch an app generated with Xcode that should get a sandbox receipt in 10.12.4 Beta (16E189a). The app checks whether it has a receipt and if it doesn't, it exits with 173 so that macOS can show the App Store login dialog and generate a receipt. This used to work.However, on said beta, when I click on the freshly built app the icon appears in the dock for a very short time, then disappears… and nothing else happens. No dialog. No receipt.In the console log, I can see this:default 11:08:20.480048 +0100 storeassetd MacOS error: -67050 default 11:08:20.480695 +0100 storeassetd MacOS error: -67050 default 11:08:20.480934 +0100 storeassetd ISCodeSignatureOperation: isDeveloperSigned = 0 default 11:08:20.485024 +0100 storeassetd MacOS error: -67050 default 11:08:20.485099 +0100 storeassetd MacOS error: -67050 default 11:08:20.485292 +0100 storeassetd ISCodeSignatureOperation: isAppleSigned = 0 default 11:08:20.485475 +0100 storeassetd Unsigned app (/path/to/test.app). default 11:08:20.485797 +0100 st
Replies
0
Boosts
0
Views
884
Activity
Mar ’17
Does Xcode handle code signing sub frameworks in umbrella frameworks?
I am attempting to ship an umbrella dynamic framework for other apps to use. I understand that Apple recommends not to use umbrella frameworks but in this case I am the owner of the umbrella framework and *all* of its subframeworks.It turns out that when a developer consumes my umbrella framework only the umbrella one ends up codesigned and the sub frameworks are not code signed. This causes a crash when launching the app.Is there a way to tell Xcode to code sign all the sub frameworks as well or a setting to enable this? Do I have to force developers to include a build phase script that re-signs the internal frameworks? The latter sounds like a bad experience and would prefer to avoid it.
Replies
3
Boosts
0
Views
914
Activity
Mar ’17
Reply to How to test capabilities entitlements file?
You certainly don’t want to look at the .entitlements file. That’s one input to the code signing process, but you really want to test the output. That output is baked into the code signature, and you can dump it like so: $ codesign -d --entitlements :- /path/to/your.appShare and Enjoy — Quinn “The Eskimo!” Apple Developer Relations, Developer Technical Support, Core OS/Hardware let myEmail = eskimo + 1 + @apple.com
Replies
Boosts
Views
Activity
Mar ’17
Reply to PacketTunnelProvider not work
You need to dump the entitlements of the built binary, not the .entitlements file or the .xcent file. That means running the codesign tool on the built binary of both the app and the extension nested within the app, as described in the Debugging Entitlement Issues post a referenced earlier. The is really important; the OS doesn’t look at your .entitlements file or your .xcent file, it looks at your built executable. Share and Enjoy — Quinn “The Eskimo!” Apple Developer Relations, Developer Technical Support, Core OS/Hardware let myEmail = eskimo + 1 + @apple.com
Replies
Boosts
Views
Activity
Mar ’17
Reply to PacketTunnelProvider not work
I sorry,This flow is the command codesign -d --entitlements output of the container app and extension app,there seens not incorrect.Executable=/Users/antonycui/Library/Developer/Xcode/DerivedData/testTunnel-cnomglujrazpnvfcbkthtcznqten/Build/Products/Debug/testTunnel.app/Contents/MacOS/testTunnel<?xml version=1.0 encoding=UTF-8?><!DOCTYPE plist PUBLIC -/<plist version=1.0><dict> <key>com.apple.application-identifier</key> <string>H3DPC4EH35.com.myTunnel.testTunnel</string> <key>com.apple.developer.networking.networkextension</key> <array> <string>packet-tunnel-provider</string> <string>app-proxy-provider</string> <string>content-filter-provider</string> </array> <key>com.apple.developer.networking.vpn.api</key> <array> <string>allow-vpn</string> </array> <key>com.apple.developer.team-identifier</key> <string>H3DPC4EH35</string> <key>
Replies
Boosts
Views
Activity
Mar ’17