Code signing works on one app but fails on another

classic Classic list List threaded Threaded
19 messages Options
Reply | Threaded
Open this post in threaded view
|

Code signing works on one app but fails on another

4D Tech mailing list
Using v17
I've added our Apple OSX signing certificate to a client's app built with
4D v17. It compiles and runs just fine.
I've added the same certificate to another app, using the same version of
4D and the same compiler settings. However with this one, at the end of
compilation, I get the message "Code signature failed".
Any suggestions as to why it would work for one app but not for another? As
far as I can see, the settings are identical.

Pat

--
*************************************************
CatBase - Top Dog in Data Publishing
tel: +44 (0) 207 118 7889
w: http://www.catbase.com
skype: pat.bensky
*************************************************
**********************************************************************
4D Internet Users Group (4D iNUG)
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:[hidden email]
**********************************************************************
Reply | Threaded
Open this post in threaded view
|

Re: Code signing works on one app but fails on another

4D Tech mailing list
Pat:

I struggled with this for a few months. A bunch of research, help from the nug, and help from 4D Tech support, I think I found our problem. We will use a graphic application to create some graphics (icons / pictures etc). As is usual, Apple is getting more strict with each version of the OS for signing. They are permitting less ‘noise’ in the files.

Make of copy of your .4dbase to work with that is uncompiled. The goal is to make a clean development version that you can use from now on that will sign with 4D’s build tool.

In Terminal issue the following:

Pats-Mac-Pro: ~ pat$ codesign —force —deep -s “Developer ID Application: Pat (yourIDHere)” -fvvvv /PathTo/Your.4dbase/

This command goes through all the files in the .dbase directory and clears out things like finder  attributes that are not permitted. If this does the trick you will see that the the application has been signed. If this works, make this your new development version. Subject to adding any new files into the .4dbase it should compile, build and sign using the 4D tool.

Jody

> On Mar 21, 2019, at 5:52 AM, Pat Bensky via 4D_Tech <[hidden email]> wrote:
>
> Using v17
> I've added our Apple OSX signing certificate to a client's app built with
> 4D v17. It compiles and runs just fine.
> I've added the same certificate to another app, using the same version of
> 4D and the same compiler settings. However with this one, at the end of
> compilation, I get the message "Code signature failed".
> Any suggestions as to why it would work for one app but not for another? As
> far as I can see, the settings are identical.
>
> Pat
>

**********************************************************************
4D Internet Users Group (4D iNUG)
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:[hidden email]
**********************************************************************
Reply | Threaded
Open this post in threaded view
|

Re: Code signing works on one app but fails on another

4D Tech mailing list
Thanks Jody - I will try that.
Pat

On Thu, 21 Mar 2019 at 14:17, Jody Bevan via 4D_Tech <[hidden email]>
wrote:

> Pat:
>
> I struggled with this for a few months. A bunch of research, help from the
> nug, and help from 4D Tech support, I think I found our problem. We will
> use a graphic application to create some graphics (icons / pictures etc).
> As is usual, Apple is getting more strict with each version of the OS for
> signing. They are permitting less ‘noise’ in the files.
>
> Make of copy of your .4dbase to work with that is uncompiled. The goal is
> to make a clean development version that you can use from now on that will
> sign with 4D’s build tool.
>
> In Terminal issue the following:
>
> Pats-Mac-Pro: ~ pat$ codesign —force —deep -s “Developer ID Application:
> Pat (yourIDHere)” -fvvvv /PathTo/Your.4dbase/
>
> This command goes through all the files in the .dbase directory and clears
> out things like finder  attributes that are not permitted. If this does the
> trick you will see that the the application has been signed. If this works,
> make this your new development version. Subject to adding any new files
> into the .4dbase it should compile, build and sign using the 4D tool.
>
> Jody
>
> > On Mar 21, 2019, at 5:52 AM, Pat Bensky via 4D_Tech <
> [hidden email]> wrote:
> >
> > Using v17
> > I've added our Apple OSX signing certificate to a client's app built with
> > 4D v17. It compiles and runs just fine.
> > I've added the same certificate to another app, using the same version of
> > 4D and the same compiler settings. However with this one, at the end of
> > compilation, I get the message "Code signature failed".
> > Any suggestions as to why it would work for one app but not for another?
> As
> > far as I can see, the settings are identical.
> >
> > Pat
> >
>
> **********************************************************************
> 4D Internet Users Group (4D iNUG)
> Archive:  http://lists.4d.com/archives.html
> Options: https://lists.4d.com/mailman/options/4d_tech
> Unsub:  mailto:[hidden email]
> **********************************************************************



--
*************************************************
CatBase - Top Dog in Data Publishing
tel: +44 (0) 207 118 7889
w: http://www.catbase.com
skype: pat.bensky
*************************************************
**********************************************************************
4D Internet Users Group (4D iNUG)
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:[hidden email]
**********************************************************************
Reply | Threaded
Open this post in threaded view
|

Re: Code signing works on one app but fails on another

4D Tech mailing list
In reply to this post by 4D Tech mailing list
I have been copying lines similar to these and then pasting them into the Terminal.  Not sure about the details of these steps, but the app installs and runs.  The pkg file ends up in the Home folder.

// At the $ prompt (if the app is in the Documents folder)
xattr -cr "Documents/myApp.app"
codesign --force --deep -s "Mac Developer: My Name (mynumber)" -fvvvv "Documents/myApp.app"
codesign -dvvv "Documents/myApp.app"

// Move the app to Applications then Build a signed package (before running the app after signing it)
productbuild --component /Applications/myApp.app /Applications myApp.pkg --sign "Developer ID Installer: My Name (mynumber)"

Keith - CDI

> On Mar 21, 2019, at 6:52 AM, Pat Bensky via 4D_Tech <[hidden email]> wrote:
>
> Using v17
> I've added our Apple OSX signing certificate to a client's app built with
> 4D v17. It compiles and runs just fine.
> I've added the same certificate to another app, using the same version of
> 4D and the same compiler settings. However with this one, at the end of
> compilation, I get the message "Code signature failed".
> Any suggestions as to why it would work for one app but not for another? As
> far as I can see, the settings are identical.
>
> Pat
 
**********************************************************************
4D Internet Users Group (4D iNUG)
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:[hidden email]
**********************************************************************
Reply | Threaded
Open this post in threaded view
|

Re: Code signing works on one app but fails on another

4D Tech mailing list
In reply to this post by 4D Tech mailing list
Pat, I had a similar message. I use Dropbox to backup and sync and it was adding extended attributes to some of the files. When I added a command to remove extended attributes before codesigning, it began to work.

        LAUNCH EXTERNAL PROCESS("xattr -cr "+$appPath)
               
Just a thought

Jeremy

> On 21 Mar 2019, at 11:52, Pat Bensky via 4D_Tech <[hidden email]> wrote:
>
> Using v17
> I've added our Apple OSX signing certificate to a client's app built with
> 4D v17. It compiles and runs just fine.
> I've added the same certificate to another app, using the same version of
> 4D and the same compiler settings. However with this one, at the end of
> compilation, I get the message "Code signature failed".
> Any suggestions as to why it would work for one app but not for another? As
> far as I can see, the settings are identical.
>
> Pat

**********************************************************************
4D Internet Users Group (4D iNUG)
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:[hidden email]
**********************************************************************
Reply | Threaded
Open this post in threaded view
|

Re: Code signing works on one app but fails on another

4D Tech mailing list
In reply to this post by 4D Tech mailing list
Hi Jody,
Thanks very much for this.
I've tried running doing as you suggested in Terminal but I always get:

Developer: found in both
/Users/patbensky/Library/Keychains/login.keychain-db and
/Library/Keychains/System.keychain (this is all right)

—force: No such file or directory

The pathname for the file is definitely correct - if I run
open /mypathname/

it opens the database.

Any ideas?

Thanks!

Pat

On Thu, 21 Mar 2019 at 14:17, Jody Bevan via 4D_Tech <[hidden email]>
wrote:

> Pat:
>
> I struggled with this for a few months. A bunch of research, help from the
> nug, and help from 4D Tech support, I think I found our problem. We will
> use a graphic application to create some graphics (icons / pictures etc).
> As is usual, Apple is getting more strict with each version of the OS for
> signing. They are permitting less ‘noise’ in the files.
>
> Make of copy of your .4dbase to work with that is uncompiled. The goal is
> to make a clean development version that you can use from now on that will
> sign with 4D’s build tool.
>
> In Terminal issue the following:
>
> Pats-Mac-Pro: ~ pat$ codesign —force —deep -s “Developer ID Application:
> Pat (yourIDHere)” -fvvvv /PathTo/Your.4dbase/
>
> This command goes through all the files in the .dbase directory and clears
> out things like finder  attributes that are not permitted. If this does the
> trick you will see that the the application has been signed. If this works,
> make this your new development version. Subject to adding any new files
> into the .4dbase it should compile, build and sign using the 4D tool.
>
> Jody
>
> > On Mar 21, 2019, at 5:52 AM, Pat Bensky via 4D_Tech <
> [hidden email]> wrote:
> >
> > Using v17
> > I've added our Apple OSX signing certificate to a client's app built with
> > 4D v17. It compiles and runs just fine.
> > I've added the same certificate to another app, using the same version of
> > 4D and the same compiler settings. However with this one, at the end of
> > compilation, I get the message "Code signature failed".
> > Any suggestions as to why it would work for one app but not for another?
> As
> > far as I can see, the settings are identical.
> >
> > Pat
> >
>
> **********************************************************************
> 4D Internet Users Group (4D iNUG)
> Archive:  http://lists.4d.com/archives.html
> Options: https://lists.4d.com/mailman/options/4d_tech
> Unsub:  mailto:[hidden email]
> **********************************************************************



--
*************************************************
CatBase - Top Dog in Data Publishing
tel: +44 (0) 207 118 7889
w: http://www.catbase.com
skype: pat.bensky
*************************************************
**********************************************************************
4D Internet Users Group (4D iNUG)
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:[hidden email]
**********************************************************************
Reply | Threaded
Open this post in threaded view
|

Re: Code signing works on one app but fails on another

4D Tech mailing list
Pat, what’s the character before “force”? In your email, it seems to be an em-dash. I suspect it should be a double-hyphen. The same will apply to the character before “deep”.

Jeremy

> On 2 Apr 2019, at 19:05, Pat Bensky via 4D_Tech <[hidden email]> wrote:
>
> Hi Jody,
> Thanks very much for this.
> I've tried running doing as you suggested in Terminal but I always get:
>
> Developer: found in both
> /Users/patbensky/Library/Keychains/login.keychain-db and
> /Library/Keychains/System.keychain (this is all right)
>
> —force: No such file or directory
>
> The pathname for the file is definitely correct - if I run
> open /mypathname/
>
> it opens the database.
>
> Any ideas?
>
> Thanks!
>
> Pat
>
> On Thu, 21 Mar 2019 at 14:17, Jody Bevan via 4D_Tech <[hidden email]>
> wrote:
>
>> Pat:
>>
>> I struggled with this for a few months. A bunch of research, help from the
>> nug, and help from 4D Tech support, I think I found our problem. We will
>> use a graphic application to create some graphics (icons / pictures etc).
>> As is usual, Apple is getting more strict with each version of the OS for
>> signing. They are permitting less ‘noise’ in the files.
>>
>> Make of copy of your .4dbase to work with that is uncompiled. The goal is
>> to make a clean development version that you can use from now on that will
>> sign with 4D’s build tool.
>>
>> In Terminal issue the following:
>>
>> Pats-Mac-Pro: ~ pat$ codesign —force —deep -s “Developer ID Application:
>> Pat (yourIDHere)” -fvvvv /PathTo/Your.4dbase/
>>
>> This command goes through all the files in the .dbase directory and clears
>> out things like finder  attributes that are not permitted. If this does the
>> trick you will see that the the application has been signed. If this works,
>> make this your new development version. Subject to adding any new files
>> into the .4dbase it should compile, build and sign using the 4D tool.
>>
>> Jody
>>
>>> On Mar 21, 2019, at 5:52 AM, Pat Bensky via 4D_Tech <
>> [hidden email]> wrote:
>>>
>>> Using v17
>>> I've added our Apple OSX signing certificate to a client's app built with
>>> 4D v17. It compiles and runs just fine.
>>> I've added the same certificate to another app, using the same version of
>>> 4D and the same compiler settings. However with this one, at the end of
>>> compilation, I get the message "Code signature failed".
>>> Any suggestions as to why it would work for one app but not for another?
>> As
>>> far as I can see, the settings are identical.
>>>
>>> Pat
>>>
>>
>> **********************************************************************
>> 4D Internet Users Group (4D iNUG)
>> Archive:  http://lists.4d.com/archives.html
>> Options: https://lists.4d.com/mailman/options/4d_tech
>> Unsub:  mailto:[hidden email]
>> **********************************************************************
>
>
>
> --
> *************************************************
> CatBase - Top Dog in Data Publishing
> tel: +44 (0) 207 118 7889
> w: http://www.catbase.com
> skype: pat.bensky
> *************************************************
> **********************************************************************
> 4D Internet Users Group (4D iNUG)
> Archive:  http://lists.4d.com/archives.html
> Options: https://lists.4d.com/mailman/options/4d_tech
> Unsub:  mailto:[hidden email]
> **********************************************************************

**********************************************************************
4D Internet Users Group (4D iNUG)
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:[hidden email]
**********************************************************************
Reply | Threaded
Open this post in threaded view
|

Re: Code signing works on one app but fails on another

4D Tech mailing list
Hi Jeremy,
I've tried different hyphens ...
--force --deep
I get:

ID: No such file or directory

-force -deep
I get:

invalid argument "rce"

?????


On Tue, 2 Apr 2019 at 19:56, Jeremy Roussak via 4D_Tech <
[hidden email]> wrote:

> Pat, what’s the character before “force”? In your email, it seems to be an
> em-dash. I suspect it should be a double-hyphen. The same will apply to the
> character before “deep”.
>
> Jeremy
>
> > On 2 Apr 2019, at 19:05, Pat Bensky via 4D_Tech <[hidden email]>
> wrote:
> >
> > Hi Jody,
> > Thanks very much for this.
> > I've tried running doing as you suggested in Terminal but I always get:
> >
> > Developer: found in both
> > /Users/patbensky/Library/Keychains/login.keychain-db and
> > /Library/Keychains/System.keychain (this is all right)
> >
> > —force: No such file or directory
> >
> > The pathname for the file is definitely correct - if I run
> > open /mypathname/
> >
> > it opens the database.
> >
> > Any ideas?
> >
> > Thanks!
> >
> > Pat
> >
> > On Thu, 21 Mar 2019 at 14:17, Jody Bevan via 4D_Tech <
> [hidden email]>
> > wrote:
> >
> >> Pat:
> >>
> >> I struggled with this for a few months. A bunch of research, help from
> the
> >> nug, and help from 4D Tech support, I think I found our problem. We will
> >> use a graphic application to create some graphics (icons / pictures
> etc).
> >> As is usual, Apple is getting more strict with each version of the OS
> for
> >> signing. They are permitting less ‘noise’ in the files.
> >>
> >> Make of copy of your .4dbase to work with that is uncompiled. The goal
> is
> >> to make a clean development version that you can use from now on that
> will
> >> sign with 4D’s build tool.
> >>
> >> In Terminal issue the following:
> >>
> >> Pats-Mac-Pro: ~ pat$ codesign —force —deep -s “Developer ID Application:
> >> Pat (yourIDHere)” -fvvvv /PathTo/Your.4dbase/
> >>
> >> This command goes through all the files in the .dbase directory and
> clears
> >> out things like finder  attributes that are not permitted. If this does
> the
> >> trick you will see that the the application has been signed. If this
> works,
> >> make this your new development version. Subject to adding any new files
> >> into the .4dbase it should compile, build and sign using the 4D tool.
> >>
> >> Jody
> >>
> >>> On Mar 21, 2019, at 5:52 AM, Pat Bensky via 4D_Tech <
> >> [hidden email]> wrote:
> >>>
> >>> Using v17
> >>> I've added our Apple OSX signing certificate to a client's app built
> with
> >>> 4D v17. It compiles and runs just fine.
> >>> I've added the same certificate to another app, using the same version
> of
> >>> 4D and the same compiler settings. However with this one, at the end of
> >>> compilation, I get the message "Code signature failed".
> >>> Any suggestions as to why it would work for one app but not for
> another?
> >> As
> >>> far as I can see, the settings are identical.
> >>>
> >>> Pat
> >>>
> >>
> >> **********************************************************************
> >> 4D Internet Users Group (4D iNUG)
> >> Archive:  http://lists.4d.com/archives.html
> >> Options: https://lists.4d.com/mailman/options/4d_tech
> >> Unsub:  mailto:[hidden email]
> >> **********************************************************************
> >
> >
> >
> > --
> > *************************************************
> > CatBase - Top Dog in Data Publishing
> > tel: +44 (0) 207 118 7889
> > w: http://www.catbase.com
> > skype: pat.bensky
> > *************************************************
> > **********************************************************************
> > 4D Internet Users Group (4D iNUG)
> > Archive:  http://lists.4d.com/archives.html
> > Options: https://lists.4d.com/mailman/options/4d_tech
> > Unsub:  mailto:[hidden email]
> > **********************************************************************
>
> **********************************************************************
> 4D Internet Users Group (4D iNUG)
> Archive:  http://lists.4d.com/archives.html
> Options: https://lists.4d.com/mailman/options/4d_tech
> Unsub:  mailto:[hidden email]
> **********************************************************************



--
*************************************************
CatBase - Top Dog in Data Publishing
tel: +44 (0) 207 118 7889
w: http://www.catbase.com
skype: pat.bensky
*************************************************
**********************************************************************
4D Internet Users Group (4D iNUG)
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:[hidden email]
**********************************************************************
Reply | Threaded
Open this post in threaded view
|

Re: Code signing works on one app but fails on another

4D Tech mailing list
Pat:

The error No such file or directory, is an error saying that the paths you are giving Terminal are incorrect. One thing that can cause this is if the file name, or the directory path has spaces in the names. Though the OS can handle spaces terminal cannot. You need to put an escape character in front of the space (back slash or forward slash not sure at the moment).

Jody

> On Apr 2, 2019, at 3:47 PM, Pat Bensky via 4D_Tech <[hidden email]> wrote:
>
> Hi Jeremy,
> I've tried different hyphens ...
> --force --deep
> I get:
>
> ID: No such file or directory
>
> -force -deep
> I get:
>
> invalid argument "rce"
>
> ?????
>
>
> On Tue, 2 Apr 2019 at 19:56, Jeremy Roussak via 4D_Tech <
> [hidden email]> wrote:
>
>> Pat, what’s the character before “force”? In your email, it seems to be an
>> em-dash. I suspect it should be a double-hyphen. The same will apply to the
>> character before “deep”.
>>
>> Jeremy
>>
>>> On 2 Apr 2019, at 19:05, Pat Bensky via 4D_Tech <[hidden email]>
>> wrote:
>>>
>>> Hi Jody,
>>> Thanks very much for this.
>>> I've tried running doing as you suggested in Terminal but I always get:
>>>
>>> Developer: found in both
>>> /Users/patbensky/Library/Keychains/login.keychain-db and
>>> /Library/Keychains/System.keychain (this is all right)
>>>
>>> —force: No such file or directory
>>>
>>> The pathname for the file is definitely correct - if I run
>>> open /mypathname/
>>>
>>> it opens the database.
>>>
>>> Any ideas?
>>>
>>> Thanks!
>>>
>>> Pat
>>>
>>> On Thu, 21 Mar 2019 at 14:17, Jody Bevan via 4D_Tech <
>> [hidden email]>
>>> wrote:
>>>
>>>> Pat:
>>>>
>>>> I struggled with this for a few months. A bunch of research, help from
>> the
>>>> nug, and help from 4D Tech support, I think I found our problem. We will
>>>> use a graphic application to create some graphics (icons / pictures
>> etc).
>>>> As is usual, Apple is getting more strict with each version of the OS
>> for
>>>> signing. They are permitting less ‘noise’ in the files.
>>>>
>>>> Make of copy of your .4dbase to work with that is uncompiled. The goal
>> is
>>>> to make a clean development version that you can use from now on that
>> will
>>>> sign with 4D’s build tool.
>>>>
>>>> In Terminal issue the following:
>>>>
>>>> Pats-Mac-Pro: ~ pat$ codesign —force —deep -s “Developer ID Application:
>>>> Pat (yourIDHere)” -fvvvv /PathTo/Your.4dbase/
>>>>
>>>> This command goes through all the files in the .dbase directory and
>> clears
>>>> out things like finder  attributes that are not permitted. If this does
>> the
>>>> trick you will see that the the application has been signed. If this
>> works,
>>>> make this your new development version. Subject to adding any new files
>>>> into the .4dbase it should compile, build and sign using the 4D tool.
>>>>
>>>> Jody
>>>>
>>>>> On Mar 21, 2019, at 5:52 AM, Pat Bensky via 4D_Tech <
>>>> [hidden email]> wrote:
>>>>>
>>>>> Using v17
>>>>> I've added our Apple OSX signing certificate to a client's app built
>> with
>>>>> 4D v17. It compiles and runs just fine.
>>>>> I've added the same certificate to another app, using the same version
>> of
>>>>> 4D and the same compiler settings. However with this one, at the end of
>>>>> compilation, I get the message "Code signature failed".
>>>>> Any suggestions as to why it would work for one app but not for
>> another?
>>>> As
>>>>> far as I can see, the settings are identical.
>>>>>
>>>>> Pat
>>>>>
>>>>
>>>> **********************************************************************
>>>> 4D Internet Users Group (4D iNUG)
>>>> Archive:  http://lists.4d.com/archives.html
>>>> Options: https://lists.4d.com/mailman/options/4d_tech
>>>> Unsub:  mailto:[hidden email]
>>>> **********************************************************************
>>>
>>>
>>>
>>> --
>>> *************************************************
>>> CatBase - Top Dog in Data Publishing
>>> tel: +44 (0) 207 118 7889
>>> w: http://www.catbase.com
>>> skype: pat.bensky
>>> *************************************************
>>> **********************************************************************
>>> 4D Internet Users Group (4D iNUG)
>>> Archive:  http://lists.4d.com/archives.html
>>> Options: https://lists.4d.com/mailman/options/4d_tech
>>> Unsub:  mailto:[hidden email]
>>> **********************************************************************
>>
>> **********************************************************************
>> 4D Internet Users Group (4D iNUG)
>> Archive:  http://lists.4d.com/archives.html
>> Options: https://lists.4d.com/mailman/options/4d_tech
>> Unsub:  mailto:[hidden email]
>> **********************************************************************
>
>
>
> --
> *************************************************
> CatBase - Top Dog in Data Publishing
> tel: +44 (0) 207 118 7889
> w: http://www.catbase.com
> skype: pat.bensky
> *************************************************
> **********************************************************************
> 4D Internet Users Group (4D iNUG)
> Archive:  http://lists.4d.com/archives.html
> Options: https://lists.4d.com/mailman/options/4d_tech
> Unsub:  mailto:[hidden email]
> **********************************************************************

**********************************************************************
4D Internet Users Group (4D iNUG)
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:[hidden email]
**********************************************************************
Reply | Threaded
Open this post in threaded view
|

Re: Code signing works on one app but fails on another

4D Tech mailing list
Hi Jody,
Yes, I thought that might be an issue so I made sure that the pathname had
no spaces, to test it - IE:

/Users/patbensky/Desktop/catbase/CatBasev8b105.4DB

I still get the "No such file or directory" error when I try to run the
code sign code, but it I run simple code to open the file ie:

open /Users/patbensky/Desktop/catbase/CatBasev8b105.4DB

it works OK - it opens the database and asks for a data file, which is what
I'd expect.

So I don't think it is a problem with the pathaname ):

Pat

On Tue, 2 Apr 2019 at 23:15, Jody Bevan via 4D_Tech <[hidden email]>
wrote:

> Pat:
>
> The error No such file or directory, is an error saying that the paths you
> are giving Terminal are incorrect. One thing that can cause this is if the
> file name, or the directory path has spaces in the names. Though the OS can
> handle spaces terminal cannot. You need to put an escape character in front
> of the space (back slash or forward slash not sure at the moment).
>
> Jody
>
> > On Apr 2, 2019, at 3:47 PM, Pat Bensky via 4D_Tech <[hidden email]>
> wrote:
> >
> > Hi Jeremy,
> > I've tried different hyphens ...
> > --force --deep
> > I get:
> >
> > ID: No such file or directory
> >
> > -force -deep
> > I get:
> >
> > invalid argument "rce"
> >
> > ?????
> >
> >
> > On Tue, 2 Apr 2019 at 19:56, Jeremy Roussak via 4D_Tech <
> > [hidden email]> wrote:
> >
> >> Pat, what’s the character before “force”? In your email, it seems to be
> an
> >> em-dash. I suspect it should be a double-hyphen. The same will apply to
> the
> >> character before “deep”.
> >>
> >> Jeremy
> >>
> >>> On 2 Apr 2019, at 19:05, Pat Bensky via 4D_Tech <[hidden email]>
> >> wrote:
> >>>
> >>> Hi Jody,
> >>> Thanks very much for this.
> >>> I've tried running doing as you suggested in Terminal but I always get:
> >>>
> >>> Developer: found in both
> >>> /Users/patbensky/Library/Keychains/login.keychain-db and
> >>> /Library/Keychains/System.keychain (this is all right)
> >>>
> >>> —force: No such file or directory
> >>>
> >>> The pathname for the file is definitely correct - if I run
> >>> open /mypathname/
> >>>
> >>> it opens the database.
> >>>
> >>> Any ideas?
> >>>
> >>> Thanks!
> >>>
> >>> Pat
> >>>
> >>> On Thu, 21 Mar 2019 at 14:17, Jody Bevan via 4D_Tech <
> >> [hidden email]>
> >>> wrote:
> >>>
> >>>> Pat:
> >>>>
> >>>> I struggled with this for a few months. A bunch of research, help from
> >> the
> >>>> nug, and help from 4D Tech support, I think I found our problem. We
> will
> >>>> use a graphic application to create some graphics (icons / pictures
> >> etc).
> >>>> As is usual, Apple is getting more strict with each version of the OS
> >> for
> >>>> signing. They are permitting less ‘noise’ in the files.
> >>>>
> >>>> Make of copy of your .4dbase to work with that is uncompiled. The goal
> >> is
> >>>> to make a clean development version that you can use from now on that
> >> will
> >>>> sign with 4D’s build tool.
> >>>>
> >>>> In Terminal issue the following:
> >>>>
> >>>> Pats-Mac-Pro: ~ pat$ codesign —force —deep -s “Developer ID
> Application:
> >>>> Pat (yourIDHere)” -fvvvv /PathTo/Your.4dbase/
> >>>>
> >>>> This command goes through all the files in the .dbase directory and
> >> clears
> >>>> out things like finder  attributes that are not permitted. If this
> does
> >> the
> >>>> trick you will see that the the application has been signed. If this
> >> works,
> >>>> make this your new development version. Subject to adding any new
> files
> >>>> into the .4dbase it should compile, build and sign using the 4D tool.
> >>>>
> >>>> Jody
> >>>>
> >>>>> On Mar 21, 2019, at 5:52 AM, Pat Bensky via 4D_Tech <
> >>>> [hidden email]> wrote:
> >>>>>
> >>>>> Using v17
> >>>>> I've added our Apple OSX signing certificate to a client's app built
> >> with
> >>>>> 4D v17. It compiles and runs just fine.
> >>>>> I've added the same certificate to another app, using the same
> version
> >> of
> >>>>> 4D and the same compiler settings. However with this one, at the end
> of
> >>>>> compilation, I get the message "Code signature failed".
> >>>>> Any suggestions as to why it would work for one app but not for
> >> another?
> >>>> As
> >>>>> far as I can see, the settings are identical.
> >>>>>
> >>>>> Pat
> >>>>>
> >>>>
> >>>> **********************************************************************
> >>>> 4D Internet Users Group (4D iNUG)
> >>>> Archive:  http://lists.4d.com/archives.html
> >>>> Options: https://lists.4d.com/mailman/options/4d_tech
> >>>> Unsub:  mailto:[hidden email]
> >>>> **********************************************************************
> >>>
> >>>
> >>>
> >>> --
> >>> *************************************************
> >>> CatBase - Top Dog in Data Publishing
> >>> tel: +44 (0) 207 118 7889
> >>> w: http://www.catbase.com
> >>> skype: pat.bensky
> >>> *************************************************
> >>> **********************************************************************
> >>> 4D Internet Users Group (4D iNUG)
> >>> Archive:  http://lists.4d.com/archives.html
> >>> Options: https://lists.4d.com/mailman/options/4d_tech
> >>> Unsub:  mailto:[hidden email]
> >>> **********************************************************************
> >>
> >> **********************************************************************
> >> 4D Internet Users Group (4D iNUG)
> >> Archive:  http://lists.4d.com/archives.html
> >> Options: https://lists.4d.com/mailman/options/4d_tech
> >> Unsub:  mailto:[hidden email]
> >> **********************************************************************
> >
> >
> >
> > --
> > *************************************************
> > CatBase - Top Dog in Data Publishing
> > tel: +44 (0) 207 118 7889
> > w: http://www.catbase.com
> > skype: pat.bensky
> > *************************************************
> > **********************************************************************
> > 4D Internet Users Group (4D iNUG)
> > Archive:  http://lists.4d.com/archives.html
> > Options: https://lists.4d.com/mailman/options/4d_tech
> > Unsub:  mailto:[hidden email]
> > **********************************************************************
>
> **********************************************************************
> 4D Internet Users Group (4D iNUG)
> Archive:  http://lists.4d.com/archives.html
> Options: https://lists.4d.com/mailman/options/4d_tech
> Unsub:  mailto:[hidden email]
> **********************************************************************



--
*************************************************
CatBase - Top Dog in Data Publishing
tel: +44 (0) 207 118 7889
w: http://www.catbase.com
skype: pat.bensky
*************************************************
**********************************************************************
4D Internet Users Group (4D iNUG)
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:[hidden email]
**********************************************************************
Reply | Threaded
Open this post in threaded view
|

Re: Code signing works on one app but fails on another

4D Tech mailing list
the text edit setting "smart dashes" may convert double hyphens to dash,
which is not what you want in this context.

https://support.apple.com/kb/PH23628?locale=ja_JP&viewlocale=en_US

a single hyphen must be used with a short option name (-f)
a double hyphen must be used with a short option name (--force)

-force is therefore an invalid instruction (single hyphen+long option name).

I've posted a utility to ease the process of signing

https://github.com/miyako/4d-utility-build-application

it is written in v17 but the target app path can be any path.

2019/04/03 8:05、Pat Bensky via 4D_Tech <[hidden email]<mailto:[hidden email]>>のメール:
—force: No such file or directory


**********************************************************************
4D Internet Users Group (4D iNUG)
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:[hidden email]
**********************************************************************
Reply | Threaded
Open this post in threaded view
|

Re: Code signing works on one app but fails on another

4D Tech mailing list
Brilliant, thank you Miyako!
Note that I needed to make one change to the code, in the method "code
sign":

Change

$infoPlistPath:=$applicationPath+Folder separator+\

"Contents"+Folder separator+"Info.plist"


to


$infoPlistPath:=$applicationPath+\

"Contents"+Folder separator+"Info.plist"

Pat

On Thu, 4 Apr 2019 at 01:32, Keisuke Miyako via 4D_Tech <
[hidden email]> wrote:

> the text edit setting "smart dashes" may convert double hyphens to dash,
> which is not what you want in this context.
>
> https://support.apple.com/kb/PH23628?locale=ja_JP&viewlocale=en_US
>
> a single hyphen must be used with a short option name (-f)
> a double hyphen must be used with a short option name (--force)
>
> -force is therefore an invalid instruction (single hyphen+long option
> name).
>
> I've posted a utility to ease the process of signing
>
> https://github.com/miyako/4d-utility-build-application
>
> it is written in v17 but the target app path can be any path.
>
> 2019/04/03 8:05、Pat Bensky via 4D_Tech <[hidden email]<mailto:
> [hidden email]>>のメール:
> —force: No such file or directory
>
>
> **********************************************************************
> 4D Internet Users Group (4D iNUG)
> Archive:  http://lists.4d.com/archives.html
> Options: https://lists.4d.com/mailman/options/4d_tech
> Unsub:  mailto:[hidden email]
> **********************************************************************



--
*************************************************
CatBase - Top Dog in Data Publishing
tel: +44 (0) 207 118 7889
w: http://www.catbase.com
skype: pat.bensky
*************************************************
**********************************************************************
4D Internet Users Group (4D iNUG)
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:[hidden email]
**********************************************************************
Reply | Threaded
Open this post in threaded view
|

Re: Code signing works on one app but fails on another

4D Tech mailing list
Actually it doesn't seem to be working ... it seems to corrupt the app in
some way.
It's quite bizarre ... I compile the app, sign it using Miyako's code, and
create a disk image using DropDMG. I check it by mounting the disk image
and installing the app. It runs OK.
Then I upload it to DropBox.
Download it from Dropbox, open it, install it, and it will not run. The app
starts to open and then I get the message "CatBase 8 is damaged and can't
be opened."

Any ideas?

On Thu, 4 Apr 2019 at 11:52, Pat Bensky <[hidden email]> wrote:

> Brilliant, thank you Miyako!
> Note that I needed to make one change to the code, in the method "code
> sign":
>
> Change
>
> $infoPlistPath:=$applicationPath+Folder separator+\
>
> "Contents"+Folder separator+"Info.plist"
>
>
> to
>
>
> $infoPlistPath:=$applicationPath+\
>
> "Contents"+Folder separator+"Info.plist"
>
> Pat
>
> On Thu, 4 Apr 2019 at 01:32, Keisuke Miyako via 4D_Tech <
> [hidden email]> wrote:
>
>> the text edit setting "smart dashes" may convert double hyphens to dash,
>> which is not what you want in this context.
>>
>> https://support.apple.com/kb/PH23628?locale=ja_JP&viewlocale=en_US
>>
>> a single hyphen must be used with a short option name (-f)
>> a double hyphen must be used with a short option name (--force)
>>
>> -force is therefore an invalid instruction (single hyphen+long option
>> name).
>>
>> I've posted a utility to ease the process of signing
>>
>> https://github.com/miyako/4d-utility-build-application
>>
>> it is written in v17 but the target app path can be any path.
>>
>> 2019/04/03 8:05、Pat Bensky via 4D_Tech <[hidden email]<mailto:
>> [hidden email]>>のメール:
>> —force: No such file or directory
>>
>>
>> **********************************************************************
>> 4D Internet Users Group (4D iNUG)
>> Archive:  http://lists.4d.com/archives.html
>> Options: https://lists.4d.com/mailman/options/4d_tech
>> Unsub:  mailto:[hidden email]
>> **********************************************************************
>
>
>
> --
> *************************************************
> CatBase - Top Dog in Data Publishing
> tel: +44 (0) 207 118 7889
> w: http://www.catbase.com
> skype: pat.bensky
> *************************************************
>


--
*************************************************
CatBase - Top Dog in Data Publishing
tel: +44 (0) 207 118 7889
w: http://www.catbase.com
skype: pat.bensky
*************************************************
**********************************************************************
4D Internet Users Group (4D iNUG)
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:[hidden email]
**********************************************************************
Reply | Threaded
Open this post in threaded view
|

Re: Code signing works on one app but fails on another

4D Tech mailing list
Pat:

I use DropBox for this every week. When I bill a .dmg file I upload to Dropbox and for about that last 6 months, when it is downloaded by others it works fine.

Just of note I use DMG Canvas. That should not matter, but it is a point of difference.

Jody

> On Apr 24, 2019, at 10:42 AM, Pat Bensky via 4D_Tech <[hidden email]> wrote:
>
> Actually it doesn't seem to be working ... it seems to corrupt the app in
> some way.
> It's quite bizarre ... I compile the app, sign it using Miyako's code, and
> create a disk image using DropDMG. I check it by mounting the disk image
> and installing the app. It runs OK.
> Then I upload it to DropBox.
> Download it from Dropbox, open it, install it, and it will not run. The app
> starts to open and then I get the message "CatBase 8 is damaged and can't
> be opened."
>
> Any ideas?
>

**********************************************************************
4D Internet Users Group (4D iNUG)
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:[hidden email]
**********************************************************************
Reply | Threaded
Open this post in threaded view
|

Re: Code signing works on one app but fails on another

4D Tech mailing list
In reply to this post by 4D Tech mailing list
compress the dmg (zip it) before uploading to dropbox?


On Wed, 24 Apr 2019 17:42:10 +0100, Pat Bensky via 4D_Tech wrote:

> Actually it doesn't seem to be working ... it seems to corrupt the app in
> some way.
> It's quite bizarre ... I compile the app, sign it using Miyako's code, and
> create a disk image using DropDMG. I check it by mounting the disk image
> and installing the app. It runs OK.
> Then I upload it to DropBox.
> Download it from Dropbox, open it, install it, and it will not run. The app
> starts to open and then I get the message "CatBase 8 is damaged and can't
> be opened."
>
> Any ideas?
>
> On Thu, 4 Apr 2019 at 11:52, Pat Bensky <[hidden email]> wrote:
>
>> Brilliant, thank you Miyako!
>> Note that I needed to make one change to the code, in the method "code
>> sign":
>>
>> Change
>>
>> $infoPlistPath:=$applicationPath+Folder separator+\
>>
>> "Contents"+Folder separator+"Info.plist"
>>
>>
>> to
>>
>>
>> $infoPlistPath:=$applicationPath+\
>>
>> "Contents"+Folder separator+"Info.plist"
>>
>> Pat
>>
>> On Thu, 4 Apr 2019 at 01:32, Keisuke Miyako via 4D_Tech <
>> [hidden email]> wrote:
>>
>>> the text edit setting "smart dashes" may convert double hyphens to dash,
>>> which is not what you want in this context.
>>>
>>> https://support.apple.com/kb/PH23628?locale=ja_JP&viewlocale=en_US
>>>
>>> a single hyphen must be used with a short option name (-f)
>>> a double hyphen must be used with a short option name (--force)
>>>
>>> -force is therefore an invalid instruction (single hyphen+long option
>>> name).
>>>
>>> I've posted a utility to ease the process of signing
>>>
>>> https://github.com/miyako/4d-utility-build-application
>>>
>>> it is written in v17 but the target app path can be any path.
>>>
>>> 2019/04/03 8:05、Pat Bensky via 4D_Tech <[hidden email]<mailto:
>>> [hidden email]>>のメール:
>>> ―force: No such file or directory
>>>
>>>
>>> **********************************************************************
>>> 4D Internet Users Group (4D iNUG)
>>> Archive:  http://lists.4d.com/archives.html
>>> Options: https://lists.4d.com/mailman/options/4d_tech
>>> Unsub:  mailto:[hidden email]
>>> **********************************************************************
>>
>>
>>
>> --
>> *************************************************
>> CatBase - Top Dog in Data Publishing
>> tel: +44 (0) 207 118 7889
>> w: http://www.catbase.com
>> skype: pat.bensky
>> *************************************************
>>
>
>
> --
> *************************************************
> CatBase - Top Dog in Data Publishing
> tel: +44 (0) 207 118 7889
> w: http://www.catbase.com
> skype: pat.bensky
> *************************************************
> **********************************************************************
> 4D Internet Users Group (4D iNUG)
> Archive:  http://lists.4d.com/archives.html
> Options: https://lists.4d.com/mailman/options/4d_tech
> Unsub:  mailto:[hidden email]
> **********************************************************************
---------------
Gas is for washing parts
Alcohol is for drinkin'
Nitromethane is for racing
**********************************************************************
4D Internet Users Group (4D iNUG)
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:[hidden email]
**********************************************************************
Reply | Threaded
Open this post in threaded view
|

Re: Code signing works on one app but fails on another

4D Tech mailing list
In reply to this post by 4D Tech mailing list
Hi Pat,

Did you specify that DropDMG **also** sign the dmg file?

In other words, your app is signed and the DMG file is also signed.

You can sign the DMG through a DropDMG preference.

See “DropDMG -> Preferences -> Configurations”. Look for “Signing”, and enter your Apple Developer credential.

- Jeremy


> On Apr 24, 2019, at 12:42 PM, Pat Bensky via 4D_Tech <[hidden email]> wrote:
>
> compile the app, sign it … and create a disk image using DropDMG

**********************************************************************
4D Internet Users Group (4D iNUG)
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:[hidden email]
**********************************************************************
Reply | Threaded
Open this post in threaded view
|

Re: Code signing works on one app but fails on another

4D Tech mailing list
In reply to this post by 4D Tech mailing list
Are you sure the app is signed correctly? Sometimes an app with invalid signature will launch until it is downloaded from the internet (downloading sets the quarantine flag). I use these commands after signing to double-check that signing worked properly:

  spctl -av "$appPath"
  codesign --verify -v "$appPath"

Also, I launch the app before signing to choose the datafile and update the Info.plist with a more descriptive version string.

Jim Crate

> On Apr 24, 2019, at 9:42 AM, Pat Bensky via 4D_Tech <[hidden email]> wrote:
>
> Actually it doesn't seem to be working ... it seems to corrupt the app in
> some way.
> It's quite bizarre ... I compile the app, sign it using Miyako's code, and
> create a disk image using DropDMG. I check it by mounting the disk image
> and installing the app. It runs OK.
> Then I upload it to DropBox.
> Download it from Dropbox, open it, install it, and it will not run. The app
> starts to open and then I get the message "CatBase 8 is damaged and can't
> be opened."
>
> Any ideas?
>
> On Thu, 4 Apr 2019 at 11:52, Pat Bensky <[hidden email]> wrote:
>
>> Brilliant, thank you Miyako!
>> Note that I needed to make one change to the code, in the method "code
>> sign":
>>
>> Change
>>
>> $infoPlistPath:=$applicationPath+Folder separator+\
>>
>> "Contents"+Folder separator+"Info.plist"
>>
>>
>> to
>>
>>
>> $infoPlistPath:=$applicationPath+\
>>
>> "Contents"+Folder separator+"Info.plist"
>>
>> Pat
>>
>> On Thu, 4 Apr 2019 at 01:32, Keisuke Miyako via 4D_Tech <
>> [hidden email]> wrote:
>>
>>> the text edit setting "smart dashes" may convert double hyphens to dash,
>>> which is not what you want in this context.
>>>
>>> https://support.apple.com/kb/PH23628?locale=ja_JP&viewlocale=en_US
>>>
>>> a single hyphen must be used with a short option name (-f)
>>> a double hyphen must be used with a short option name (--force)
>>>
>>> -force is therefore an invalid instruction (single hyphen+long option
>>> name).
>>>
>>> I've posted a utility to ease the process of signing
>>>
>>> https://github.com/miyako/4d-utility-build-application
>>>
>>> it is written in v17 but the target app path can be any path.
>>>
>>> 2019/04/03 8:05、Pat Bensky via 4D_Tech <[hidden email]<mailto:
>>> [hidden email]>>のメール:
>>> —force: No such file or directory
>>>
>>>
>>> **********************************************************************
>>> 4D Internet Users Group (4D iNUG)
>>> Archive:  http://lists.4d.com/archives.html
>>> Options: https://lists.4d.com/mailman/options/4d_tech
>>> Unsub:  mailto:[hidden email]
>>> **********************************************************************
>>
>>
>>
>> --
>> *************************************************
>> CatBase - Top Dog in Data Publishing
>> tel: +44 (0) 207 118 7889
>> w: http://www.catbase.com
>> skype: pat.bensky
>> *************************************************
>>
>
>
> --
> *************************************************
> CatBase - Top Dog in Data Publishing
> tel: +44 (0) 207 118 7889
> w: http://www.catbase.com
> skype: pat.bensky
> *************************************************
> **********************************************************************
> 4D Internet Users Group (4D iNUG)
> Archive:  http://lists.4d.com/archives.html
> Options: https://lists.4d.com/mailman/options/4d_tech
> Unsub:  mailto:[hidden email]
> **********************************************************************

**********************************************************************
4D Internet Users Group (4D iNUG)
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:[hidden email]
**********************************************************************
Reply | Threaded
Open this post in threaded view
|

Re: Code signing works on one app but fails on another

4D Tech mailing list
Hi Jim,
I ran the following in Terminal to check it:
codesign -dv /Users/patbensky/CatBase\ dev/CatBase\ v8/Final\
Application/CatBase\ 8.app

and this is the result:

Executable=/Users/patbensky/CatBase dev/CatBase v8/Final
Application/CatBase 8.app/Contents/MacOS/CatBase 8

Identifier=4d.com.CatBase 8.app

Format=app bundle with Mach-O thin (x86_64)

CodeDirectory v=20200 size=133812 flags=0x0(none) hashes=4176+3
location=embedded

Signature size=9042

Timestamp=24 Apr 2019 at 23:18:30

Info.plist entries=41

TeamIdentifier=8W63XCXWRA

Sealed Resources version=2 rules=13 files=2018

Internal requirements count=1 size=180

When I ran your suggested code
codesign --verify -v /Users/patbensky/CatBase\ dev/CatBase\ v8/Final\
Application/CatBase\ 8.app

I got:

a sealed resource is missing or invalid

file modified: /Users/patbensky/CatBase dev/CatBase v8/Final
Application/CatBase 8.app/Contents/Database/CatBase 8.4DIndy

file modified: /Users/patbensky/CatBase dev/CatBase v8/Final
Application/CatBase 8.app/Contents/Database/CatBase 8.4DC


So that's a bit more informative ... Any idea what "sealed resource" is
missing or invalid?

On Wed, 24 Apr 2019 at 23:30, Jim Crate via 4D_Tech <[hidden email]>
wrote:

> Are you sure the app is signed correctly? Sometimes an app with invalid
> signature will launch until it is downloaded from the internet (downloading
> sets the quarantine flag). I use these commands after signing to
> double-check that signing worked properly:
>
>   spctl -av "$appPath"
>   codesign --verify -v "$appPath"
>
> Also, I launch the app before signing to choose the datafile and update
> the Info.plist with a more descriptive version string.
>
> Jim Crate
>
> > On Apr 24, 2019, at 9:42 AM, Pat Bensky via 4D_Tech <
> [hidden email]> wrote:
> >
> > Actually it doesn't seem to be working ... it seems to corrupt the app in
> > some way.
> > It's quite bizarre ... I compile the app, sign it using Miyako's code,
> and
> > create a disk image using DropDMG. I check it by mounting the disk image
> > and installing the app. It runs OK.
> > Then I upload it to DropBox.
> > Download it from Dropbox, open it, install it, and it will not run. The
> app
> > starts to open and then I get the message "CatBase 8 is damaged and can't
> > be opened."
> >
> > Any ideas?
> >
> > On Thu, 4 Apr 2019 at 11:52, Pat Bensky <[hidden email]> wrote:
> >
> >> Brilliant, thank you Miyako!
> >> Note that I needed to make one change to the code, in the method "code
> >> sign":
> >>
> >> Change
> >>
> >> $infoPlistPath:=$applicationPath+Folder separator+\
> >>
> >> "Contents"+Folder separator+"Info.plist"
> >>
> >>
> >> to
> >>
> >>
> >> $infoPlistPath:=$applicationPath+\
> >>
> >> "Contents"+Folder separator+"Info.plist"
> >>
> >> Pat
> >>
> >> On Thu, 4 Apr 2019 at 01:32, Keisuke Miyako via 4D_Tech <
> >> [hidden email]> wrote:
> >>
> >>> the text edit setting "smart dashes" may convert double hyphens to
> dash,
> >>> which is not what you want in this context.
> >>>
> >>> https://support.apple.com/kb/PH23628?locale=ja_JP&viewlocale=en_US
> >>>
> >>> a single hyphen must be used with a short option name (-f)
> >>> a double hyphen must be used with a short option name (--force)
> >>>
> >>> -force is therefore an invalid instruction (single hyphen+long option
> >>> name).
> >>>
> >>> I've posted a utility to ease the process of signing
> >>>
> >>> https://github.com/miyako/4d-utility-build-application
> >>>
> >>> it is written in v17 but the target app path can be any path.
> >>>
> >>> 2019/04/03 8:05、Pat Bensky via 4D_Tech <[hidden email]<mailto:
> >>> [hidden email]>>のメール:
> >>> —force: No such file or directory
> >>>
> >>>
> >>> **********************************************************************
> >>> 4D Internet Users Group (4D iNUG)
> >>> Archive:  http://lists.4d.com/archives.html
> >>> Options: https://lists.4d.com/mailman/options/4d_tech
> >>> Unsub:  mailto:[hidden email]
> >>> **********************************************************************
> >>
> >>
> >>
> >> --
> >> *************************************************
> >> CatBase - Top Dog in Data Publishing
> >> tel: +44 (0) 207 118 7889
> >> w: http://www.catbase.com
> >> skype: pat.bensky
> >> *************************************************
> >>
> >
> >
> > --
> > *************************************************
> > CatBase - Top Dog in Data Publishing
> > tel: +44 (0) 207 118 7889
> > w: http://www.catbase.com
> > skype: pat.bensky
> > *************************************************
> > **********************************************************************
> > 4D Internet Users Group (4D iNUG)
> > Archive:  http://lists.4d.com/archives.html
> > Options: https://lists.4d.com/mailman/options/4d_tech
> > Unsub:  mailto:[hidden email]
> > **********************************************************************
>
> **********************************************************************
> 4D Internet Users Group (4D iNUG)
> Archive:  http://lists.4d.com/archives.html
> Options: https://lists.4d.com/mailman/options/4d_tech
> Unsub:  mailto:[hidden email]
> **********************************************************************



--
*************************************************
CatBase - Top Dog in Data Publishing
tel: +44 (0) 207 118 7889
w: http://www.catbase.com
skype: pat.bensky
*************************************************
**********************************************************************
4D Internet Users Group (4D iNUG)
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:[hidden email]
**********************************************************************
Reply | Threaded
Open this post in threaded view
|

Re: Code signing works on one app but fails on another

4D Tech mailing list
I got the same result on the app after I ran it.  The app does launch properly. However, those changes happened after the app was downloaded.

-> codesign --verify -v T19.app
T19.app: a sealed resource is missing or invalid
file modified: /T19/T19.app/Contents/Database/T19.4DIndy
file modified: /T19/T19.app/Contents/Database/T19.4DC

Before uploading, this is the result:

-> codesign --verify -v T19/T19.app
T19/T19.app: valid on disk
T19/T19.app: satisfies its Designated Requirement

So from that state, I compress and upload the app, and when downloaded, the signature is still valid. The app then needs to be moved to a folder other than the Download folder. If you run the app from a disk image or Downloads folder you will likely run into problems with quarantine, because the app will be translocated when run.

Jim Crate

> On Apr 24, 2019, at 3:39 PM, Pat Bensky via 4D_Tech <[hidden email]> wrote:
>
> Hi Jim,
> I ran the following in Terminal to check it:
> codesign -dv /Users/patbensky/CatBase\ dev/CatBase\ v8/Final\
> Application/CatBase\ 8.app
>
> and this is the result:
>
> Executable=/Users/patbensky/CatBase dev/CatBase v8/Final
> Application/CatBase 8.app/Contents/MacOS/CatBase 8
>
> Identifier=4d.com.CatBase 8.app
>
> Format=app bundle with Mach-O thin (x86_64)
>
> CodeDirectory v=20200 size=133812 flags=0x0(none) hashes=4176+3
> location=embedded
>
> Signature size=9042
>
> Timestamp=24 Apr 2019 at 23:18:30
>
> Info.plist entries=41
>
> TeamIdentifier=8W63XCXWRA
>
> Sealed Resources version=2 rules=13 files=2018
>
> Internal requirements count=1 size=180
>
> When I ran your suggested code
> codesign --verify -v /Users/patbensky/CatBase\ dev/CatBase\ v8/Final\
> Application/CatBase\ 8.app
>
> I got:
>
> a sealed resource is missing or invalid
>
> file modified: /Users/patbensky/CatBase dev/CatBase v8/Final
> Application/CatBase 8.app/Contents/Database/CatBase 8.4DIndy
>
> file modified: /Users/patbensky/CatBase dev/CatBase v8/Final
> Application/CatBase 8.app/Contents/Database/CatBase 8.4DC
>
>
> So that's a bit more informative ... Any idea what "sealed resource" is
> missing or invalid?
>
> On Wed, 24 Apr 2019 at 23:30, Jim Crate via 4D_Tech <[hidden email]>
> wrote:
>
>> Are you sure the app is signed correctly? Sometimes an app with invalid
>> signature will launch until it is downloaded from the internet (downloading
>> sets the quarantine flag). I use these commands after signing to
>> double-check that signing worked properly:
>>
>>  spctl -av "$appPath"
>>  codesign --verify -v "$appPath"
>>
>> Also, I launch the app before signing to choose the datafile and update
>> the Info.plist with a more descriptive version string.
>>
>> Jim Crate
>>
>>> On Apr 24, 2019, at 9:42 AM, Pat Bensky via 4D_Tech <
>> [hidden email]> wrote:
>>>
>>> Actually it doesn't seem to be working ... it seems to corrupt the app in
>>> some way.
>>> It's quite bizarre ... I compile the app, sign it using Miyako's code,
>> and
>>> create a disk image using DropDMG. I check it by mounting the disk image
>>> and installing the app. It runs OK.
>>> Then I upload it to DropBox.
>>> Download it from Dropbox, open it, install it, and it will not run. The
>> app
>>> starts to open and then I get the message "CatBase 8 is damaged and can't
>>> be opened."
>>>
>>> Any ideas?
>>>
>>> On Thu, 4 Apr 2019 at 11:52, Pat Bensky <[hidden email]> wrote:
>>>
>>>> Brilliant, thank you Miyako!
>>>> Note that I needed to make one change to the code, in the method "code
>>>> sign":
>>>>
>>>> Change
>>>>
>>>> $infoPlistPath:=$applicationPath+Folder separator+\
>>>>
>>>> "Contents"+Folder separator+"Info.plist"
>>>>
>>>>
>>>> to
>>>>
>>>>
>>>> $infoPlistPath:=$applicationPath+\
>>>>
>>>> "Contents"+Folder separator+"Info.plist"
>>>>
>>>> Pat
>>>>
>>>> On Thu, 4 Apr 2019 at 01:32, Keisuke Miyako via 4D_Tech <
>>>> [hidden email]> wrote:
>>>>
>>>>> the text edit setting "smart dashes" may convert double hyphens to
>> dash,
>>>>> which is not what you want in this context.
>>>>>
>>>>> https://support.apple.com/kb/PH23628?locale=ja_JP&viewlocale=en_US
>>>>>
>>>>> a single hyphen must be used with a short option name (-f)
>>>>> a double hyphen must be used with a short option name (--force)
>>>>>
>>>>> -force is therefore an invalid instruction (single hyphen+long option
>>>>> name).
>>>>>
>>>>> I've posted a utility to ease the process of signing
>>>>>
>>>>> https://github.com/miyako/4d-utility-build-application
>>>>>
>>>>> it is written in v17 but the target app path can be any path.
>>>>>
>>>>> 2019/04/03 8:05、Pat Bensky via 4D_Tech <[hidden email]<mailto:
>>>>> [hidden email]>>のメール:
>>>>> —force: No such file or directory
>>>>>
>>>>>
>>>>> **********************************************************************
>>>>> 4D Internet Users Group (4D iNUG)
>>>>> Archive:  http://lists.4d.com/archives.html
>>>>> Options: https://lists.4d.com/mailman/options/4d_tech
>>>>> Unsub:  mailto:[hidden email]
>>>>> **********************************************************************
>>>>
>>>>
>>>>
>>>> --
>>>> *************************************************
>>>> CatBase - Top Dog in Data Publishing
>>>> tel: +44 (0) 207 118 7889
>>>> w: http://www.catbase.com
>>>> skype: pat.bensky
>>>> *************************************************
>>>>
>>>
>>>
>>> --
>>> *************************************************
>>> CatBase - Top Dog in Data Publishing
>>> tel: +44 (0) 207 118 7889
>>> w: http://www.catbase.com
>>> skype: pat.bensky
>>> *************************************************
>>> **********************************************************************
>>> 4D Internet Users Group (4D iNUG)
>>> Archive:  http://lists.4d.com/archives.html
>>> Options: https://lists.4d.com/mailman/options/4d_tech
>>> Unsub:  mailto:[hidden email]
>>> **********************************************************************
>>
>> **********************************************************************
>> 4D Internet Users Group (4D iNUG)
>> Archive:  http://lists.4d.com/archives.html
>> Options: https://lists.4d.com/mailman/options/4d_tech
>> Unsub:  mailto:[hidden email]
>> **********************************************************************
>
>
>
> --
> *************************************************
> CatBase - Top Dog in Data Publishing
> tel: +44 (0) 207 118 7889
> w: http://www.catbase.com
> skype: pat.bensky
> *************************************************
> **********************************************************************
> 4D Internet Users Group (4D iNUG)
> Archive:  http://lists.4d.com/archives.html
> Options: https://lists.4d.com/mailman/options/4d_tech
> Unsub:  mailto:[hidden email]
> **********************************************************************

**********************************************************************
4D Internet Users Group (4D iNUG)
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:[hidden email]
**********************************************************************