errSecInternalComponent when using codesign from within a daemon
2
votes
1
answer
740
views
I have my own running daemon application that listens to a network port and executes some different commands based on the coming request. All is working fine except when trying to execute the following
codesign
command.
sudo codesign --force --timestamp --options=runtime --entitlements --sign
Where I see an error saying errSecInternalComponent
. However, when I take the same command and paste it into the terminal it works.
I have my application certificate installed under both login
and System
keychains and set to be Always Trust
in settings.
I tried adding --keychain
option to specify the keychain path for the codesign
command.
Also, I made sure that both login
and System
keychains are unlocked during command execution.
Besides, I tried adding the following key/value pair to my daemon plist
file and restarting it.
SessionCreate
All of the above trials failed to fix the issue, I'm out of ideas and any help would be highly appreciated.
Asked by Mohammad Fneish
(121 rep)
Feb 16, 2022, 11:29 PM
Last activity: Jul 23, 2025, 02:34 AM
Last activity: Jul 23, 2025, 02:34 AM