/* */ package com.tencent.bugly.crashreport.common.info;
/* */
/* */ import android.content.Context;
/* */ import android.net.ConnectivityManager;
/* */ import android.net.NetworkInfo;
/* */ import android.net.wifi.WifiInfo;
/* */ import android.net.wifi.WifiManager;
/* */ import android.os.Build;
/* */ import android.os.Build.VERSION;
/* */ import android.os.Environment;
/* */ import android.os.StatFs;
/* */ import android.provider.Settings.Secure;
/* */ import android.telephony.TelephonyManager;
/* */ import com.tencent.bugly.proguard.an;
/* */ import com.tencent.bugly.proguard.ap;
/* */ import java.io.BufferedReader;
/* */ import java.io.File;
/* */ import java.io.FileReader;
/* */ import java.io.IOException;
/* */ import java.net.NetworkInterface;
/* */ import java.util.ArrayList;
/* */ import java.util.Locale;
/* */
/* */
/* */
/* */
/* */
/* */
/* */
/* */
/* */
/* */
/* */
/* */
/* */
/* */
/* */
/* */
/* */
/* */
/* */ public class b
/* */ {
/* */ public static String a()
/* */ {
/* */ try
/* */ {
/* 47 */ return Build.MODEL;
/* */ } catch (Throwable localThrowable) {
/* 49 */ if (!an.a(localThrowable)) {
/* 50 */ localThrowable.printStackTrace();
/* */ }
/* */ }
/* 53 */ return "fail";
/* */ }
/* */
/* */
/* */
/* */
/* */ public static String b()
/* */ {
/* */ try
/* */ {
/* 63 */ return Build.VERSION.RELEASE;
/* */ } catch (Throwable localThrowable) {
/* 65 */ if (!an.a(localThrowable)) {
/* 66 */ localThrowable.printStackTrace();
/* */ }
/* */ }
/* 69 */ return "fail";
/* */ }
/* */
/* */
/* */
/* */
/* */ public static int c()
/* */ {
/* */ try
/* */ {
/* 79 */ return Build.VERSION.SDK_INT;
/* */ } catch (Throwable localThrowable) {
/* 81 */ if (!an.a(localThrowable)) {
/* 82 */ localThrowable.printStackTrace();
/* */ }
/* */ }
/* 85 */ return -1;
/* */ }
/* */
/* */
/* */
/* */
/* */
/* */
/* */ public static String a(Context paramContext)
/* */ {
/* 95 */ if (paramContext == null) {
/* 96 */ return null;
/* */ }
/* 98 */ if (!AppInfo.a(paramContext, "android.permission.READ_PHONE_STATE")) {
/* 99 */ an.d("no READ_PHONE_STATE permission to get IMEI", new Object[0]);
/* 100 */ return null;
/* */ }
/* 102 */ String str = null;
/* */ try
/* */ {
/* 105 */ TelephonyManager localTelephonyManager = (TelephonyManager)paramContext.getSystemService("phone");
/* 106 */ if (localTelephonyManager != null) {
/* 107 */ str = localTelephonyManager.getDeviceId();
/* 108 */ if (str != null) {
/* 109 */ str = str.toLowerCase();
/* */ }
/* */ }
/* */ }
/* */ catch (Throwable localThrowable) {
/* 114 */ an.a("Failed to get IMEI.", new Object[0]);
/* */ }
/* 116 */ return str;
/* */ }
/* */
/* */
/* */
/* */
/* */
/* */
/* */ public static String b(Context paramContext)
/* */ {
/* 126 */ if (paramContext == null) {
/* 127 */ return null;
/* */ }
/* 129 */ if (!AppInfo.a(paramContext, "android.permission.READ_PHONE_STATE")) {
/* 130 */ an.d("no READ_PHONE_STATE permission to get IMSI", new Object[0]);
/* 131 */ return null;
/* */ }
/* 133 */ String str = null;
/* */ try
/* */ {
/* 136 */ TelephonyManager localTelephonyManager = (TelephonyManager)paramContext.getSystemService("phone");
/* 137 */ if (localTelephonyManager != null) {
/* 138 */ str = localTelephonyManager.getSubscriberId();
/* 139 */ if (str != null) {
/* 140 */ str = str.toLowerCase();
/* */ }
/* */ }
/* */ }
/* */ catch (Throwable localThrowable) {
/* 145 */ an.a("Failed to get IMSI.", new Object[0]);
/* */ }
/* 147 */ return str;
/* */ }
/* */
/* */
/* */
/* */
/* */
/* */
/* */ public static String c(Context paramContext)
/* */ {
/* 157 */ String str = "fail";
/* 158 */ if (paramContext == null) {
/* 159 */ return str;
/* */ }
/* */ try
/* */ {
/* 163 */ str = Settings.Secure.getString(paramContext.getContentResolver(), "android_id");
/* 164 */ if (null == str) {
/* 165 */ str = "null";
/* */ } else {
/* 167 */ str = str.toLowerCase();
/* */ }
/* */ } catch (Throwable localThrowable) {
/* 170 */ if (!an.a(localThrowable)) {
/* 171 */ an.a("Failed to get Android ID.", new Object[0]);
/* */ }
/* */ }
/* 174 */ return str;
/* */ }
/* */
/* */
/* */
/* */
/* */
/* */
/* */
/* */
/* */
/* */
/* */
/* */
/* */
/* */
/* */
/* */
/* */
/* */
/* */
/* */
/* */
/* */
/* */
/* */
/* */
/* */
/* */
/* */
/* */
/* */
/* */
/* */
/* */
/* */
/* */
/* */ public static String d(Context paramContext)
/* */ {
/* 213 */ String str1 = "fail";
/* 214 */ if (paramContext == null) {
/* 215 */ return str1;
/* */ }
/* */ try {
/* 218 */ WifiManager localWifiManager = (WifiManager)paramContext.getSystemService("wifi");
/* 219 */ if (localWifiManager != null) {
/* 220 */ WifiInfo localWifiInfo = localWifiManager.getConnectionInfo();
/* 221 */ if (localWifiInfo != null) {
/* 222 */ str1 = localWifiInfo.getMacAddress();
/* 223 */ if ((str1 == null) || (str1.equals("02:00:00:00:00:00"))) {
/* 224 */ String str2 = ap.a(paramContext, "wifi.interface");
/* 225 */ an.c("MAC interface: %s", new Object[] { str2 });
/* 226 */ NetworkInterface localNetworkInterface = NetworkInterface.getByName(str2);
/* */
/* 228 */ if (localNetworkInterface == null) {
/* 229 */ localNetworkInterface = NetworkInterface.getByName("wlan0");
/* */ }
/* */
/* 232 */ if (localNetworkInterface == null) {
/* 233 */ localNetworkInterface = NetworkInterface.getByName("eth0");
/* */ }
/* 235 */ if (localNetworkInterface != null) {
/* 236 */ byte[] arrayOfByte = localNetworkInterface.getHardwareAddress();
/* 237 */ str1 = ap.e(arrayOfByte);
/* */ }
/* */ }
/* */ }
/* */ }
/* */ } catch (Throwable localThrowable) {
/* 243 */ if (!an.a(localThrowable)) {
/* 244 */ localThrowable.printStackTrace();
/* */ }
/* */ }
/* 247 */ if (str1 == null) {
/* 248 */ str1 = "null";
/* */ }
/* 250 */ an.c("MAC address: %s", new Object[] { str1 });
/* 251 */ return str1.toLowerCase();
/* */ }
/* */
/* */
/* */
/* */
/* */
/* */
/* */ public static String e(Context paramContext)
/* */ {
/* 261 */ String str = "fail";
/* 262 */ if (paramContext == null) {
/* 263 */ return str;
/* */ }
/* */ try
/* */ {
/* 267 */ TelephonyManager localTelephonyManager = (TelephonyManager)paramContext.getSystemService("phone");
/* 268 */ if (localTelephonyManager != null) {
/* 269 */ str = localTelephonyManager.getSimSerialNumber();
/* 270 */ if (str == null) {
/* 271 */ str = "null";
/* */ }
/* */ }
/* */ } catch (Throwable localThrowable) {
/* 275 */ an.a("Failed to get SIM serial number.", new Object[0]);
/* */ }
/* 277 */ return str;
/* */ }
/* */
/* */
/* */
/* */
/* */ public static String d()
/* */ {
/* */ try
/* */ {
/* 287 */ return Build.SERIAL;
/* */ } catch (Throwable localThrowable) {
/* 289 */ an.a("Failed to get hardware serial number.", new Object[0]); }
/* 290 */ return "fail";
/* */ }
/* */
/* */
/* */
/* */
/* */
/* */ public static boolean e()
/* */ {
/* */ try
/* */ {
/* 301 */ if (Environment.getExternalStorageState().equals("mounted")) {
/* 302 */ return true;
/* */ }
/* */ } catch (Throwable localThrowable) {
/* 305 */ if (!an.a(localThrowable)) {
/* 306 */ localThrowable.printStackTrace();
/* */ }
/* */ }
/* 309 */ return false;
/* */ }
/* */
/* */
/* */
/* */ private static String o()
/* */ {
/* 316 */ String str1 = "/system/build.prop";
/* 317 */ FileReader localFileReader = null;
/* 318 */ BufferedReader localBufferedReader = null;
/* */ try {
/* 320 */ localFileReader = new FileReader(str1);
/* 321 */ localBufferedReader = new BufferedReader(localFileReader, 2048);
/* 322 */ String str2 = null;
/* */ Object localObject1;
/* 324 */ while ((str3 = localBufferedReader.readLine()) != null) {
/* 325 */ localObject1 = str3.split("=", 2);
/* 326 */ if (localObject1.length == 2) {
/* 327 */ if (localObject1[0].equals("ro.product.cpu.abilist")) {
/* 328 */ str2 = localObject1[1];
/* 329 */ break; }
/* 330 */ if (localObject1[0].equals("ro.product.cpu.abi")) {
/* 331 */ str2 = localObject1[1];
/* 332 */ break;
/* */ }
/* */ }
/* */ }
/* 336 */ if (str2 != null) {
/* 337 */ str2 = str2.split(",")[0];
/* */ }
/* 339 */ return str2;
/* */ } catch (Throwable localThrowable) { String str3;
/* 341 */ if (!an.a(localThrowable)) {
/* 342 */ localThrowable.printStackTrace();
/* */ }
/* 344 */ return null;
/* */ }
/* */ finally {
/* 347 */ if (localBufferedReader != null) {
/* */ try {
/* 349 */ localBufferedReader.close();
/* */ } catch (IOException localIOException5) {
/* 351 */ if (!an.a(localIOException5)) {
/* 352 */ localIOException5.printStackTrace();
/* */ }
/* */ }
/* */ }
/* 356 */ if (localFileReader != null) {
/* */ try {
/* 358 */ localFileReader.close();
/* */ } catch (IOException localIOException6) {
/* 360 */ if (!an.a(localIOException6)) {
/* 361 */ localIOException6.printStackTrace();
/* */ }
/* */ }
/* */ }
/* */ }
/* */ }
/* */
/* */
/* */
/* */
/* */
/* */
/* */ public static String a(boolean paramBoolean)
/* */ {
/* */ try
/* */ {
/* 377 */ String str = null;
/* 378 */ if (paramBoolean) {
/* 379 */ str = o();
/* */ }
/* 381 */ if (str == null) {
/* 382 */ str = System.getProperty("os.arch");
/* */ }
/* 384 */ return "" + str;
/* */ } catch (Throwable localThrowable) {
/* 386 */ if (!an.a(localThrowable)) {
/* 387 */ localThrowable.printStackTrace();
/* */ }
/* */ }
/* 390 */ return "fail";
/* */ }
/* */
/* */
/* */
/* */
/* */ public static long f()
/* */ {
/* 398 */ long l1 = -1L;
/* */ try {
/* 400 */ File localFile = Environment.getDataDirectory();
/* 401 */ StatFs localStatFs = new StatFs(localFile.getPath());
/* 402 */ long l2 = localStatFs.getBlockSize();
/* 403 */ long l3 = localStatFs.getBlockCount();
/* 404 */ l1 = l3 * l2;
/* */ } catch (Throwable localThrowable) {
/* 406 */ if (!an.a(localThrowable)) {
/* 407 */ localThrowable.printStackTrace();
/* */ }
/* */ }
/* 410 */ return l1;
/* */ }
/* */
/* */
/* */
/* */
/* */ public static long g()
/* */ {
/* 418 */ long l1 = -1L;
/* */ try {
/* 420 */ File localFile = Environment.getDataDirectory();
/* 421 */ StatFs localStatFs = new StatFs(localFile.getPath());
/* 422 */ long l2 = localStatFs.getBlockSize();
/* 423 */ long l3 = localStatFs.getAvailableBlocks();
/* 424 */ l1 = l3 * l2;
/* */ } catch (Throwable localThrowable) {
/* 426 */ if (!an.a(localThrowable)) {
/* 427 */ localThrowable.printStackTrace();
/* */ }
/* */ }
/* 430 */ return l1;
/* */ }
/* */
/* */
/* */
/* */ public static long h()
/* */ {
/* 437 */ String str1 = "/proc/meminfo";
/* 438 */ FileReader localFileReader = null;
/* 439 */ BufferedReader localBufferedReader = null;
/* */ try {
/* 441 */ localFileReader = new FileReader(str1);
/* 442 */ localBufferedReader = new BufferedReader(localFileReader, 2048);
/* 443 */ String str2 = localBufferedReader.readLine();
/* 444 */ if (str2 == null) {
/* 445 */ return -1L;
/* */ }
/* 447 */ String[] arrayOfString = str2.split(":\\s+", 2);
/* 448 */ String str4 = arrayOfString[1].toLowerCase();
/* 449 */ String str3 = str4.replace("kb", "").trim();
/* 450 */ long l2 = Long.parseLong(str3) * 1024L;
/* 451 */ return l2;
/* */ } catch (Throwable localThrowable) {
/* 453 */ if (!an.a(localThrowable)) {
/* 454 */ localThrowable.printStackTrace();
/* */ }
/* */ }
/* */ finally {
/* 458 */ if (localBufferedReader != null) {
/* */ try {
/* 460 */ localBufferedReader.close();
/* */ } catch (IOException localIOException7) {
/* 462 */ if (!an.a(localIOException7)) {
/* 463 */ localIOException7.printStackTrace();
/* */ }
/* */ }
/* */ }
/* 467 */ if (localFileReader != null) {
/* */ try {
/* 469 */ localFileReader.close();
/* */ } catch (IOException localIOException8) {
/* 471 */ if (!an.a(localIOException8)) {
/* 472 */ localIOException8.printStackTrace();
/* */ }
/* */ }
/* */ }
/* */ }
/* */
/* 478 */ return -2L;
/* */ }
/* */
/* */
/* */
/* */ public static long i()
/* */ {
/* 485 */ String str1 = "/proc/meminfo";
/* 486 */ FileReader localFileReader = null;
/* 487 */ BufferedReader localBufferedReader = null;
/* */ try {
/* 489 */ localFileReader = new FileReader(str1);
/* 490 */ localBufferedReader = new BufferedReader(localFileReader, 2048);
/* 491 */ localBufferedReader.readLine();
/* 492 */ String str2 = localBufferedReader.readLine();
/* 493 */ if (str2 == null) {
/* 494 */ return -1L;
/* */ }
/* 496 */ String[] arrayOfString = str2.split(":\\s+", 2);
/* 497 */ String str4 = arrayOfString[1].toLowerCase();
/* 498 */ String str3 = str4.replace("kb", "").trim();
/* 499 */ long l2 = 0L;
/* 500 */ l2 += Long.parseLong(str3) * 1024L;
/* */
/* 502 */ str2 = localBufferedReader.readLine();
/* 503 */ long l3; if (str2 == null) {
/* 504 */ return -1L;
/* */ }
/* 506 */ arrayOfString = str2.split(":\\s+", 2);
/* 507 */ str4 = arrayOfString[1].toLowerCase();
/* 508 */ str3 = str4.replace("kb", "").trim();
/* 509 */ l2 += Long.parseLong(str3) * 1024L;
/* */
/* 511 */ str2 = localBufferedReader.readLine();
/* 512 */ if (str2 == null) {
/* 513 */ return -1L;
/* */ }
/* 515 */ arrayOfString = str2.split(":\\s+", 2);
/* 516 */ str4 = arrayOfString[1].toLowerCase();
/* 517 */ str3 = str4.replace("kb", "").trim();
/* 518 */ l2 += Long.parseLong(str3) * 1024L;
/* */
/* 520 */ return l2;
/* */ } catch (Throwable localThrowable) {
/* 522 */ if (!an.a(localThrowable)) {
/* 523 */ localThrowable.printStackTrace();
/* */ }
/* */ }
/* */ finally {
/* 527 */ if (localBufferedReader != null) {
/* */ try {
/* 529 */ localBufferedReader.close();
/* */ } catch (IOException localIOException11) {
/* 531 */ if (!an.a(localIOException11)) {
/* 532 */ localIOException11.printStackTrace();
/* */ }
/* */ }
/* */ }
/* 536 */ if (localFileReader != null) {
/* */ try {
/* 538 */ localFileReader.close();
/* */ } catch (IOException localIOException12) {
/* 540 */ if (!an.a(localIOException12)) {
/* 541 */ localIOException12.printStackTrace();
/* */ }
/* */ }
/* */ }
/* */ }
/* */
/* 547 */ return -2L;
/* */ }
/* */
/* */
/* */
/* */
/* */
/* */
/* */ public static long j()
/* */ {
/* 557 */ if (!e()) {
/* 558 */ return 0L;
/* */ }
/* */ try
/* */ {
/* 562 */ StatFs localStatFs = new StatFs(Environment.getExternalStorageDirectory().getPath());
/* 563 */ int i = localStatFs.getBlockSize();
/* 564 */ long l = localStatFs.getBlockCount();
/* 565 */ return l * i;
/* */ } catch (Throwable localThrowable) {
/* 567 */ if (!an.a(localThrowable)) {
/* 568 */ localThrowable.printStackTrace();
/* */ }
/* */ }
/* 571 */ return -2L;
/* */ }
/* */
/* */
/* */
/* */
/* */
/* */
/* */ public static long k()
/* */ {
/* 581 */ if (!e()) {
/* 582 */ return 0L;
/* */ }
/* */ try
/* */ {
/* 586 */ StatFs localStatFs = new StatFs(Environment.getExternalStorageDirectory().getPath());
/* 587 */ int i = localStatFs.getBlockSize();
/* 588 */ long l = localStatFs.getAvailableBlocks();
/* 589 */ return l * i;
/* */ } catch (Throwable localThrowable) {
/* 591 */ if (!an.a(localThrowable)) {
/* 592 */ localThrowable.printStackTrace();
/* */ }
/* */ }
/* 595 */ return -2L;
/* */ }
/* */
/* */
/* */
/* */ public static String l()
/* */ {
/* 602 */ String str = "fail";
/* */ try {
/* 604 */ str = Locale.getDefault().getCountry();
/* */ } catch (Throwable localThrowable) {
/* 606 */ if (!an.a(localThrowable)) {
/* 607 */ localThrowable.printStackTrace();
/* */ }
/* */ }
/* 610 */ return str;
/* */ }
/* */
/* */
/* */
/* */ public static String m()
/* */ {
/* 617 */ String str = "fail";
/* */ try {
/* 619 */ str = Build.BRAND;
/* */ } catch (Throwable localThrowable) {
/* 621 */ if (!an.a(localThrowable)) {
/* 622 */ localThrowable.printStackTrace();
/* */ }
/* */ }
/* 625 */ return str;
/* */ }
/* */
/* */
/* */
/* */
/* */
/* */ public static String f(Context paramContext)
/* */ {
/* 634 */ String str = "unknown";
/* */ try
/* */ {
/* 637 */ ConnectivityManager localConnectivityManager = (ConnectivityManager)paramContext.getSystemService("connectivity");
/* 638 */ NetworkInfo localNetworkInfo = localConnectivityManager.getActiveNetworkInfo();
/* 639 */ if (localNetworkInfo == null) {
/* 640 */ return null;
/* */ }
/* 642 */ if (localNetworkInfo.getType() == 1) {
/* 643 */ str = "WIFI";
/* 644 */ } else if (localNetworkInfo.getType() == 0)
/* */ {
/* 646 */ TelephonyManager localTelephonyManager = (TelephonyManager)paramContext.getSystemService("phone");
/* 647 */ if (localTelephonyManager != null) {
/* 648 */ int i = localTelephonyManager.getNetworkType();
/* 649 */ switch (i) {
/* */ case 1:
/* 651 */ str = "GPRS";
/* 652 */ break;
/* */ case 2:
/* 654 */ str = "EDGE";
/* 655 */ break;
/* */ case 3:
/* 657 */ str = "UMTS";
/* 658 */ break;
/* */ case 8:
/* 660 */ str = "HSDPA";
/* 661 */ break;
/* */ case 9:
/* 663 */ str = "HSUPA";
/* 664 */ break;
/* */ case 10:
/* 666 */ str = "HSPA";
/* 667 */ break;
/* */ case 4:
/* 669 */ str = "CDMA";
/* 670 */ break;
/* */ case 5:
/* 672 */ str = "EVDO_0";
/* 673 */ break;
/* */ case 6:
/* 675 */ str = "EVDO_A";
/* 676 */ break;
/* */ case 7:
/* 678 */ str = "1xRTT";
/* 679 */ break;
/* */ case 11:
/* 681 */ str = "iDen";
/* 682 */ break;
/* */ case 12:
/* 684 */ str = "EVDO_B";
/* 685 */ break;
/* */ case 13:
/* 687 */ str = "LTE";
/* 688 */ break;
/* */ case 14:
/* 690 */ str = "eHRPD";
/* 691 */ break;
/* */ case 15:
/* 693 */ str = "HSPA+";
/* 694 */ break;
/* */ default:
/* 696 */ str = "MOBILE(" + i + ")";
/* */ }
/* */ }
/* */ }
/* */ } catch (Exception localException) {
/* 701 */ if (!an.a(localException)) {
/* 702 */ localException.printStackTrace();
/* */ }
/* */ }
/* 705 */ return str;
/* */ }
/* */
/* */
/* */
/* */
/* */
/* */ public static String g(Context paramContext)
/* */ {
/* 714 */ String str = ap.a(paramContext, "ro.miui.ui.version.name");
/* 715 */ if ((!ap.a(str)) && (!str.equals("fail"))) {
/* 716 */ return "XiaoMi/MIUI/" + str;
/* */ }
/* */
/* */
/* 720 */ str = ap.a(paramContext, "ro.build.version.emui");
/* 721 */ if ((!ap.a(str)) && (!str.equals("fail"))) {
/* 722 */ return "HuaWei/EMOTION/" + str;
/* */ }
/* */
/* */
/* 726 */ str = ap.a(paramContext, "ro.lenovo.series");
/* 727 */ if ((!ap.a(str)) && (!str.equals("fail"))) {
/* 728 */ str = ap.a(paramContext, "ro.build.version.incremental");
/* 729 */ return "Lenovo/VIBE/" + str;
/* */ }
/* */
/* */
/* 733 */ str = ap.a(paramContext, "ro.build.nubia.rom.name");
/* 734 */ if ((!ap.a(str)) && (!str.equals("fail"))) {
/* 735 */ return
/* 736 */ "Zte/NUBIA/" + str + "_" + ap.a(paramContext, "ro.build.nubia.rom.code");
/* */ }
/* */
/* */
/* 740 */ str = ap.a(paramContext, "ro.meizu.product.model");
/* 741 */ if ((!ap.a(str)) && (!str.equals("fail"))) {
/* 742 */ return "Meizu/FLYME/" + ap.a(paramContext, "ro.build.display.id");
/* */ }
/* */
/* */
/* 746 */ str = ap.a(paramContext, "ro.build.version.opporom");
/* 747 */ if ((!ap.a(str)) && (!str.equals("fail"))) {
/* 748 */ return "Oppo/COLOROS/" + str;
/* */ }
/* */
/* */
/* 752 */ str = ap.a(paramContext, "ro.vivo.os.build.display.id");
/* 753 */ if ((!ap.a(str)) && (!str.equals("fail"))) {
/* 754 */ return "vivo/FUNTOUCH/" + str;
/* */ }
/* */
/* */
/* 758 */ str = ap.a(paramContext, "ro.aa.romver");
/* 759 */ if ((!ap.a(str)) && (!str.equals("fail"))) {
/* 760 */ return "htc/" + str + "/" + ap.a(paramContext, "ro.build.description");
/* */ }
/* */
/* */
/* 764 */ str = ap.a(paramContext, "ro.lewa.version");
/* 765 */ if ((!ap.a(str)) && (!str.equals("fail"))) {
/* 766 */ return "tcl/" + str + "/" + ap.a(paramContext, "ro.build.display.id");
/* */ }
/* */
/* */
/* 770 */ str = ap.a(paramContext, "ro.gn.gnromvernumber");
/* 771 */ if ((!ap.a(str)) && (!str.equals("fail"))) {
/* 772 */ return "amigo/" + str + "/" + ap.a(paramContext, "ro.build.display.id");
/* */ }
/* */
/* */
/* 776 */ str = ap.a(paramContext, "ro.build.tyd.kbstyle_version");
/* 777 */ if ((!ap.a(str)) && (!str.equals("fail"))) {
/* 778 */ return "dido/" + str;
/* */ }
/* */
/* */
/* 782 */ return
/* 783 */ ap.a(paramContext, "ro.build.fingerprint") + "/" + ap.a(paramContext, "ro.build.rom.id");
/* */ }
/* */
/* */
/* */
/* */
/* */ public static String h(Context paramContext)
/* */ {
/* 791 */ return ap.a(paramContext, "ro.board.platform");
/* */ }
/* */
/* */
/* */
/* */
/* */
/* */
/* */ public static boolean i(Context paramContext)
/* */ {
/* 801 */ boolean bool1 = false;
/* 802 */ boolean bool2 = false;
/* */ try {
/* 804 */ bool2 = new File("/system/app/Superuser.apk").exists();
/* */ } catch (Throwable localThrowable) {
/* 806 */ if (!an.b(localThrowable)) {
/* 807 */ localThrowable.printStackTrace();
/* */ }
/* */ }
/* */
/* 811 */ Boolean localBoolean = null;
/* */
/* 813 */ ArrayList localArrayList = ap.a(paramContext, new String[] { "/system/bin/sh", "-c", "type su" });
/* 814 */ if ((localArrayList != null) && (localArrayList.size() > 0)) {
/* 815 */ for (String str : localArrayList) {
/* 816 */ an.c(str, new Object[0]);
/* 817 */ if (str.contains("not found")) {
/* 818 */ localBoolean = Boolean.valueOf(false);
/* */ }
/* */ }
/* 821 */ if (localBoolean == null) {
/* 822 */ localBoolean = Boolean.valueOf(true);
/* */ }
/* */ }
/* 825 */ localBoolean = Boolean.valueOf(localBoolean == null ? false : localBoolean.booleanValue());
/* */
/* */
/* 828 */ int i = (Build.TAGS != null) && (Build.TAGS.contains("test-keys")) ? 1 : 0;
/* */
/* 830 */ if ((i != 0) || (bool2) || (localBoolean.booleanValue())) {
/* 831 */ bool1 = true;
/* */ }
/* 833 */ return bool1;
/* */ }
/* */
/* */
/* */
/* */
/* */
/* */ public static String n()
/* */ {
/* 842 */ BufferedReader localBufferedReader = null;
/* */ try {
/* 844 */ StringBuilder localStringBuilder = new StringBuilder();
/* 845 */ if (new File("/sys/block/mmcblk0/device/type").exists()) {
/* 846 */ localBufferedReader = new BufferedReader(new FileReader("/sys/block/mmcblk0/device/type"));
/* 847 */ str = localBufferedReader.readLine();
/* 848 */ if (str != null) {
/* 849 */ localStringBuilder.append(str);
/* */ }
/* 851 */ localBufferedReader.close();
/* */ }
/* 853 */ localStringBuilder.append(",");
/* 854 */ if (new File("/sys/block/mmcblk0/device/name").exists()) {
/* 855 */ localBufferedReader = new BufferedReader(new FileReader("/sys/block/mmcblk0/device/name"));
/* 856 */ str = localBufferedReader.readLine();
/* 857 */ if (str != null) {
/* 858 */ localStringBuilder.append(str);
/* */ }
/* 860 */ localBufferedReader.close();
/* */ }
/* 862 */ localStringBuilder.append(",");
/* 863 */ if (new File("/sys/block/mmcblk0/device/cid").exists()) {
/* 864 */ localBufferedReader = new BufferedReader(new FileReader("/sys/block/mmcblk0/device/cid"));
/* 865 */ str = localBufferedReader.readLine();
/* 866 */ if (str != null) {
/* 867 */ localStringBuilder.append(str);
/* */ }
/* */ }
/* 870 */ return localStringBuilder.toString();
/* */ } catch (Throwable localThrowable) {
/* */ String str;
/* 873 */ return null;
/* */ } finally {
/* 875 */ if (localBufferedReader != null) {
/* */ try {
/* 877 */ localBufferedReader.close();
/* */ } catch (IOException localIOException3) {
/* 879 */ an.a(localIOException3);
/* */ }
/* */ }
/* */ }
/* */ }
/* */
/* */
/* */
/* */
/* */
/* */
/* */ public static String j(Context paramContext)
/* */ {
/* 892 */ StringBuilder localStringBuilder = new StringBuilder();
/* */
/* 894 */ String str = ap.a(paramContext, "ro.genymotion.version");
/* 895 */ if (str != null) {
/* 896 */ localStringBuilder.append("ro.genymotion.version");
/* 897 */ localStringBuilder.append("|");
/* 898 */ localStringBuilder.append(str);
/* 899 */ localStringBuilder.append("\n");
/* */ }
/* */
/* 902 */ str = ap.a(paramContext, "androVM.vbox_dpi");
/* 903 */ if (str != null) {
/* 904 */ localStringBuilder.append("androVM.vbox_dpi");
/* 905 */ localStringBuilder.append("|");
/* 906 */ localStringBuilder.append(str);
/* 907 */ localStringBuilder.append("\n");
/* */ }
/* */
/* 910 */ str = ap.a(paramContext, "qemu.sf.fake_camera");
/* 911 */ if (str != null) {
/* 912 */ localStringBuilder.append("qemu.sf.fake_camera");
/* 913 */ localStringBuilder.append("|");
/* 914 */ localStringBuilder.append(str);
/* */ }
/* 916 */ return localStringBuilder.toString();
/* */ }
/* */
/* 919 */ private static String a = null;
/* 920 */ private static String b = null;
/* */
/* */
/* */
/* */
/* */
/* */
/* */ public static String k(Context paramContext)
/* */ {
/* 929 */ StringBuilder localStringBuilder = new StringBuilder();
/* */
/* 931 */ if (a == null) {
/* 932 */ a = ap.a(paramContext, "ro.secure");
/* */ }
/* 934 */ if (a != null) {
/* 935 */ localStringBuilder.append("ro.secure");
/* 936 */ localStringBuilder.append("|");
/* 937 */ localStringBuilder.append(a);
/* 938 */ localStringBuilder.append("\n");
/* */ }
/* */
/* 941 */ if (b == null) {
/* 942 */ b = ap.a(paramContext, "ro.debuggable");
/* */ }
/* 944 */ if (b != null) {
/* 945 */ localStringBuilder.append("ro.debuggable");
/* 946 */ localStringBuilder.append("|");
/* 947 */ localStringBuilder.append(b);
/* 948 */ localStringBuilder.append("\n");
/* */ }
/* 950 */ BufferedReader localBufferedReader = null;
/* */ try
/* */ {
/* 953 */ localBufferedReader = new BufferedReader(new FileReader("/proc/self/status"));
/* 954 */ String str1 = null;
/* 955 */ while ((str1 = localBufferedReader.readLine()) != null) {
/* 956 */ if (str1.startsWith("TracerPid:")) {
/* */ break;
/* */ }
/* */ }
/* 960 */ if (str1 != null) {
/* 961 */ str1 = str1.substring("TracerPid:".length()).trim();
/* 962 */ localStringBuilder.append("tracer_pid");
/* 963 */ localStringBuilder.append("|");
/* 964 */ localStringBuilder.append(str1);
/* */ }
/* 966 */ return localStringBuilder.toString();
/* */ } catch (Throwable localThrowable) {
/* 968 */ an.a(localThrowable);
/* */ } finally {
/* 970 */ if (localBufferedReader != null) {
/* */ try {
/* 972 */ localBufferedReader.close();
/* */ } catch (IOException localIOException3) {
/* 974 */ an.a(localIOException3);
/* */ }
/* */ }
/* */ }
/* 978 */ return localStringBuilder.toString();
/* */ }
/* */
/* */
/* */
/* */
/* */
/* */
/* */ public static String l(Context paramContext)
/* */ {
/* 988 */ localStringBuilder = new StringBuilder();
/* 989 */ BufferedReader localBufferedReader = null;
/* */ try { String str;
/* 991 */ if (new File("/sys/class/power_supply/ac/online").exists())
/* */ {
/* 993 */ localBufferedReader = new BufferedReader(new FileReader("/sys/class/power_supply/ac/online"));
/* 994 */ str = localBufferedReader.readLine();
/* 995 */ if (str != null) {
/* 996 */ localStringBuilder.append("ac_online");
/* 997 */ localStringBuilder.append("|");
/* 998 */ localStringBuilder.append(str);
/* */ }
/* 1000 */ localBufferedReader.close();
/* */ }
/* 1002 */ localStringBuilder.append("\n");
/* 1003 */ if (new File("/sys/class/power_supply/usb/online").exists())
/* */ {
/* 1005 */ localBufferedReader = new BufferedReader(new FileReader("/sys/class/power_supply/usb/online"));
/* 1006 */ str = localBufferedReader.readLine();
/* 1007 */ if (str != null) {
/* 1008 */ localStringBuilder.append("usb_online");
/* 1009 */ localStringBuilder.append("|");
/* 1010 */ localStringBuilder.append(str);
/* */ }
/* 1012 */ localBufferedReader.close();
/* */ }
/* 1014 */ localStringBuilder.append("\n");
/* 1015 */ if (new File("/sys/class/power_supply/battery/capacity").exists())
/* */ {
/* 1017 */ localBufferedReader = new BufferedReader(new FileReader("/sys/class/power_supply/battery/capacity"));
/* */
/* 1019 */ str = localBufferedReader.readLine();
/* 1020 */ if (str != null) {
/* 1021 */ localStringBuilder.append("battery_capacity");
/* 1022 */ localStringBuilder.append("|");
/* 1023 */ localStringBuilder.append(str);
/* */ }
/* 1025 */ localBufferedReader.close();
/* */ }
/* */
/* */
/* */
/* */
/* */
/* */
/* */
/* */
/* */
/* */
/* */
/* 1038 */ return localStringBuilder.toString();
/* */ }
/* */ catch (Throwable localThrowable) {}finally
/* */ {
/* 1030 */ if (localBufferedReader != null) {
/* */ try {
/* 1032 */ localBufferedReader.close();
/* */ } catch (IOException localIOException3) {
/* 1034 */ an.a(localIOException3);
/* */ }
/* */ }
/* */ }
/* */ }
/* */
/* */
/* */
/* */
/* */
/* */
/* */
/* */ public static String m(Context paramContext)
/* */ {
/* 1048 */ StringBuilder localStringBuilder = new StringBuilder();
/* */
/* 1050 */ String str = ap.a(paramContext, "gsm.sim.state");
/* 1051 */ if (str != null) {
/* 1052 */ localStringBuilder.append("gsm.sim.state");
/* 1053 */ localStringBuilder.append("|");
/* 1054 */ localStringBuilder.append(str);
/* */ }
/* 1056 */ localStringBuilder.append("\n");
/* */
/* 1058 */ str = ap.a(paramContext, "gsm.sim.state2");
/* 1059 */ if (str != null) {
/* 1060 */ localStringBuilder.append("gsm.sim.state2");
/* 1061 */ localStringBuilder.append("|");
/* 1062 */ localStringBuilder.append(str);
/* */ }
/* 1064 */ return localStringBuilder.toString();
/* */ }
/* */
/* */
/* */
/* */
/* */
/* */
/* */ public static long n(Context paramContext)
/* */ {
/* 1074 */ f = 0.0F;
/* 1075 */ BufferedReader localBufferedReader = null;
/* */ try
/* */ {
/* 1078 */ localBufferedReader = new BufferedReader(new FileReader("/proc/uptime"));
/* 1079 */ String str1 = localBufferedReader.readLine();
/* 1080 */ if (str1 != null) {
/* 1081 */ String str2 = str1.split(" ")[0];
/* 1082 */ f = (float)(System.currentTimeMillis() / 1000L) - Float.parseFloat(str2);
/* */ }
/* */
/* */
/* */
/* */
/* */
/* */
/* */
/* */
/* */
/* */
/* */
/* 1095 */ return f;
/* */ }
/* */ catch (Throwable localThrowable)
/* */ {
/* 1085 */ an.a(localThrowable);
/* */ } finally {
/* 1087 */ if (localBufferedReader != null) {
/* */ try {
/* 1089 */ localBufferedReader.close();
/* */ } catch (IOException localIOException3) {
/* 1091 */ an.a(localIOException3);
/* */ }
/* */ }
/* */ }
/* */ }
/* */ }
/* Location: C:\Users\lin\Desktop\classes.jar!\com\tencent\bugly\crashreport\common\info\b.class
* Java compiler version: 7 (51.0)
* JD-Core Version: 0.7.1
*/