Categories & Tags
Archive

Unity iPhone App Store Submissions – Problem Solved

November 14, 2009 in Demos, Tutorials and Tips by

Recently some Unity customers who have been very anxious to get their game approved by Apple for listing in the app store have received a disappointing rejection notice by Apple because they use something that was not approved by the Apple rules.
As it turns out, the Unity iPhone application was accessing those non-public functions through the Mono runtime which is a third party piece of code we use. Therefore, some of our customers had the bad experience of seeing their application be rejected.
We have been working on hard on this issue as it stalls and affects our iPhone developer customers. We were able to correct the issue just 2 days after we first heard about it and delivered that fix to those that had reported the problem. Many of them have already resubmitted their application to Apple.
We will be releasing this new version, Unity iPhone 1.5.1, sometime next week. In the meantime, you have a need or concern, please contact support@unity3d.com and request an iPhone build with this issue fixed.
Note that Unity games already on the app store are not affected by this.

Recently, some Unity customers who have been very anxious to get their iPhone game approved by Apple, have received a rejection notice because they use something that was no longer approved by the Apple rules.

We have been working hard on this issue as it stalls and affects our iPhone developer customers. We were able to correct the issue 2 days after we first heard about it and delivered that fix to those who had reported the problem. Many of them have been already resubmitted their application to Apple. The first Unity game to completely pass the App Store Submission Process is “Star Wars: Trench Run”.

We will be releasing this new version, Unity iPhone 1.5.1, publicly on our website sometime next week. In the meantime, if you have an urgent need or concern, please contact oleg@unity3d.com and request an iPhone build with this issue fixed.

Note that Unity games already on the app store are not affected by this.

For those who are interested here are the technical details:

The reason why Unity authored games (amongst other applications) have been rejected is that Apple recently has begun using special tools to check against usage of private APIs. The main reason for restricting private API usage is to avoid problems with applications breaking when Apple releases new versions of the iPhone OS. Unity iPhone 1.5.0 is accessing 2 private functions _NSGetEnviron and exc_server from the .NET runtime Mono.
There has been a lot of confusion about this topic recently. So to be 100% clear, there is zero relation between those 2 private functions and harvesting user information. Harvesting of user information can be done with a public API. The 2 private functions used in Unity, can not be used for this purpose. Neither do we know of any Unity games that performed any kind of harvesting of user information like phone numbers.
So why did we access those 2 private functions? First of all, Mono runtime was ported from OS X where those functions are very commonly used. Actually they have been used for years now. And as those functions didn’t give us any problems during Unity port to the iPhone, we simply continued to use them.

What do those functions actually do?

_NSGetEnviron is used by the Mono runtime to provide an implementation of the .NET core API method: Environment.GetEnvironmentVariable(). On UNIX environment variables are often used to pass arguments to applications. Due to how the function is exposed, it does not let developers do any data collection.

exc_server is used by the Mono runtime to provide graceful NULL reference exception handling. This is useful for developers, when they dereference a null pointer, we can avoid a crash and instead throw an exception and continue the game.

While those functions are useful for debugging purposes, Apple now rejects Apps that use them.

In order for us to solve this problem we simply removed any calls to _NSGetEnviron and exc_server. Update Unity iPhone 1.5.1 was sent out to developers days ago. Most of them have already resubmitted their Apps to the AppStore with the functions removed. Unity iPhone 1.5.1 will go live this week. The first Unity game to completely pass the App Store Submission Process is “Star Wars: Trench Run”.

Share this post

Comments (19)

Comments are closed.

14 Nov 2009, 4:42 am

Thanks guys for all of the work that you put in to keep us shining! It’s very appreciated. Unity FTW!

Minevr
14 Nov 2009, 4:42 am

Hateful apple

14 Nov 2009, 6:18 am

Why the “hateful Apple” comment? Apple was responding to an issue with another game using private variables/api to harvest user information (of something like that). All apple did was enforce the already existing rule more strictly. Kudos to UT for responding so quickly. :)

gamedev1
14 Nov 2009, 6:01 pm

I have tested a new release 1.5.1f2 on my large project and everything worked just great. Not even a single issue, great job guys.

Why the “hateful Apple” comment?

Because it has nothing to do with harvesting user information. You can request a user phone number programmatically even using exposed public SDK API.
That is right there is a hole here, but Apple should be responsible for that and try to fix it on system level introducing something similar to UAC.

What does it mean enforce existing rule more strictly? Wait a second, you know, the rule exists or it doesn’t. The fact they approved a bunch of applications calling private API means they not doing a good job there either.

And c’mon how harmful is the exc_server function? It is responsible for exceptions handling and it should be exposed in an SDK in the first place.

Ashkan
15 Nov 2009, 5:19 pm

how about fixing unity 2.6.
it has many bugs in editor that were not available on 2.5 and web player still has input problems and sometimes send key presses to the game for no reason

i know you will fix it soon guys but talk about that on the blog too

Thank you great unity guys

Graham
16 Nov 2009, 2:05 pm

@ashkan

We are working on 2.6.1.

16 Nov 2009, 7:06 pm

“Hateful apple” is a joke~~~ LoL….

Daniel Wind
16 Nov 2009, 8:07 pm

Thanks guys for looking into this so quick

Dwair
17 Nov 2009, 12:34 pm

Ouch! I sent an update to the app store on 14th, and did al the PR and marketing thing…half of the world will hate me for sure…

Well, time to get the patch, then ;P

Craig Mirkan
19 Nov 2009, 8:06 am

I’m surprised you were making use of exc_server — none of the headers required for implementing your own forwarding exception server are available in the SDK, but you can do implicit NULL checks just fine by trapping the equivalent BSD signals.

lesfundi
20 Nov 2009, 5:02 am

when will unity iphone 1.5.1 be out?

Renaldas Zioma
20 Nov 2009, 11:52 pm

Unity iPhone 1.5.1 is out already: http://unity3d.com/unity/whats-new/iphone-1.5.1

4 Aug 2010, 5:14 am

Private API use, there goes Apple trying to play Microsoft again

29 Aug 2011, 6:59 am

what do you think when does the new iphone out?

4 Sep 2011, 5:20 pm

Thx for this great work guys. I’m happy

11 Sep 2011, 11:18 am

Hey there, You have done a great job. I’ll definitely digg it and personally recommend to my friends. I am confident they will be benefited from this site.

12 Sep 2011, 3:45 pm

thank you for the info

29 Sep 2011, 10:44 am

Safes, yes Safes, or german “Tresor | Wertschutzschrank”

8 Oct 2011, 3:38 am

Danke, Thanks for the post. But after the 5.10.11… . we will see

Leave a Reply

Comments are closed.