After updating Xcode to latest version Xcode Server can not be turned on. It fails with error:
Could not export API server SSL certificate: Error Domain=XCSSecurity Code=-1 "OpenSSL: Error decrypting key
4304406060:error:06FFF089:digital envelope routines:CRYPTO_internal:bad key length:/System/Volumes/Data/SWE/macOS/BuildRoots/5b2e67f8af/Library/Caches/com.apple.xbs/Sources/libressl/libressl-75.60.3/libressl-2.8/crypto/apple/hmac/hmac.c:188:
4304406060:error:06FFF078:digital envelope routines:CRYPTO_internal:keygen failure:/System/Volumes/Data/SWE/macOS/BuildRoots/5b2e67f8af/Library/Caches/com.apple.xbs/Sources/libressl/libressl-75.60.3/libressl-2.8/crypto/evp/evp_pbe.c:166:
4304406060:error:23FFF073:PKCS12 routines:func(4095):pkcs12 algor cipherinit error:/System/Volumes/Data/SWE/macOS/BuildRoots/5b2e67f8af/Library/Caches/com.apple.xbs/Sources/libressl/libressl-75.60.3/libressl-2.8/crypto/pkcs12/p12_decr.c:83:
4304406060:error:23FFF075:PKCS12 routines:func(4095):pkcs12 pbe crypt error:/System/Volumes/Data/SWE/macOS/BuildRoots/5b2e67f8af/Library/Caches/com.apple.xbs/Sources/libressl/libressl-75.60.3/libressl-2.8/crypto/pkcs12/p12_decr.c:133:
" UserInfo={NSLocalizedDescription=OpenSSL: Error decrypting key
4304406060:error:06FFF089:digital envelope routines:CRYPTO_internal:bad key length:/System/Volumes/Data/SWE/macOS/BuildRoots/5b2e67f8af/Library/Caches/com.apple.xbs/Sources/libressl/libressl-75.60.3/libressl-2.8/crypto/apple/hmac/hmac.c:188:
4304406060:error:06FFF078:digital envelope routines:CRYPTO_internal:keygen failure:/System/Volumes/Data/SWE/macOS/BuildRoots/5b2e67f8af/Library/Caches/com.apple.xbs/Sources/libressl/libressl-75.60.3/libressl-2.8/crypto/evp/evp_pbe.c:166:
4304406060:error:23FFF073:PKCS12 routines:func(4095):pkcs12 algor cipherinit error:/System/Volumes/Data/SWE/macOS/BuildRoots/5b2e67f8af/Library/Caches/com.apple.xbs/Sources/libressl/libressl-75.60.3/libressl-2.8/crypto/pkcs12/p12_decr.c:83:
4304406060:error:23FFF075:PKCS12 routines:func(4095):pkcs12 pbe crypt error:/System/Volumes/Data/SWE/macOS/BuildRoots/5b2e67f8af/Library/Caches/com.apple.xbs/Sources/libressl/libressl-75.60.3/libressl-2.8/crypto/pkcs12/p12_decr.c:133:
}
Development and Xcode Server runs on the same Mac machine. I have tried to restart xcscontrol, but it did not help.
sudo xcscontrol --reset
In my case here is no SWE folder at this location:
/System/Volumes/Data
How I could fix "Could not export API server SSL..." error?
It looks that needs to install macOS 12.3 beta and use Xcode 13.3 beta or 13.2.1.
If here is another way on fixing this problem I would like to know.
More discussion can be found here.