[This is part 1 of an on-going saga. Check out part 2. Or part 3.]
So last night, Markus "Notch" Persson -- the Minecraft guy -- mentioned that Microsoft reached out to the company (Mojang AB) in an attempt to get the wildly popular Minecraft video game into the Windows Store. Shortly after, though, he denounced Microsoft for "ruining the PC" with Windows 8 and its "closed" nature. What's really going on here: Notch is just confused about Windows 8.
Allow me to help.
After Windows 8 hits the shelves, there will be two classes of applications that run on the PC:
- Desktop Apps
- Windows Store Apps (previously Metro Apps)
(There are also Desktop Device Apps but lets ignore those.) Desktop apps are the applications we use today. Photoshop. Visual Studio. Office. Each application has its own experience which, at times, can be difficult to use or even master. Take Minecraft for example -- it had a "textbox" for specifying the hostname or IP address of a server to connect to. But it wasn't until recently that users could paste text into this textbox from the clipboard. Users expected it to work, but it didn't.
Cue Windows Store Apps. These are newer PC apps that are held to a strict code to ensure users are provided a consistent, elegant, and easy-to-use experience. These apps come from one place -- the Windows Store -- with dependencies quietly in tow and out of sight. You can say, in most cases, they Just Work. (For more insight on this vision, be sure to check out Steven Sinofsky's write up on the Building 8 blog.)
Both app types are supported in the Windows Store. Windows Store Apps obviously get preferential treatment -- that is, they are submitted to and hosted by Microsoft, tie into bug reporting and analysis tools, support in-app purchase, etc. Desktop apps are left to continue doing what they do today but can benefit from a listing in the Windows Store. (More details on how desktop apps look and behave in the store can be found on the Windows Store blog.) [Added 9/28/2012 @ 8:55PM PST]
Like the classified ads in your local newspaper, listing your app in the Windows Store isn't free. Justifying those fees, however, is access to Windows users across 120 markets -- that is, nearly anyone on this planet using Windows. Crazy, right?
And one other thing: Your application must follow some rules to ensure nothing goes awry on the user's machine. These rules differ based on what kind of app you're submitting and unsurprisingly require one of two certifications: Windows Store App Certification or Desktop App Certification.
Let's return to the tweet situation for a moment.
I contacted Microsoft about the ordeal and they confirmed reaching out to Notch. But Microsoft did not ask for the guys to rework Minecraft into a Windows Store App or participate in any walled app gardens. (Though it's noteworthy that Mojang AB is not unfamiliar with playing in these spaces. After all, they have Xbox 360, iOS, and Android versions of Minecraft in some form on the market today.) Microsoft was simply offering assistance in pushing Minecraft through the Desktop App Certification process.
Let's dissect that process now.
The Desktop App Certification process isn't new. Back in the days, it was called the Windows Software Logo Program -- you know, that program that Microsoft tried to nudge developers to participate in to no avail. Generally speaking, it's a document filled with best practices-turned-requirements that if implemented net you a spot in the Windows Store. A fair deal, I think.
But you can't implement and submit your app to the Windows Store blind. Microsoft conveniently provides a set of tools to mock certify your application, eliminating most of the guess work associated with submitting your application to the Windows Store. They run the same tests over there.
I took Minecraft and ran it through these tests myself, to see what passed and what failed. While I passed my mock certification, I did so with some warnings that would very likely result in rejection or at the very least raise some eyebrows. (I suspect they are labeled as warnings because waivers could work around them if needed.)
Here's what I got dinged on:
Windows Security Features Test
Microsoft is constantly evolving the security landscape of Windows operating system, developing and improving protection against coding mistakes that lead to scary-sounding issues, like buffer overflows. Enabling these features once required app developers to opt-in to the protection. Not anymore. To play ball, you need to get with the program and ensure you compile your app with the following security features enabled:
Details: Minecraft.exe currently fails this test (with a warning). While I can't be certain, it appears Mojang AB cross-compiles Minecraft.exe for Windows via gcc. Or perhaps they use a mingw/cygwin/vc++ compiler environment. Let's hope for the latter because gcc doesn't support some of these features. A switch to the Windows SDK or Visual Studio 2012 Express for Windows Desktop software is likely in order.
User Account Control (UAC) Test
UAC is a set of complicated security technologies that debuted in Windows Vista. Short version: Your application is reduced to having little to no privileges by default, requiring "elevation" or hoop jumping by authorized users to gain access to sensitive bits of Windows. They relaxed it a bit in Windows 7, to the point where it's now a Good Thing. (You can read all about it on MSDN.) This particular test just inspects the app for a little XML file called the Application Manifest. It describes to the OS what the app needs in terms of permissions, dependencies, etc.
Details: Minecraft.exe fails this test (with a warning). This is trivial to fix -- embed a tiny Application Manifest that simply indicates that it needs no special access and can run safely in the user's sandbox. (i.e. add requestedExecutionLevel level=asInvoker)
Digitally Signed File Test
This one is simple. Code should be digitally signed to confirm where it came from and to ensure its intact when the user receives it.
Details: Minecraft.exe fails this test (with a warning). It isn't digitally code signed. (Now, there's no requirement that Mojang AB actually "check" this signature, so modders fear not.)
Install To Program Files Test
For application storage consistency and security, Microsoft requires apps be installed to the trusty ol' Program Files folder.
Details: I put together a quick, NSIS-based per-user installer for Minecraft.exe. Per-user installers typically install apps for use by a single user so naturally they cannot be installed to Program Files. I chose per-user in the certification tool but Minecraft still failed this test (with a warning). It appears I hit a certification bug but I'm waiting for Microsoft to get back to me on this one.
... and, that's it. Minecraft passed every other test.
If Mojang AB needs a hand, feel free to email me. I'd be delighted to help.
Rev 1: Added a clarifying paragraph on how Windows Store/Desktop apps get hosted in the Windows Store. It has been time-stamped with gray text accordingly.