Search Unity

IOS Advertising Identifier rejection

Discussion in 'iOS and tvOS' started by intoscienceDing, Feb 3, 2014.

  1. intoscienceDing

    intoscienceDing

    Joined:
    Nov 29, 2012
    Posts:
    10
    Hi all,

    Our app just being rejected this morning because of this:

    The policy has been there since june 2013 but seems enforced rencently, as after we did some research online, this issue seems starting affect people from last week.

    We wonder if anyone here has the similar issue recently and which Unity version are you using?

    Our environment: Unity 4.2.2 + Xcode 5.0.1

    Thanks.
     
  2. Mantas-Puida

    Mantas-Puida

    Joined:
    Nov 13, 2008
    Posts:
    1,864
    Thanks for reporting this. We are looking into it.
    Btw, do you use any 3rd party analytics libraries or maybe you are calling SystemInfo.deviceUniqueIdentifier from your script?
     
  3. denim

    denim

    Joined:
    Feb 3, 2014
    Posts:
    1
    Hi, unfortunately my app has been rejected for the same reason.

    My environment: Unity 4.3.4 + Xcode 5.0.1

    I am curios to know on how to solve the problem.
     
  4. Mantas-Puida

    Mantas-Puida

    Joined:
    Nov 13, 2008
    Posts:
    1,864
    Are you using any 3rd party libraries?
     
  5. missingno

    missingno

    Joined:
    Mar 5, 2013
    Posts:
    5
    Same issue here.

    Only thing other than standard Unity I'm using is NGUI.

    Unity 4.3 Xcode 4.6
     
  6. Mantas-Puida

    Mantas-Puida

    Joined:
    Nov 13, 2008
    Posts:
    1,864
  7. intoscienceDing

    intoscienceDing

    Joined:
    Nov 29, 2012
    Posts:
    10
    Thanks guys.

    We decided to use the method on the sticky post and try submit again. Will let u guys know the result.
     
  8. Deleted User

    Deleted User

    Guest

    Hi, my app was rejected too.. I'm using Gameanalytics will this fix work for me or I have to remove Gameanalytics, Adsupport.framework etc..

    Thanks.
     
  9. Mantas-Puida

    Mantas-Puida

    Joined:
    Nov 13, 2008
    Posts:
    1,864
    My posted solution does not solve issue if this API is used by 3rd party plugin. You should better check you plugin provider support documentation.
     
  10. nekromansur

    nekromansur

    Joined:
    Feb 8, 2014
    Posts:
    4
    Any ideas why this happened? I haven't updated my Unity or Xcode for a while, so nothing changed. But in the span of a couple days, I went from being able to upload proper packages to having Advertising Identification rejections. I thought it was odd.

    Nothing was added to my projects. Infact, they were two nearly identical projects. Hopefully your fix worked. I'm eagerly waiting for them to review it.
     
  11. xangamer

    xangamer

    Joined:
    Jan 15, 2011
    Posts:
    13
    Hi. I'm facing the same issue. No third party libs at all.

    Someone on stackoverflow suggested a grep.
    Here is the result:
    Code (csharp):
    1. grep -r advertisingIdentifier .
    2. ./Classes/Unity/DeviceSettings.mm:              [retClass instancesRespondToSelector:@selector(advertisingIdentifier)]
    3. ./Classes/Unity/DeviceSettings.mm:      _ADID = (NSString*)[[[manager performSelector:@selector(advertisingIdentifier)] UUIDString] retain];
    4. Binary file ./Data/Managed/UnityEngine.dll matches
    5. Binary file ./Libraries/libiPhone-lib.a matches
    6. ./Libraries/RegisterMonoModules.cpp:    void Register_UnityEngine_iPhone_get_advertisingIdentifier ();
    7. ./Libraries/RegisterMonoModules.cpp:    Register_UnityEngine_iPhone_get_advertisingIdentifier ();
    8. ./Libraries/UnityEngine.dll.s:m_wrapper_managed_to_native_UnityEngine_iPhone_get_advertisingIdentifier:
    9. ./Libraries/UnityEngine.dll.s:plt__icall_native_UnityEngine_iPhone_get_advertisingIdentifier:
    Does your solution apply to my case?
     
  12. Mantas-Puida

    Mantas-Puida

    Joined:
    Nov 13, 2008
    Posts:
    1,864
    Yes, you should apply posted solution.
     
  13. intoscienceDing

    intoscienceDing

    Joined:
    Nov 29, 2012
    Posts:
    10
    Our app just got approved this morning by using the method the sticky post.
     
  14. Hemant Sharma

    Hemant Sharma

    Joined:
    May 28, 2013
    Posts:
    4
    I am using chartboost SDK in my unity3D engine. I am not getting any help from chartboost help community. I am not understanding now that this issue (iAd rejection) is now regarding to chartboost integration or is it bug from Unity iteself. Please help because we are at the submission of the app and getting already very late.
     
  15. Agent_007

    Agent_007

    Joined:
    Dec 18, 2011
    Posts:
    899
    Apple can reject any App that uses iOS Advertising Identifier but doesn't show ads. And since it seems that Chartboost requires it, you have to either
    * Drop it
    * Wait for new Chartboost version
    * Or add Ads to your app
     
    Last edited: Feb 11, 2014
  16. dbrandt

    dbrandt

    Joined:
    Feb 14, 2014
    Posts:
    7
    I tried using the solution from the sticky post and my app was rejected for having an advertising identifier. The only third party library I am using is a script for Google Analytics found here:

    http://forum.unity3d.com/threads/188226-Google-Analytics-Mobile-Plugin-Released-Free

    After applying the solution on the sticky post, I ran: "grep -r advertisingIdentifier ." on my xcode project and get this:

    Binary file ./Data/Managed/UnityEngine.dll matches
    Binary file ./Libraries/libiPhone-lib.a matches
    ./Libraries/RegisterMonoModules.cpp: void Register_UnityEngine_iPhone_get_advertisingIdentifier ();
    ./Libraries/RegisterMonoModules.cpp: Register_UnityEngine_iPhone_get_advertisingIdentifier ();
    ./Libraries/UnityEngine.dll.s:m_wrapper_managed_to_native_UnityEngine_iPhone_get_advertisingIdentifier:
    ./Libraries/UnityEngine.dll.s:plt__icall_native_UnityEngine_iPhone_get_advertisingIdentifier:

    Any ideas as to what could be the problem?
     
  17. Mantas-Puida

    Mantas-Puida

    Joined:
    Nov 13, 2008
    Posts:
    1,864
    Other people have reported Google Analytics causing similar troubles to them (http://stackoverflow.com/questions/...-the-ad-support-framework-which-library-is-re). You should check on Google site, which version is safe to use. Not sure how this library is integrated in your Xcode project, but it might be directly referenced from Unity project tree. In such case your grep search on Xcode file tree would not find it.

    P.S. symbols you found are just C# <-> native code bindings. You should be fine with them. It's not what Apple is looking for.
     
  18. dbrandt

    dbrandt

    Joined:
    Feb 14, 2014
    Posts:
    7
    Hey Mantas,

    Thanks for the quick reply!

    The plugin that I am using is just a script that does http requests. It uses Unity's WWW class to send data to google. I am not referencing any libraries. Could this kind of code cause problems?

    I also noticed that my Xcode project links the binary with iAd.framework. It is set to optional, but does that need to be removed?

    PS: If I try to remove it I get linker errors.
     
    Last edited: Mar 6, 2014
  19. Mantas-Puida

    Mantas-Puida

    Joined:
    Nov 13, 2008
    Posts:
    1,864
    You should not need to remove iAd. Currently I'm bit out of ideas. Could you try cleaning derived data in Xcode, make a new build and resubmit it?
     
  20. dbrandt

    dbrandt

    Joined:
    Feb 14, 2014
    Posts:
    7
    I will try doing that, but before submitting the app I just want to make sure that this wouldn't be of any concern:

    I cleaned the derived data folder, then rebuilt the app and exported an .ipa file. I then changed the extension to .zip, went into the app and ran this function on the binary "otool -L <binary_name>". This is what I get:

    Code (csharp):
    1.     /System/Library/Frameworks/CoreMotion.framework/CoreMotion (compatibility version 1.0.0, current version 1613.5.2)
    2.     /usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version 1198.0.0)
    3.     /System/Library/Frameworks/Foundation.framework/Foundation (compatibility version 300.0.0, current version 1047.22.0)
    4.     /System/Library/Frameworks/UIKit.framework/UIKit (compatibility version 1.0.0, current version 2903.23.0)
    5.     /System/Library/Frameworks/OpenGLES.framework/OpenGLES (compatibility version 1.0.0, current version 1.0.0)
    6.     /System/Library/Frameworks/QuartzCore.framework/QuartzCore (compatibility version 1.2.0, current version 1.8.0)
    7.     /System/Library/Frameworks/OpenAL.framework/OpenAL (compatibility version 1.0.0, current version 1.0.0)
    8.     /usr/lib/libiconv.2.dylib (compatibility version 7.0.0, current version 7.0.0)
    9.     /System/Library/Frameworks/AudioToolbox.framework/AudioToolbox (compatibility version 1.0.0, current version 492.0.0)
    10.     /System/Library/Frameworks/CFNetwork.framework/CFNetwork (compatibility version 1.0.0, current version 672.0.8)
    11.     /System/Library/Frameworks/MediaPlayer.framework/MediaPlayer (compatibility version 1.0.0, current version 1.0.0)
    12.     /System/Library/Frameworks/CoreLocation.framework/CoreLocation (compatibility version 1.0.0, current version 1613.5.2)
    13.     /System/Library/Frameworks/SystemConfiguration.framework/SystemConfiguration (compatibility version 1.0.0, current version 615.0.0)
    14.     /System/Library/Frameworks/iAd.framework/iAd (compatibility version 1.0.0, current version 1.0.0)
    15.     /System/Library/Frameworks/CoreMedia.framework/CoreMedia (compatibility version 1.0.0, current version 1.0.0)
    16.     /System/Library/Frameworks/CoreVideo.framework/CoreVideo (compatibility version 1.2.0, current version 1.8.0)
    17.     /System/Library/Frameworks/AVFoundation.framework/AVFoundation (compatibility version 1.0.0, current version 2.0.0)
    18.     /System/Library/Frameworks/CoreGraphics.framework/CoreGraphics (compatibility version 64.0.0, current version 600.0.0)
    19.     /System/Library/Frameworks/GameKit.framework/GameKit (compatibility version 1.0.0, current version 1111.0.0)
    20.     /usr/lib/libobjc.A.dylib (compatibility version 1.0.0, current version 228.0.0)
    21.     /usr/lib/libstdc++.6.dylib (compatibility version 7.0.0, current version 100.0.0)
    22.     /usr/lib/libgcc_s.1.dylib (compatibility version 1.0.0, current version 7.0.0)
    23.     /System/Library/Frameworks/CoreFoundation.framework/CoreFoundation (compatibility version 150.0.0, current version 847.21.0)
    24.  
    I also ran "strings <binary_name>" and looked for "ASIdentifierManager", "advertisingIdentifier", "AdSupport.framework". This is what I found:

    ASIdentifierManager
    advertisingIdentifier
    UnityEngine.iPhone::get_advertisingIdentifier
    /System/Library/Frameworks/AdSupport.framework

    Does anything here look problematic?

    Thanks for your help.
     
  21. Mantas-Puida

    Mantas-Puida

    Joined:
    Nov 13, 2008
    Posts:
    1,864
    Hmz.. There shouldn't be neither "ASIdentifierManager" nor "/System/Library/Frameworks/AdSupport.framework" if quickfix is applied properly. But in such case your grep search would find them too. If you submit your Xcode project (+ipa) as bugreport I could look at it.
     
  22. Nordir

    Nordir

    Joined:
    Apr 25, 2012
    Posts:
    20
    Maybe my experience will be useful for those who use 3d party advertising services:

    - My game was rejected
    - I replied to the Apple review team, giving instructions for how to see ads in my game and attached screenshots with the in-game ads
    - My game was ready to sale in 2 days after that

    P. S. I use Unity 4.3.1f1
     
  23. dbrandt

    dbrandt

    Joined:
    Feb 14, 2014
    Posts:
    7
    I submitted a bug report last week, but just wanted to make sure that you knew. I am using an older version of Unity (4.3.3). Let me know if you find anything. Thanks again.
     
    Last edited: Mar 12, 2014
  24. dbrandt

    dbrandt

    Joined:
    Feb 14, 2014
    Posts:
    7
    After playing around with this a little more, I just realized that the build of the app that Xcode makes in the derived data folder does not have these strings. When I go to create a build of the app through the Organizer window -> Archives -> Distribute, and choose "Save for Enterprise or Ad Hoc Deployment" and check the binary that is created, the strings appear. Any ideas as to why this would happen?
     
    Last edited: Mar 19, 2014
  25. dbrandt

    dbrandt

    Joined:
    Feb 14, 2014
    Posts:
    7
    It turns out that I forgot to archive the app! In Xcode, go to Product -> Archive. Once the app is archived, building the .ipa (make sure the most recently created version is selected) using "Save for Enterprise or Ad Hoc Deployment" and checking the binary no longer yields the strings "ASIdentifierManager" and "/System/Library/Frameworks/AdSupport.framework".
     
    Last edited: Mar 19, 2014
  26. dbrandt

    dbrandt

    Joined:
    Feb 14, 2014
    Posts:
    7
    The app was accepted using the solution posted by Mantas Puida. Just don't forget to archive the new build.
     
  27. IndieFist

    IndieFist

    Joined:
    Jul 18, 2013
    Posts:
    520
    I have solved my problem talking with the reviewer and request to play 5 partys to get an ads.
     
    Last edited: Nov 5, 2015
  28. planetfactory

    planetfactory

    Joined:
    May 18, 2016
    Posts:
    56
    Hi,
    we are being rejected by Apple because this same reason, with Unity 2019.2.4.
    They say:

    Code of concern in your app binary has been confirmed around dynamic use of Ad Support code. Specifically, there is a portion of the binary code making use of the following elements:

    Method calls +[NSBundle bundleWithPath:] and -[NSBundle classNamed:]
    Strings @"/System/Library/Frameworks/AdSupport.framework" and @"ASIdentifierManager"
    Selector reference sharedManager

    We are not using ads nor analytics.

    Thanks,

    Albert
     
  29. IndieFist

    IndieFist

    Joined:
    Jul 18, 2013
    Posts:
    520
    Ayer you using another sdk mediatition for ads?
     
  30. Mauri

    Mauri

    Joined:
    Dec 9, 2010
    Posts:
    2,665
  31. planetfactory

    planetfactory

    Joined:
    May 18, 2016
    Posts:
    56
    Finally the app was approved by Apple, but I had to manually edit some files in xCode, so that meany that I will have to make these changes every time that I make a build from Unity. Not cool.
     
  32. kaarloew

    kaarloew

    Joined:
    Nov 1, 2018
    Posts:
    360