13 ms·
Distributing Mac apps outside the App Store, a quick start guide
- sthnblllII 6y agoIf Apple has to sign your app for it to run, then the Mac is no longer hackable.
- gh123man 6y agoHow do you define hackable? Also it is trivial to run unsigned code on a mac. Signed binaries are a totally reasonable security feature for computers sold to people that will install anything. Having a reasonable (hard enough to find) workaround is totally acceptable in my book. I also believe you can trust a self signed codesigning certificate if you want a more permanent solution (citation needed)
- jrumbut 6y agoI think part of why the signed apps system feels onerous to me is that I can't really trust it for the things that matter most. Even if I'm assuming no exploits, everything working as intended, the permissions don't map well to what I care about. I don't really care which app has access to the camera, I care about what gets done with the recording (or even metadata/inferences from the images) or about it taking pictures at surprising times. Some fitness tracker needs a lot of data, which is fine as long as they aren't selling it to third parties. I would love the feature if it was something I could rely on, with audits of the client code, backend infrastructure, transparency in regards to data use, etc. As is installing software is still caveat emptor.
- samatman 6y agoCapabilities are a technical problem with a technical solution. As in: an app can't use the microphone or access the Downloads folder without getting permission from the user, by design. What you're after is a sociopolitical problem, and would take a sociopolitical solution. It simply can't be implemented in software, and it can't be implemented correctly in all cases, period: even if the app designer is a perfect angel, and only does exactly what they've pledged to with your data, the company could be bought by Evil Corp, or get hacked.
- Wowfunhappy 6y agoI totally agree with you, but it's worth noting that what you're describing is TCC (permissions for camera, accessing certain folders, etc), which is somewhat orthogonal to code signing. It's also much harder (practically impossible in many cases) to actually disable than Gatekeeper if you don't like it.
- sthnblllII 6y agoHackable means I can run any software I want from any source without anyone's permission. My understanding (please correct me if I'm wrong) is that starting with M1 macs, I now need apple's permission to distribute an app whether I use their store or not. Richard Stallman is seeming more and more prescient every year. Users should not be forced to give up control like this.
- Wowfunhappy 6y agoBut they don't. Go into the Terminal and type sudo spctl --master-disable (I have that command memorized!) and you can run all the unsigned code you want.
- ogre_codes 6y agoApple only has to sign your app if you want to distribute it. You can run apps you build without getting them signed. You can build local apps, run Python/ Ruby/ Elixir code on your own computer without Apple ever knowing. Likewise on the iPhone actually, though I have to build the software on the Mac.
- mhh__ 6y ago> distribute it Hardly a saving grace, no? Apple are still judge, jury, executioner, and taxman as to what the vast majority of their customers can run with their already expensive hardware.
- ogre_codes 6y ago> Apple are still judge, jury, executioner, and taxman Does that mean Tim Cook is Judge Dredd? The reality of distributing Mac Software is far more boring than you paint it.
- GeekyBear 6y agoSo Windows 10 isn't hackable now that Windows SmartScreen hides the option to run unsigned software installers?
- rubyist5eva 6y agoNot everyone wants a "hackable" machine - but for those that do, it's rather trivial to bypass the mechanisms.
- rootsudo 6y agoI never knew this was so much to write about. Whatever happened to the days of having an apache web server, having it in a zip, and just hosting it? If it's small enough, personal S3 bucket? If paranoid, post the SHA1/MD5 hash. I guess signing the app too.
- gh123man 6y agoAgreed. I worked for (very large company) distributing a mac app outside the app store. Other than the distribution + update benefits (and a couple entitlements) you get from the app store, the freedom you get by living outside the sandbox outweighs it IMO.
- jolux 6y agoIt's not much more complicated than just sticking it in an S3 bucket. This article seems to be more about the broader implications for your business about choosing one route vs the other. Guilherme mentions that GitHub Releases work fine for open source apps.
- jws 6y ago“Transmission”, a popular Mac bit torrent client did it the simple way. They ended up distributing a disk destroying malware to their users. If you only distribute your Mac software outside the store, and aren’t inherently ineligible for the store (like a full disk space measuring program) I just assume you are up to no good or don’t care enough about my security and pass on your product. If you aren’t willing to fork over $100/year to at least minimally tie an identity to your actions and go through all the signing nuisance then you don’t get control of my computer. Now that we are living in a notarized application world I may have to rethink this and loosen up, so the nuisance you go through notarizing your app is in some sense the entry fee to sell to some security conscious customers.
- deleted 6y ago[deleted]
- kranner 6y agoThe $100 fee is not the issue. You also give up 15% or 30% of revenue to Apple; have to go through app review on every update facing arbitrary rejection; have no direct relationship with your users; can't offer upgrade pricing on significant new releases (existing users either get the new release for free or you make it a new SKU thus forcing everyone to pay full price, including existing users).
- jaimex2 6y agoIt still puzzles me to this day why developers are happy to develop for Apple products. If the red tape alone doesn't make it a deal breaker the % cut certainly should.
- random5634 6y agoBecause apple provides a tradeoff - a VERY trusted ecosystem that folks are happy to spend big money in knowing they are pretty safe (no impossible to cancel subscriptions). The ecosystem as well is pretty aggressively updated - even old devices (by most company standards) remain supported AND updated - so your development target is not terrible. So in short - you can make good to great money on the apple ecosystem as revenue per install is higher and ecosystem support costs lower.
- PurpleFoxy 6y ago3rd parties kind of shot themselves in the foot by abusing the fuck out of users in every way possible and now things have swung in the other direction where users all flock to marketplaces that prevent the abuse even if sellers get charged a huge fee.
- oefrha 6y agoYes. On the one hand, having NE entitlements restricted to MAS and the associated pain of MAS distribution is real. On the other hand, a few years ago, I once installed some garbage corporate VPN software on a Windows machine of mine so that a family member could connect to their office to resolve an urgent matter. I later realized it was impossible to uninstall. It seemed to have somehow managed to embed itself deep into the network stack initiation process, and since you can’t delete an open file on Windows, it was impossible to remove. I booted into the Windows equivalent of recovery mode and forcefully removed the files from a DOS prompt, but then the whole network stack was borked. Not knowing which registry keys to edit I had to reinstall the damn OS. With that experience in mind, I’d really appreciate the peace of mind of knowing deeply system-altering software can be cleanly removed.
- 6y ago
- adamnemecek 6y agoI'm surprised there isn't a startup solving this. Cross-platform Sparkle for updates (probably written in Rust), payment processing, DRM. Maybe even some sort of App Store-like thing for discoverability. I'm also kinda surprised how desktop app development is not not quite as "hip" as mobile. I'm guessing it's due to the relatively difficulty compared with mobile.
- deleted 6y ago[deleted]
- qppo 6y agoWhy ship a desktop app when you can ship a browser product? The business incentives often outweigh the technical benefits of desktop apps. DRM and payment processing are easy. Discoverability is a shit show but the only competitive advantage to app stores is exclusivity. No need to worry about provisioning user machines, DLL hell, whatever. And whatever you do you're going to pay a couple of release engineers anyway.
- adamnemecek 6y agoMaybe you are building something performance sensitive. DLL hell isn’t a problem. You can just ship a stand-alone binary if you want.
- novok 6y agoFigma has shown if you want perf, you write it in C++ and distribute as web assembly and still stay in the browser.
- astlouis44 6y agoCould not agree more, and my bold prediction is that we will see a major migration of desktop apps that run on WASM at near native performance. The benefit of being in the browser is clear to both developers and end users, especially if the performance gap isn't big. What's really exciting to me is the disruption of incumbents in various industries, the only real one we've seen so far is Figma's webapp eating away market share of Sketch/Adobe's native clients.
- mesh 6y agoI dont mind Apple putting more restrictions around signing, but they make it SO onerous for Desktop users to explicitly allow unsigned apps. Tell me its unsigned and the dangers, but then give me the option to run it. Stop treating me like some dolt. Right now, you have to really jump through hoops: https://github.com/mikechambers/dcli/wiki/Running-dcli-tools-on-Mac-OS-X https://github.com/mikechambers/dcli/wiki/Running-dcli-tools... (this is for a open source project I run)
- ogre_codes 6y agoI'm not sure why, but I don't see many of these prompts myself. You can disable Gatekeeper. sudo spctl --master-disable That should get rid of the prompts.
- asiando 6y agoI’d rather not. After the initial setup I don’t see that many annoying prompts either, I’d rather not disable security measures when they’re really not that painful.
- ogre_codes 6y agoI don't have it disabled myself. But if it's a burden, the option is there.
- GeekyBear 6y ago> they make it SO onerous for Desktop users to explicitly allow unsigned apps Not really onerous. However, you do have to use a terminal command to turn off Gatekeeper. https://www.imore.com/how-open-apps-anywhere-macos-catalina-and-mojave https://www.imore.com/how-open-apps-anywhere-macos-catalina-...
- webmobdev 6y agoHe means from the perspective of an app developer - it is hard to educate users when Apple's deliberate UI scares the user. Asking some some of them to disable Gatekeeper can also backfire with ignorant users, because it is a security measure against malware spread and execution (once malware is identified).
- doomlaser 6y agoI distribute a Mac app outside the app store. In my case, it's a freeware tool to hide the cursor with a hotkey or idle timer: http://doomlaser.com/cursorcerer-hide-your-cursor-at-will/ http://doomlaser.com/cursorcerer-hide-your-cursor-at-will/ Architecturally, it's two "apps", a System Preference pane and a daemon that actually does the hiding. There's a new dance in the last year or so where you must notarize your app before distribution. This is a bit more involved than just code signing, but it's workable. If you codesign and notarize your app, it's still possible for everyday users to download and launch without too much trouble.
- sneak 6y agoUnless you need the NetworkExtension API to be a vpn; Apple only notarizes those in the App Store. This is why you can't download WireGuard from the WireGuard website - only from the App Store after providing ID (email and phone are the minimum required to get an Apple ID, required even for free apps). It's not as easy as simply notarizing via the dev program and then self-publishing; some APIs are totally off-limits outside of the App Store.
- xvector 6y agoHow does Mullvad do it, then? Their Mac app is downloaded directly from their website, and WireGuard is used for their VPN.
- aequitas 6y agoI think Mullvad doesn't use the NetworkExtension API but relies on tun/tap. WireGuard used to do this in the past. But if you want to run a VPN on iOS devices you need to implement via NE anyways, so I believe the development was streamlined and the macOS version was build using NE as well. Afaik you can still install WireGuard via Homebrew: https://www.wireguard.com/install/#macos-homebrew-and-macports-basic-cli-homebrew-userspace-go-homebrew-tools-macports-userspace-go-macports-tools https://www.wireguard.com/install/#macos-homebrew-and-macpor...
- sneak 6y ago
- CommieDetector 6y agoSound like something only a Trump supporter would do.... #cancelrambo
- The_Colonel 6y agoI'm building my app for all platforms (Win, Lin, Mac) on a Linux machine, so I don't (can't) sign or notarize. It's been going OK so far, but it seems like screws are tightening and when this workflow doesn't work anymore, I will simply stop supporting Mac (this applies to M1 too).
- steeleduncan 6y agoHow are you building a macOS app from linux? Is there some equivalent of mingw?
- patrickg 6y agoThere is osxcross: https://github.com/tpoechtrager/osxcross https://github.com/tpoechtrager/osxcross
- The_Colonel 6y agoMy app is based on electron and electron-builder can do Mac x86 builds on linux.
- elliottkember 6y agoGitHub Actions has OSX runners. I’m building an Electron app too and my builds run in Actions. Electron even has arm64 builds now. It works great
- The_Colonel 6y agoInteresting, I need to look into it. ARM64 is nice too, but for me not applicable. I won't dare to produce builds which I can't test ...
- elliottkember 6y agoI can understand that. Intel builds run just fine. But once you try the ARM64 build, it really flies and you can’t go back.
- ChrisMarshallNY 6y agoThis is a great guide! My own preference is to try using the Mac App Store, if possible. One reason, is that I’m lazy, and most of my stuff is free, or first-tier priced. I’m not too concerned about Apple’s cut. Another reason is that it is another level of QA for my app. Sort of a “peer review.” I’m fairly obsessed with Quality. But it’s not something that has ever been a “big deal” for me, so the stakes have not been too high.
- _qulr 6y ago> Another reason is that it is another level of QA for my app. Sort of a “peer review.” I’m fairly obsessed with Quality. In my experience, don't expect much from App Store reviewers. Their primary concern seems to be simply protecting Apple's own intellectual property. If you want testing, distribute your app to beta testers.
- ChrisMarshallNY 6y agoNot to worry. I would never rely on it. But what they are good for, is some basic usability, and "Apple user expect this" kind of things.
- rho4 6y agoJust this month we moved the installer creation step of our build pipeline to an on-premise mac mini in order to let install4j handle the signing & notarization (for windows, linux and mac).
- oneweekwonder 6y agoThe article recommends create-dmg to create a disk image, but it depends on node/npm. A python alternative would be: dmgbuild[0] [0]: https://github.com/al45tair/dmgbuild https://github.com/al45tair/dmgbuild
- fartcannon 6y agoYou know what you can run whatever you want on? Linux and a myriad of other open OSes. Just stop using Macs/Windows. You can have it better. You deserve to be treated with respect.
- lostgame 6y ago>> Just stop using Macs/Windows. You can have it better. Someone is privileged / in a bubble enough to think this is even remotely plausible for a massive chunk of people. When native Photoshop, Final Cut Pro, Logic Pro X, hell; even Unity makes it to Linux, I’ll be able to consider it. Until then, I make my money off those apps. How is not having access to the vast wealth of commercial software ‘having it better’? Even for just the average person? It’s not. Plain and simple. Can we finally just drop this ‘just go to Linux’ shit? It really only works for Grandma or Mom who only needs to check their emails, Facebook and type documents, and programmers who happen to be lucky enough to have that extremely limited set of tools work for them. Until solutions like WINE are no longer required and commercial software is available it is and will remain a non option for the vast, vast majority of professionals using a computer. No offence intended - but seriously every time someone posts ‘everyone should just move to Linux it’s so much better’, I have to ask myself how isolated in that community they made themselves to make that ‘realistic’.
- deleted 6y ago[deleted]
- swebs 6y agoUnity is available for Linux. The beta has been available sincle like 2015, but UnityHub for Linux is an official release nowadays.
- triceratop 6y agoI wish articles like this were around when I built my crypto trader mac app. I agree with others here that codesigning is a pain. One thing -- I don't really think adding licensing/copy protection is that hard and I personally think it is beneficial. I use a SaaS to hadnle the backend of that. It's been awhile but I remember it being pretty painless to integrate a simple licesning setup where my users activate devices up to their maximum according to their license key's tier.
- vkaku 6y agoWe need these writeups for iOS as well. Distribute IPA files without a problem!
- TYPE_FASTER 6y agoFWIW, Microsoft's Visual Studio App Center will build and distribute iOS apps: https://visualstudio.microsoft.com/app-center https://visualstudio.microsoft.com/app-center.