GSM-Forum

GSM-Forum (https://forum.gsmhosting.com/vbb/)
-   GSM Programming & Reverse Engineering (https://forum.gsmhosting.com/vbb/f83/)
-   -   ALGO for zte unlock (https://forum.gsmhosting.com/vbb/f83/algo-zte-unlock-984385/)

v4mpire 04-23-2010 16:52

ALGO for zte unlock
 
hi to all :
algo for zte unlocking here :
PHP Code:

import hashlibgetoptsys

magic 
= [688950000000]


def usage():
    print 
"Options: -i*, --imei=*      IMEI of the device"
    
print ""
    
print "Example: zte-unlock.txt --imei=351234567891239"
    
print ""

def testIME******sum(digits):
    
_sum 0
    alt 
False
    
for d in reversed(digits):
        
assert 0 <= <= 9
        
if alt:
            
*= 2
        
if 9:
            
-= 9
        _sum 
+= d
        alt 
not alt
    
return (_sum 10) == 0

def checkIMEI
(imei):
    
digits = []
    if 
len(imei) != 15:
        print 
"IMEI too short/long"
        
return False
    
for i in imei:
        
digits.append(int(i))
    if 
not testIME******sum(digits):
        print 
"IMEI checksum invalid"
        
return False
    
return True

def getCode
(imei):
    
digits = []
    
nck ""
    
spck ""
    
crosssum 0
    
for i in imei[3:15]:
        
digits.append(int(i))
    for 
i in digits:
        
crosssum += i
    
for i in range(0,len(digits)):
        
code = (digits[i]*crosssum digits[11-i]*magic[i]) % 10
        nck 
+= "%d" code
        spck 
+= "%d" % ((code digits[11-i]) % 10)
    return (
nckspck)

def main():
    
info()
        try:   
                
optsargs getopt.getopt(sys.argv[1:], "hi:", ["help""imei="])
        
except getopt.GetoptErrorerr:
                print 
str(err# will print something like "option -a not recognized"
                
usage()
                
sys.exit(2)

    
imei ""
    
interactive False

        
for oa in opts:
                if 
o in ("-i""--imei"):
                        
imei a
                elif o in 
("-h""--help"):
                        
usage()
                        
sys.exit()

    if 
imei == "":
        
imei raw_input("Please enter the IMEI of the device:  ")
        
interactive True

    
if checkIMEI(imei):
        
nckspck getCode(imei)
        print 
""
        
print "Network Control Key (NCK):            " nck
        
print "Service Provider Control Key (SPCK):  " spck
        
print "done."

    
if interactive:
        
raw_input()
    
if 
__name__ == "__main__":
    
main() 

Br v4mpire

mustipusti 04-23-2010 16:55

Quote:

Originally Posted by v4mpire (Post 5753900)
hi to all :
algo for zte unlocking here :
PHP Code:

import hashlibgetoptsys

magic 
= [688950000000]


def usage():
    print 
"Options: -i*, --imei=*      IMEI of the device"
    
print ""
    
print "Example: zte-unlock.txt --imei=351234567891239"
    
print ""

def testIME******sum(digits):
    
_sum 0
    alt 
False
    
for d in reversed(digits):
        
assert 0 <= <= 9
        
if alt:
            
*= 2
        
if 9:
            
-= 9
        _sum 
+= d
        alt 
not alt
    
return (_sum 10) == 0

def checkIMEI
(imei):
    
digits = []
    if 
len(imei) != 15:
        print 
"IMEI too short/long"
        
return False
    
for i in imei:
        
digits.append(int(i))
    if 
not testIME******sum(digits):
        print 
"IMEI checksum invalid"
        
return False
    
return True

def getCode
(imei):
    
digits = []
    
nck ""
    
spck ""
    
crosssum 0
    
for i in imei[3:15]:
        
digits.append(int(i))
    for 
i in digits:
        
crosssum += i
    
for i in range(0,len(digits)):
        
code = (digits[i]*crosssum digits[11-i]*magic[i]) % 10
        nck 
+= "%d" code
        spck 
+= "%d" % ((code digits[11-i]) % 10)
    return (
nckspck)

def main():
    
info()
        try:   
                
optsargs getopt.getopt(sys.argv[1:], "hi:", ["help""imei="])
        
except getopt.GetoptErrorerr:
                print 
str(err# will print something like "option -a not recognized"
                
usage()
                
sys.exit(2)

    
imei ""
    
interactive False

        
for oa in opts:
                if 
o in ("-i""--imei"):
                        
imei a
                elif o in 
("-h""--help"):
                        
usage()
                        
sys.exit()

    if 
imei == "":
        
imei raw_input("Please enter the IMEI of the device:  ")
        
interactive True

    
if checkIMEI(imei):
        
nckspck getCode(imei)
        print 
""
        
print "Network Control Key (NCK):            " nck
        
print "Service Provider Control Key (SPCK):  " spck
        
print "done."

    
if interactive:
        
raw_input()
    
if 
__name__ == "__main__":
    
main() 

Br v4mpire

For which ZTE's is this algo?

mouradsamsung 04-23-2010 16:58

if y have this code source in delphi please share it thanks

v4mpire 04-23-2010 16:59

check : http://forum.gsmhosting.com/vbb/f25/...ut-box-922573/

platforms 04-23-2010 17:10

Already discussed here still http://forum.gsmhosting.com/vbb/f83/...60-etc-943686/

angel25dz 04-23-2010 17:12

it's the same algo http://forum.gsmhosting.com/vbb/f83/...60-etc-943686/
:)

v4mpire 04-23-2010 17:23

ok i don't iknow if the algo already posted
soon i post more important algo

Br v4mpire;

angel25dz 04-23-2010 17:42

Quote:

Originally Posted by v4mpire (Post 5754013)
ok i don't iknow if the algo already posted
soon i post more important algo

Br v4mpire;

right, just explained :) i think u r the first hwo posted a source code....

ps: I coded it on C#, if someone need the source I can share it

./wbr

tampered 04-23-2010 21:08

how about the codes of your software, not the php :D

glad if you will share it

Ionel 04-23-2010 21:16

Post here is c++ please .

angel25dz 04-23-2010 21:31

here my code in c# (badly coded) u can optimize it by using functions !!

Code:

bool a = false;
            //ZTE
            //-----------------
            if (comboBox2.SelectedIndex == 0)
            {
                string imei = ""; char d = 'n'; int s1 = 0; int s2 = 0; int s3 = 0; int s = 0;
                string imei1 = ""; string stp1 = ""; string stp11 = ""; string stp2 = ""; string imei2 = "";
                string stp22 = ""; string stp222 = ""; string stp3 = ""; string NCK = ""; string SPCK = ""; string sp = "";
                string ml = "688950000000";
                imei = textBox1.Text;
                if (imei != "" & imei.Length == 15)
                {
                    for (int i = 0; i < 15; i++)
                    {
                        d = imei[i];
                        if (Char.IsDigit(d))
                        {
                            if (i > 2)
                            {
                                s1 = s1 + (int)(Char.GetNumericValue(d));
                                imei1 = imei1 + d;
                            }
                        }
                        else
                        {
                            MessageBox.Show(" Enter a valid imei");
                            richTextBox1.Text = "Enter a valid imei";
                            a = true; break;
                        }
                    }
                    if (a == false)
                    {
                        //1st & 2nd steps
                        for (int i = 0; i < 12; i++)
                        {
                            d = imei1[i];
                            s2 = s1 * ((int)(Char.GetNumericValue(d)));
                            s3 = 8 * ((int)(Char.GetNumericValue(d)));
                            stp11 = s2.ToString(); stp22 = s3.ToString();
                            stp1 = stp1 + stp11[(stp11.Length - 1)];
                            stp222 = stp222 + stp22[(stp22.Length - 1)];

                        }
                        for (int i = 0; i < 12; i++)
                        {
                            stp2 = stp2 + stp222[(11 - i)];
                        }
                        //3rd step
                        for (int i = 0; i < 12; i++)
                        {
                            s = (int)(char.GetNumericValue(stp1[i]) + Char.GetNumericValue(stp2[i])
                                + Char.GetNumericValue(ml[i]));
                            stp3 = s.ToString();
                            NCK = NCK + stp3[stp3.Length - 1];
                        }
                        //spck
                        for (int i = 0; i < 12; i++)
                        {
                            imei2 = imei2 + imei1[(11 - i)];
                            s1 = (int)(Char.GetNumericValue(imei2[i]) + Char.GetNumericValue(NCK[i]));
                            sp = s1.ToString();
                            SPCK = SPCK + sp[sp.Length - 1];
                        }
                        richTextBox1.Clear();
                        richTextBox1.SelectionColor = Color.PowderBlue;
                        richTextBox1.SelectedText = "ZTE NCK Calculator by ..::AnGeL25dZ::.."
                            +'\n'+"******************"
                            +'\n'+"imei: " + imei
                            + '\n' + "NCK:  " + NCK
                            + '\n' + "SPCK: " + SPCK
                            + '\n' + "******************"
                            +'\n'+"./ Done :-)";
                       
                    }

                }
                else
                {
                    MessageBox.Show(" Enter a valid imei");
                    richTextBox1.Text = "Enter a valid imei";
                }


orbita 04-23-2010 23:31

This algo is explained from begining to end in this forum.:D
Disponible in all languages, for all people, even if some don't know programing, can build.
Come with some new :D

v4mpire 04-24-2010 17:22

ALGO for zte unlock
 
Quote:

Originally Posted by angel25dz (Post 5754074)
right, just explained :) i think u r the first hwo posted a source code....

ps: I coded it on C#, if someone need the source I can share it

./wbr

WHT U HAVE MR DZ
all ur post ; juste u asking or need help


http://www.studentsoftheworld.info/s...%5D%5B1%5D.gif

mounir0020 04-24-2010 17:37

Yesssss in morocoo all programmed hir and sourss hir some product in the world

v4mpire 04-24-2010 17:53

ALGO for zte unlock
 
Quote:

Originally Posted by angel25dz (Post 5754074)
right, just explained :) i think u r the first hwo posted a source code....

ps: I coded it on C#, if someone need the source I can share it

./wbr

wht u know juste copie and paste !
wht u gived Free to the world gsm unlocking!
u are juste a copiers & pasters
http://www.studentsoftheworld.info/s...%5D%5B1%5D.gif


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


vBulletin Optimisation provided by vB Optimise (Pro) - vBulletin Mods & Addons Copyright © 2024 DragonByte Technologies Ltd.
- GSM Hosting Ltd. - 1999-2023 -

Page generated in 0.29419 seconds with 7 queries

SEO by vBSEO