Strange behaivour when unpacking my app from a downloaded zip file

Mac OSX specific forum
User avatar
Piero
Addict
Addict
Posts: 923
Joined: Sat Apr 29, 2023 6:04 pm
Location: Italy

Re: Strange behaivour when unpacking my app from a downloaded zip file

Post by Piero »

mk-soft wrote: Sat Jan 20, 2024 4:24 pm I don't have a Mac M1/M2
Have you tried the code ... Without immediately messing with the parameters.
The problem is with unsigned ARM apps downloaded from web (even your own); there are ways to make them work without notarization; notarizing is painful and expensive
User avatar
Piero
Addict
Addict
Posts: 923
Joined: Sat Apr 29, 2023 6:04 pm
Location: Italy

Re: Strange behaivour when unpacking my app from a downloaded zip file

Post by Piero »

What a stupid mad Italian I am, mk: I was about to send you a link to download a DMG with an unsigned ARM app...
...but... you cannot run it!

To myself: Gesauger!
User avatar
mk-soft
Always Here
Always Here
Posts: 6245
Joined: Fri May 12, 2006 6:51 pm
Location: Germany

Re: Strange behaivour when unpacking my app from a downloaded zip file

Post by mk-soft »

For me it was not about the signature of a macOS APP, but the problem with the ZIP and the attributes.
A DMG is better for passing on (unsigned) APPs.
You don't have to sign up for a paid account with Apple Development to publish APPs in the Apple Store. For small apps you can also distribute them on your own web server. The user only has to allow them to start apps from other sources.
My Projects ThreadToGUI / OOP-BaseClass / EventDesigner V3
PB v3.30 / v5.75 - OS Mac Mini OSX 10.xx - VM Window Pro / Linux Ubuntu
Downloads on my Webspace / OneDrive
User avatar
Piero
Addict
Addict
Posts: 923
Joined: Sat Apr 29, 2023 6:04 pm
Location: Italy

Re: Strange behaivour when unpacking my app from a downloaded zip file

Post by Piero »

mk-soft wrote: Sat Jan 20, 2024 5:19 pm For me it was not about the signature of a macOS APP, but the problem with the ZIP and the attributes.
A DMG is better for passing on (unsigned) APPs.
You don't have to sign up for a paid account with Apple Development to publish APPs in the Apple Store. For small apps you can also distribute them on your own web server. The user only has to allow them to start apps from other sources.
Unfortunately, from what I saw you are very wrong... intel mac stuff doesn't have big problems; you just set sys prefs to "NOT only from appstore" and open them with ctrl-click/open... ARM stuff is "much more problematic" if not signed...
...we will soon need to notarize our PB code with our implanted microchip
Lebostein
Addict
Addict
Posts: 829
Joined: Fri Jun 11, 2004 7:07 am

Re: Strange behaivour when unpacking my app from a downloaded zip file

Post by Lebostein »

Thanks @all for information. What I have understood: The difference between the original App and the downloaded App are the extended attributes. The original App has no extended attributes. After unzipping a downloaded and unknown app, macOS adds two extended attributes to the app:

Code: Select all

xattr my.app
>> com.apple.provenance
>> com.apple.quarantine
"provenance" means "unknown source" and
"quarantine" means "app was not checked by Apple for malware"

These attributes prevent execution. They must be removed manually. In my tests it was completely irrelevant whether zip or dmg.

X64-Apps can be opened without command line (right click menu and press open with option⌥ button pressed). But Arm64-Apps are cannot be executed "by mouse". I couldn't do it without the command line (xattr -cr).
User avatar
Piero
Addict
Addict
Posts: 923
Joined: Sat Apr 29, 2023 6:04 pm
Location: Italy

Re: Strange behaivour when unpacking my app from a downloaded zip file

Post by Piero »

Lebostein wrote: Sun Jan 21, 2024 9:38 pm I couldn't do it without the command line (xattr -cr).
Did you try dropping the app on Terminal DOCK ICON ?
It asks me if I want to open an app downloaded from the net, I click OK, quit Terminal, and then I can run it!
I doubt that it always works... but out of curiosity, please let me know if it works for you
Bmld756
User
User
Posts: 30
Joined: Mon Sep 19, 2022 3:30 pm

Re: Strange behaivour when unpacking my app from a downloaded zip file

Post by Bmld756 »

Hello,

It is normal if your are not an Apple developper, so your App is not sign. On intel it is possible to force but not on M series. So I distribute a software for intel and M produce write with pure basic. To solve this pb when you download yours software, apply the next command line

xattr -d com.apple.quarantine /Applications/nameofthesoft.app

On my site, I explain it and you can test : download the software and apply this command line

http://bmaillard.free.fr/programmer/

Envoyer
IMAC 21.5 2012 Core I5 - 2.70 Ghz. 16 GB NVIDIA GeForce GT 640M 512 Mo. MacOs OCPL Sequoia 15.0
MacBook Air M1 - 8Go - Sonoma 14.1
Post Reply