Java code for Android applications that check black list during start: /** * Determines status of device's IMEI. * * @return -1 - imei status retrieval failed. * 0 - Green status * 1 to 3 - Yellow status * 3 to 5 - Brown status * above 5 - Red status */ public int getIMEIStatus() { // 1. Get device ID TelephonyManager manager = (TelephonyManager)getSystemService (Context.TELEPHONY_SERVICE); String sDeviceID = manager.getDeviceId(); // 2. Fetch for IMEI data. // Will look like // http://www.artfulbits.com/android/antipiracycheck.ashx?IMEI=123456789123456 String url = "http://www.artfulbits.com/ab/android/ antipiracycheck.ashx?IMEI=" + sDeviceID; // Server will return 200 if request post was successful. int http_ok = 200; // Create new http client. HttpClient client = new DefaultHttpClient(); // Create new http post. HttpPost post = new HttpPost(url); // Cache http response. HttpResponse response = null; // Will return -1 unless server provides its own value. int imeiStatus = -1; try { // Executind post. response = client.execute(post); // Making sure we've received correct status code. if(response.getStatusLine().getStatusCode() == http_ok) { // Retrieving content stream. InputStream stream = response.getEntity().getContent(); // Decorating stream with Input stream reader InputStreamReader isr = new InputStreamReader(stream); // Decorating input stream reader with buffered stream reader. BufferedReader reader = new BufferedReader(isr); // Reading imei status from stream. imeiStatus = Integer.parseInt(reader.readLine()); // Closing buffered reader will recursively close decorated input stream // reader and input stream. reader.close(); } } catch(Exception e) { e.printStackTrace(); } return imeiStatus; }
On Nov 16, 4:03 pm, Abdul Mateen <abmat...@gmail.com> wrote: > Well! to be honest, Google is supporting piracy at all , All the software > engineers in Google working under Android project know about the internals > of Linux working, its user level structure, permission structures, what they > did , is allow behind a transparent curtain the piracy. > Google could have made some anti-piracy right from day one!, see they have > protected their "Android Market application". Engineers know about that > there are palenty of hackers out there ( Linux hackers) who can in very few > days hack the whole operating system.Yet! they know every details, but they > have not done measures for anti-piracy because they want piracy! Engineers > at Google? can you clearify these points, Even I having only 8 years of > Linux experience modified the phone with root, and after that no security > means to me!. I repeat * IF THE ENGINEERS AT GOOGLE JUST WANTED AND WORKED > ON ANTI-PIRACY THEY COULD HAVE CHANGED THE WORLD OF SOFTWARE PIRACY BECAUSE > ANDROID AS A PLATFORM IS AMAZING BUT THE POLITICS LIKE THIS BEHIND THE SCENE > IS WORST AND MUST BE STOPPED." , I do not know what for this politics is, > but clearly they could have made very powerful measures against Anti-piracy, > Microsoft is suffered alot with piracy, but they have taken good steps > against anti-piracy for Windows Mobile Marketplace, and I doubt they will > win the game over Google Android Market, but still will not win Apple's App > Store. > > I see only one solution to this, *IF google does not take any initiative* is > that all the vendors should support the alternative markets out there like > AndAppstore to become succesfull instead of Android Market. They listen and > accept the contributions, but Google does not listen or accept any > contributions. > > Thank You, > Abdul Mateen. > > > > On Mon, Nov 16, 2009 at 6:12 AM, AlexK <kucherenko.a...@gmail.com> wrote: > > Our company starts today anti-piracy initiative against piracy that > > already happened on Android Market. We request all vendors and > > developers to support this initiative. > > > Piracy become a threat for vendors that publishing application on > > Android Market! It is not a joke, it is a real threat. > > > Our last application publishing shows how bad is situation on the > > Android Market. Only 20% of all installs are legal, other 80% are in > > piracy hands. > > > Google does not provide any actions to stop piracy, so we as a vendor > > that provide software for Android Market, have to think about > > protection measures. Piracy is threat that cannot be target easily and > > eliminated in one day. Only join of all vendors can help in anti- > > piracy. > > > ArtfulBits company decide to start from today "Android Anti-piracy > > Movement" with main goal: "protect vendors and punish piracy". > > > Our next steps are: > > - Petition to Google with request to provide better anti-piracy > > protocols for Android Market; > > - Collective anti-Google charge, from side of vendors that loose money > > due to Google "security holes" in Android Market application > > distribution channel; > > - Public web service "Black List", that helps all developer to check > > is there application installed on pirate phone; > > - Joining of the software vendors over that problem for finding better > > anti-piracy strategies; > > - Identification of the roots of piracy, that make possible Android > > Market software leaking and contribution them to justice. > > > A little later today we will open "black-list" database of devices, > > where was installed stolen version of applications. In addition, we > > will provide "easy code" for all developers that can be integrated > > into own application and during first start, check is phone in "black > > list" or not. > > > Opened Anti-Piracy forum thread:http://www.artfulbits.com/Support > > Petition can be signed here: > >http://www.petitionspot.com/petitions/androidpiracy > > > Stay tuned! Thanks. > > > -- > > You received this message because you are subscribed to the Google > > Groups "Android Developers" group. > > To post to this group, send email to android-developers@googlegroups.com > > To unsubscribe from this group, send email to > > android-developers+unsubscr...@googlegroups.com<android-developers%2Bunsubs > > cr...@googlegroups.com> > > For more options, visit this group at > >http://groups.google.com/group/android-developers?hl=en -- You received this message because you are subscribed to the Google Groups "Android Developers" group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en