Care Unlock  
Your online unlock store
GSM-Forum  

Welcome to the GSM-Forum forums.

You are currently viewing our boards as a guest which gives you limited access to view most discussions and access our other features. By joining our free community you will have access to post topics, communicate privately with other members (PM), respond to polls, upload content and access many other special features. Registration is fast, simple and absolutely free so please, join our community today!

If you have any problems with the registration process or your account login, please contact contact us.

Go Back   GSM-Forum > Other Gsm/Mobile Related Forums > GSM Programming & Reverse Engineering

GSM Programming & Reverse Engineering Here you can post all Kind of GSM Programming and Reverse Engineering tools and Secrets.

Reply
 
LinkBack Thread Tools Display Modes
Old 06-30-2012, 14:44   #1 (permalink)
No Life Poster
 
..::SuB::..'s Avatar
 
Join Date: Aug 2008
Location: The Matrix :)
Age: 25
Posts: 566
Member: 833760
Status: Online
Sonork: 100.1597150
Thanks: 156
Thanked 90 Times in 42 Posts
ZTE Blade Algo in PHP (need testing)

I've ported the well known ZTE algo from Delphi to PHP. I can't test it now because i dont have Blade in my hand (lol sounds weird like arrow in the knee

Code:
function zteCalc ($imei)
{
    $imeiMD5 = md5($imei);

    $tmp = str_split($imeiMD5, 2);
    
    for ($i = 0; $i <= 15; $i++)
    {
        $tmp[$i] = '0x'.$tmp[$i];    
    }


    $key = '';
    
    for ($i = 0; $i <= 7; $i++)
    {
        $key[$i] = ((($tmp[$i] + $tmp[$i+8]) & 0xFF)*9)/0xFF;        
        $key[$i] = (int)$key[$i];
    }
    $key = implode("",$key);

     return $key;
}
I want to extend this algo with the new one, still in progress. If somebody has it in any programming language and want to share so they are welcome.
  Reply With Quote
Old 07-03-2012, 08:51   #2 (permalink)
No Life Poster
 
..::SuB::..'s Avatar
 
Join Date: Aug 2008
Location: The Matrix :)
Age: 25
Posts: 566
Member: 833760
Status: Online
Sonork: 100.1597150
Thanks: 156
Thanked 90 Times in 42 Posts
Mates i have decompiled the Phone.apk and found the calCode function myself. Then tried to decompile a B04 rom but found the same function. What are the differences? Rather than i think i decompiled the wrong roms. Pelase If you have a ROM dump from a ZTE Blade which do not accepting the old code upload it to somewhere, i want to analyze it a bit.

Thanks in advance.

Code:
private String calCode(String paramString)
    throws NoSuchAlgorithmException
  {
    MessageDigest localMessageDigest = MessageDigest.getInstance("MD5");
    paramString.getBytes();
    paramString.length();
    localMessageDigest.update(paramString.getBytes(), 0, paramString.length());
    byte[] arrayOfByte1 = localMessageDigest.digest();
    for (int i = 0; i < 8; i++)
      arrayOfByte1[i] = (byte)((0xFF & arrayOfByte1[i]) + (0xFF & arrayOfByte1[(i + 8)]));
    byte[] arrayOfByte2 = new byte[8];
    for (int j = 0; j < 8; j++)
      arrayOfByte2[j] = (byte)(48 + 9 * (0xFF & arrayOfByte1[j]) / 255);
    return new String(arrayOfByte2);
  }
  Reply With Quote
Old 07-05-2012, 14:39   #3 (permalink)
No Life Poster
 
..::SuB::..'s Avatar
 
Join Date: Aug 2008
Location: The Matrix :)
Age: 25
Posts: 566
Member: 833760
Status: Online
Sonork: 100.1597150
Thanks: 156
Thanked 90 Times in 42 Posts
Solved B04 version:
Contact me if you need the algo.

Last edited by ..::SuB::..; 07-05-2012 at 14:45. Reason: Removed code.
  Reply With Quote
Reply

Bookmarks

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
thread Thread Starter Forum Replies Last Post
How to add a language in 51xx/61xx tati Nokia Legacy Phones ( DCT-1 , DCT-2 , DCT-3 , DCT-L ) 8 05-21-2013 19:20
Need software upgrade for Nokia 5110 ptkrf Nokia Legacy Phones ( DCT-1 , DCT-2 , DCT-3 , DCT-L ) 26 09-25-2012 02:41
needed pinout for carkit(N61xx) mobileinfo Nokia Hardware & Hardware-Repair Area 1 12-27-2006 10:20
need ericsson 88 cable migdamas Old Ericsson Phones & Sony Phones 1 06-02-1999 16:23
need eeprom photo???? mobileinfo Nokia Legacy Phones ( DCT-1 , DCT-2 , DCT-3 , DCT-L ) 0 05-26-1999 11:35


All times are GMT +1. The time now is 21:16.



Powered by Searchlight © 2013 Axivo Inc.
- GSM Hosting Ltd. - 1999-2013 -
Page generated in 0.23509 seconds with 11 queries

SEO by vBSEO