Installing a BlitzMax App on user MAC

Started by Midimaster, July 02, 2021, 13:47:17

Previous topic - Next topic

Midimaster

Maybe this helps somebody....

If you build a App on BlitzMAX for MAc OsX BigSur and you are not listed as a registered Developer (99,oo$) your app will not start on the user's computer.

But there is a trick:

After downloading your app the user will find it in his DOWNLOAD folder.

Now hold down CRTL-Key and click on the app.
A dialog will appear.
Now hold down again the CRTL-Key and click at OPEN
Another dialog will appear
Now click at OPEN

This will open the app and change it's state from "unknown" to "secure".
This means that from now on the app can be started normal as any other app on the mac.
...back from Egypt

Midimaster

I only have 2 users with new MACs who report problems in starting one of my apps. One is a female teacher without much computer skills, one is a 85 year old man. I build an update of the app for them and it runs perfect on my new MAC.

I asked both to test this new version.

But now the female teacher still reports, that the app gives an error report. Something like (translated) "Upps ...this file not longer exists...".  I'm a little helpless because my version runs perfect. Now I would like to hear a second opinion from somebody with more skills.

Can somebody of the community please make a short test with the app? You only have to download the app and follow the procedure in post #1. Then the app starts. Answer the licence question with "Cancel" and then wait 2-3 seconds until you can click on "Continue". That's all. Does the app crash now? Deeper tests are not necessary for the moment.

It needs to be a MAC from 2018 and later. Here is the download file (5MB):
http://www.midimaster.de/download/AurisOsxBigSur.zip


...back from Egypt

MikeHart

Why does the machine has to be from 2018 and later?

Midimaster

It has to be a "64bit-only"-MAC. because only users of this models report problems. Of course you can also test it on older version if you like.
...back from Egypt

Midimaster

#4
Now a user with a 2020 MAC reports, that my way descriped in post #1 does not work on his computer.

My workaround was:

  • download the app

  • open in  finder:"downloads"

  • hold CTRL then click the app once

  • hold CTRL again, then click open
Now on my MAC (2018) appears a menu where I have three options. One of them is "Open". When I select this the app is accepted forever.

The user reports that on his MAC (2020) in this last step he only has two options: "Cancel" and "Move-To-Bin".

Can somebody with a MAC younger than 2019 please verifiy and confirm this behavior? I cannot believe it!


#UPDATE#

Now I found a hack for enabling all software from all sources:

1. You open the app TERMINAL in your MAC

2. Then you enter:

sudo spctl --master-disable

3. Then you press ENTER

4. Then you enter your password (characters will not be repeated in the console)

5. Then you press ENTER


Now will have three entries in the security settings of your MAC

QuoteAlow apps downloaded from:
- App Store
- App Store and identified developers
- Anywhere


From now on you can switch between these three options depending on the software you want to install
...back from Egypt

Qube

Wow, that's pretty excessive to ask users to do that :o - Its like saying "Here is my app but you'll have to disable its security so anything can run"

It's pretty simple to open your none signed app :

Hold down the option key > right mouse click on the app > select Open from the context menu and then select Open again the popup window. The app will then be marked as OK to open on your Mac.

Do NOT advise your customers to unknowingly disable their Mac's security.

Mac Studio M1 Max ( 10 core CPU - 24 core GPU ), 32GB LPDDR5, 512GB SSD,
Beelink SER7 Mini Gaming PC, Ryzen 7 7840HS 8-Core 16-Thread 5.1GHz Processor, 32G DDR5 RAM 1T PCIe 4.0 SSD
MSI MEG 342C 34" QD-OLED Monitor

Until the next time.

Midimaster

QuoteHold down the option key > right mouse click on the app > select Open from the context menu and then select Open again the popup window. The app will then be marked as OK to open on your Mac.

Tested on MAc 2020?
...back from Egypt

Steve Elliott

#7
Quote
Do NOT advise your customers to unknowingly disable their Mac's security.

Quite right.

Quote
Tested on MAc 2020?

Something to be suggested, if it works or not is irrelevant because disabling your customer's security is a bad idea and could get you in trouble if the user gets hacked.

Pay and make an official build.
Win11 64Gb 12th Gen Intel i9 12900K 3.2Ghz Nvidia RTX 3070Ti 8Gb
Win11 16Gb 12th Gen Intel i5 12450H 2Ghz Nvidia RTX 2050 8Gb
Win11  Pro 8Gb Celeron Intel UHD Graphics 600
Win10/Linux Mint 16Gb 4th Gen Intel i5 4570 3.2GHz, Nvidia GeForce GTX 1050 2Gb
macOS 32Gb Apple M2Max
pi5 8Gb
Spectrum Next 2Mb

iWasAdam


Qube

Quote from: Midimaster on July 04, 2021, 09:07:58
Tested on MAc 2020?
Tested on : Mac mini 2012 / Mac mini 2018/2020 ( intel ) and Mac mini 2020 ( M1 ) - It doesn't matter the model but the OS version since Apple increased the system security.

Doing the "Hold down the option key > right mouse click on the app > select Open from the context menu and then select Open again in the popup window." is the correct method a user has so should they want to open that app they can at their own risk. Sometimes you may need to use the "xattr -cr /path/to/application.app" command if an app reports it's damaged but you know it isn't.

Regardless, never ever ask a user to disable system security and put THEIR system at risk. Instead provide an instructions text file detailing what they can do to run YOUR app and why they need to do that and then it's THEIR choice if they want to go ahead.
Mac Studio M1 Max ( 10 core CPU - 24 core GPU ), 32GB LPDDR5, 512GB SSD,
Beelink SER7 Mini Gaming PC, Ryzen 7 7840HS 8-Core 16-Thread 5.1GHz Processor, 32G DDR5 RAM 1T PCIe 4.0 SSD
MSI MEG 342C 34" QD-OLED Monitor

Until the next time.

Midimaster

At the Hotline I first suggested exact what Qube writes:
Quote...Doing the "Hold down the option key > right mouse click on the app > select Open from the context menu and then select Open again in the popup window." is the correct method a user has...

But the users reported, that this does not work. So I did some resarch on Apple's support pages. And there is a new approach:
download the app
1. open in  finder:"downloads"
2. hold CTRL then click the app once
3. hold CTRL again, then click open

It looks like instead of OPTION KEY now Apple now uses CTRL KEY for this:

Apple Support:
https://support.apple.com/en-us/HT202491
Quote...  If you're prompted to open the app in Finder and you're sure you want to open it despite the warning, you can control-click the app, choose Open from the menu, and then click Open in the dialog that appears. Enter your admin name and password to open the app. 

This worked on my 2018 MAC MINI, but I needed an additional setting in the security settings: Change...
"allow downloads from app store"
...to...
"allow downloads from appstore and identiefied developers"

With this approach I had a new phone call with the user. We tried 1 hour together, but had no change to start the app on his computer.

Then I found the new support text with the "sudo..." hack , which enables to add a third feature "open from Anywhere" to the security menu. This DOES NOT mean remove all the security features but enables users to switch for a short moment to this option then start the app once, then close the feature immediately again back to "allow downloads from app store". This third option was standard on all mac Osx until 2014 and it is still  Part of the OsX, but not visible.

QUBE's Test on MAC 2020

For me it sounds strange that QUBE was able to start my app...
http://www.midimaster.de/download/AurisOsxBigSur.zip
... with the old approach on a MAC 2020. So thank you for reporting me this. I will continue investigating, why this does not work on our MACs. Are there different MAC's?

Did somebody else try to start my app on a new MAC. help is still welcome!!!



...back from Egypt

Qube

It is the control key and not the option key. Hold Control > Right mouse click > Select Open
Mac Studio M1 Max ( 10 core CPU - 24 core GPU ), 32GB LPDDR5, 512GB SSD,
Beelink SER7 Mini Gaming PC, Ryzen 7 7840HS 8-Core 16-Thread 5.1GHz Processor, 32G DDR5 RAM 1T PCIe 4.0 SSD
MSI MEG 342C 34" QD-OLED Monitor

Until the next time.

Steve Elliott

No it's the 'Command' Key and right click open.  But the app does not function correctly, the background window flashes multi-coloured garbage, there's a menu that takes user information and doesn't seem to progress and a small menu that doesn't function either...But I was able to run it easily without turning off security globally.

I have a 2017 MacBook Pro.
Win11 64Gb 12th Gen Intel i9 12900K 3.2Ghz Nvidia RTX 3070Ti 8Gb
Win11 16Gb 12th Gen Intel i5 12450H 2Ghz Nvidia RTX 2050 8Gb
Win11  Pro 8Gb Celeron Intel UHD Graphics 600
Win10/Linux Mint 16Gb 4th Gen Intel i5 4570 3.2GHz, Nvidia GeForce GTX 1050 2Gb
macOS 32Gb Apple M2Max
pi5 8Gb
Spectrum Next 2Mb

Midimaster

#13
Quote from: Steve Elliott on July 05, 2021, 11:01:51
..  But the app does not function correctly, the background window flashes multi-coloured garbage, there's a menu that takes user information and doesn't seem to progress and a small menu that doesn't function either...But I was able to run it easily without turning off security globally. I have a 2017 MacBook Pro....

Thank you for this detailed report. I did convert the old code to BlitzMax NG and then transfered it to a MAC MINI 2018 with OsX BigSur (11.4) with an XCode 12.5.1. I did no changes at security* and created no security exceptions for AURIS on this MAC. Here I compiled it with BlitzMax NG and it runs perfect on my machine.

*)What do you exactly mean with "...turning off security globally..."?

Do you have any ideas, what could be the reason for the bugs?


Quote...there's a menu that takes user information and doesn't seem to progress....
this should enable to enter the licence key, but it should have a "Cancel"-button to continue without key.
...back from Egypt

Steve Elliott

Quote
*)What do you exactly mean with "...turning off security globally..."?

You seemed to be suggesting a hack to get your app to run, followed by Qube, Adam and myself telling you not to suggest this to users.  Just press the command key, right click on the warning and press open is all that is required.

Quote
Do you have any ideas, what could be the reason for the bugs?

Quote
I did convert the old code to BlitzMax NG.

Maybe that?  Perhaps the NG guys could point out possible differences you are not aware of.
Win11 64Gb 12th Gen Intel i9 12900K 3.2Ghz Nvidia RTX 3070Ti 8Gb
Win11 16Gb 12th Gen Intel i5 12450H 2Ghz Nvidia RTX 2050 8Gb
Win11  Pro 8Gb Celeron Intel UHD Graphics 600
Win10/Linux Mint 16Gb 4th Gen Intel i5 4570 3.2GHz, Nvidia GeForce GTX 1050 2Gb
macOS 32Gb Apple M2Max
pi5 8Gb
Spectrum Next 2Mb