A Collection of Ads Behind Your Favorite Game App With More Than 6 Million Downloads

– By Trustlook Research Team

A popular Chinese game with more than 6 million downloads secretly promotes other apps using a well-protected and widely used advertisement library.

Package name: com.xyz.ddz

Chinese App name: 欢乐逗地主

Download count: 6,000,000+


Trustlook has discovered a serious adware intrusion within one of the most popular game apps in China. Immediately after installation, the app behaves normally, in which a user can play the game without restrictions or advertisements.After approximately 4 hours , various types of pop up large screen advertisements (i.e. adware) are displayed, even when the app is not in use.

The app is able to display this adware by importing two ad libraries. These libraries are implemented using native methods, including communicating with the Host App when prompted by the ad. These two ad libraries are widely used, but many anti-virus vendors are not able to detect them. All of the strings in these ad libraries are encrypted, and together these ad libraries adopt at least 8 methods to display ads, including:

  • To display the ad in the middle of the launcher
  • To display the installation notification (which can not be closed) in the middle of the launcher
  • To display the ad in the middle of the browser
  • To display the ad banner at the top of the browser
  • To display the ad banner at the bottom of the browser
  • To display the ad banner at the top of the input method
  • To display a floating ad banner with the Angry Bird icon
  • To dreate a promoted app icon in the launcher

One of the most popular implementations of this adware is an ad in the middle of the launcher. If you click the ad, then one of the following three APKs will be downloaded:

  • Qihoo mobile assistant APK (when you click the first Ad screen)
  • Qihoo browser APK (when you click the second Ad screen)
  • Jiuyou APK (when you click the third Ad screen)





After you have downloaded the APK file, a pop up window will notify you to install the downloaded APK file. If you click the Cancel button, every 30 minutes or when you attempt to unlock your phone, the same pop up window will be displayed asking if you would like to install the APK. And this pop up doesn’t have a “close” button or feature. It’s a never ending loop that creates a trap for the user.



If you click the “Enter” button(which the app forces because there is no other option to bypass the action), it will pop up this window:



When you open a browser, such as Google Chrome, the ads will be displayed at the top, bottom, or middle of the page. A message also shows up in the notification bar of your device.






And the ad displayed in the notification bar.


Ad displayed in the browser:





If you click the banner ad that is displayed on the bottom of a browser window, the following window containing three app icons will appear.



In addition to the pop up ad displaying the three app icons, a floating banner icon, which is the same in appearance as the Angry bird icon below, will appear on your home screen.



If you click the Angry Birds icon, it will pop up a window with a list of apps, like this:





After the app has been installed for 5 hours, it will create a shortcut to the Qihoo mobile assistant on the launcher screen, no matter if you close the ad or not. Sometimes the ad will pop up suddenly and erratically. 





Unfortunately, this shortcut is not a real shortcut that points to the Qihoo mobile assistant app. Instead it points to the Qihoo mobile assistant APK file, which located in the sdcard in the path:


/0Mdf4fxaQpU1MNb+F6O3YquZI+c= The game didn’t install the Qihoo 360 app, but if you click this icon, it will begin to install the Qihoo mobile assistant app.



After further analysis of this app, we discovered that the advertisement function is implemented in this module: com.xyz.ddz.gauxsw.


Most strings are encrypted in the function of com.xyz.ddz.gauxsw.d.a.a.a():



The encryption routine first decodes the string (the first parameter of this function) in base64 format, then xor it with every byte in the second parameter (“7b120431-5374-40d1-84d6-624980271ac8”):

20 21



Trustlook created a tool to decrypt it, which revealed the following strings:





From the analysis we know that the ad is displayed by the com.yt.uulib and  youtou.ad.api SDK, which are two popular adware libraries.

These two ad libraries are able to display ads in two ways:

  • Floating banner
  • Fixed banner

We found that the app used the self-protect function to protect itself and to evade anti-virus vendors. It runs 3 processes (it runs one first, which then forks into two more). When you close any of them, it will restart and run the 3 processes again:


We also found that this app uses the native library to notify the main app to activate the the native library file. It is named daemon_exe, is a .so file, and placed in:


The main app will check if the user’s phone is rooted. If it is, the main app will load the daemon_exe into system as the root user:


After the analysis of this native library file, we found that its main function is to communicate with the main app by local tcp connection ( and then send the broadcast to it for waking up and displaying the ad.




After the execution, the native library will execute this command as the root user:

/system/bin/am broadcast -a com.uu.action.wakeup –es start_bc_send_id $ro.build.version.sdk(var)$ –include-stopped-packages –user 0

This command will send a broadcast, whose action is com.uu.action.wakeup and it will take the key-value string pair start_bc_send_id”:$ro.build.version.sdk(var)$ and the phone’s sdk num and the –include-stopped-packages as the parameter.

From the manifest, we know that this broadcast could be received by com.xyz.ddz.gauxsw.a.e.a:


At the time of this release, the Trustlook Mobile Security app and Blue Frog Mobile Security app teams have detected the malicious behaviors of the sample being studied. 



Trustlook Integrates Adware Detection Feature

Just like malware, adware is becoming a significant problem for mobile users. Have you ever wondered how that mysterious icon ended up on your Android phone’s start screen? Or what about the annoying ads clogging your notification bar? You aren’t alone. Thousands of Android apps now include software that shoves marketing icons onto your phone’s start screen or pushes advertising into your notification bar–and many of the apps give you no warning about the ad invasion.

Android remains an adware magnet with tens of thousands of apps that collect information without the user’s knowledge. Such adware aggressively collects personal information from the mobile device it’s installed on, including things such as name, birth date, location, serial number, contacts, and browser bookmarks. Like malware, this data is often collected without users’ consent.

But fear not! Trustlook has just released an Adware detection feature in version 3.1.8. If Trustlook detects adware within any of your apps, you will be notified and will be able to uninstall the app if you choose.

Download the Trustlook Mobile Security app.