iOS Question Failed to parse certificate file.Error: security: SecKeychainDelete: The specified keychain could not be found.

techknight

Well-Known Member
Licensed User
Longtime User
I keep getting:

Failed to parse certificate file.Error: security: SecKeychainDelete: The specified keychain could not be found.

Its been a year or so so all my certificates are expired. got the latest b4i, got the latest buildserver running on my mac.

However, after I regenerated my csr, and all that fun stuff, I keep getting the above error no matter what. b4i_bridge, or my regular app. something is going on and I am at a loss.

I even went as far as adding a b4i_default keychain and No Go.

I re-read the certificate tutorial and it hasnt seemed to have changed? So I dont know.
 

sorex

Expert
Licensed User
Longtime User
you don't need to regenerate the csr. you just need to recreate the certificates and renew the provisioning profiles and put them in your keys folder after you downloaded them.

keep in mind that there are several (development, distribution and app specific if you use in-app purchases.)
 
Upvote 0

techknight

Well-Known Member
Licensed User
Longtime User
Yes, I know all of this. I tried re-using the same csr but kept getting failed to parse, but without the keychain issue. Now I have that above keychain issue.

then recreating the csr, and regenerating all new certs and provisioning profiles is now causing this.

Last ditch effort is im going to attempt to hack Mojave to install on my 2010 macbook since I cant upgrade past Xcode 10.1 Maybe thats what it is?
 
Upvote 0

sorex

Expert
Licensed User
Longtime User
you use the local builder?

I use the remote one but went through this yearly misery a few days ago aswell. (but didn't have problems)
 
Upvote 0

techknight

Well-Known Member
Licensed User
Longtime User
Yes I use a local builder. I dont do enough iOS development to have a recurring payment on a hosted builder, as there are no money makers here. Supporting only a couple customers.
 
Upvote 0

techknight

Well-Known Member
Licensed User
Longtime User
So, I installed Mojave and installed the latest version of Xcode that will run on Mojave, and same problem.

I am at a loss. any ideas?
 
Upvote 0

techknight

Well-Known Member
Licensed User
Longtime User
Nope, doing the same thing.

I guess ill try regenerating the csr and the certs for a 3rd time? maybe 3rd time is a charm. haha.

I did not leave the "Unknown" in the password box, I filled that out when I created the csr
 
Upvote 0

techknight

Well-Known Member
Licensed User
Longtime User
nope, regenerating certificates for a 3rd time with a new csr, did not help :-(

B4X:
B4i Version: 6.50
Parsing code.    (0.02s)
Building folders structure.    (0.07s)
Compiling code.    (0.03s)
Building designer app.    (0.04s)
Building Xcode project    (0.66s)
Sending data to remote compiler.    Error
Failed to parse certificate file.Error: security: SecKeychainDelete: The specified keychain could not be found.

Here is my header:
B4X:
'Code module
#Region  Project Attributes
    #ApplicationLabel: Paintball PB00
    #Version: 1.0.5
    'Orientation possible values: Portrait, LandscapeLeft, LandscapeRight and PortraitUpsideDown
    #iPhoneOrientations: LandscapeLeft, LandscapeRight
    #iPadOrientations: LandscapeLeft, LandscapeRight
    #Target: iPhone, iPad
    #ATSEnabled: True
    #MinVersion: 8   
    #IF RELEASE And APPSTORE
        #ProvisionFile: MD_AppStore_Distribution.mobileprovision
        #CertificateFile: ios_distribution.cer
    #Else
        #ProvisionFile: MD_ADHOC_Distribution.mobileprovision
        #CertificateFile: ios_distribution.cer
    #END IF
#End Region

All this stuff worked fine last year.
 
Upvote 0

techknight

Well-Known Member
Licensed User
Longtime User
I give up. I regenerated 2 more times, and followed the updated video tutorial carefully. No difference.

I think theyve changed something recently and B4I needs changed with it.
 
Upvote 0

techknight

Well-Known Member
Licensed User
Longtime User
as a last ditch effort, I re-used my old csr from 2016, and again, no go. still get the unable to parse.

and of course, If I try using my old keys, it will actually parse properly but alerts me that its expired so I know other things are working properly.

Apple must be formatting their current certs differently now?
 
Upvote 0

Semen Matusovskiy

Well-Known Member
Licensed User
Did you try to use MAC's KeyChain utility (Applications, Utilities) ? At first you can comletely delete a topic "<user>-db" (B4I will restore it). Take a look other topics also and delete old certificates (if you will find them)
 
Upvote 0

techknight

Well-Known Member
Licensed User
Longtime User
yes, but I dont know what I am looking for, or what. Is there a keychain tutorial?

Edit: I am not seeing anything like that anywhere.

I have a login, local items, system, and system roots. thats it.
 
Last edited:
Upvote 0

techknight

Well-Known Member
Licensed User
Longtime User
Oh I am idiot. they added Development and made iOS Development separate. I watched the video, but I do not have sound at work, and totally overlooked that detail.

Could someone post that in red bold letters somewhere? to pick IOS Development instead of "Development" even though technically development is supposed to blanket over everything.

Which tells me going forward, they will move ios development by itself into legacy and remove it. If Apple is Apple.
 
Upvote 0

sorex

Expert
Licensed User
Longtime User
I was confused there aswell as 2 or 3 mentiond ios development then I looked at Erel's video and for me it was clear enough what to pick.
 
Upvote 0

techknight

Well-Known Member
Licensed User
Longtime User
it wasnt too clear for me, I need big fat bold letters that take over my screen sometimes. And personally, I like to read. I dont care too much for videos.
 
Upvote 0
Top