johndoe1
07-30-2002, 01:09
http://www.arceauowkm.home.ro/dct4.zip <-----
100% working with fbus cable, thnx guys!
It`s working, but with MBUS cable
:D :D :D
I kept clicking lots and got there eventually
Hi
Try right click and save target as.....
B.R
here it is http://groups.yahoo.com/group/GSM_ads/files/Nokia/source_code.exe
good luck guys ;)
@serge
ur soft have problem
you must be referring to the source code. You need to compile it...
@serge what software do i use to read the source... im a newbee on this area..
You don't need the source code. Just download the ready made program and enjoy freedom ;)
Reinventing the wheel I suppose... but the info it contains is so essential for the next surprises...
datalife2000
07-30-2002, 23:04
Is this using Mbus or Fbus ? :)
Use mbus cable with your phone in test mode on display.
xfarenheitx
07-31-2002, 04:07
Why isn't there a unit MBUS_Constants? I thought all the source code was there?
Regards
FH
@xfarenheitx
This was posted by LEGIJA on the other thread... thanks to LEGIJA!
... and davieb said on that thread that soure code was written by deplhi/object-pascal!... thanks to davieb
unit algounit_dct4;
interface
uses MBUS_Constants;
type
Array8= array[0..7] of byte;
var
MirrorRecdIMEI, Calced8Bytes, RecdIMEI, XOREncodedIMEI: array8;
Lookup1Cntr, RollOver1, RollOver2: byte;
const
{$I maskarr.inc} //maskarray
{$I tblook1.inc}
{$I tblook2.inc}
{$I tblook3.inc}
DecodeIMEIMask:array8=($4A,$33,$78,$90,$11,$AF,$F2
,$3C);
EncodeIMEIMask:array8=($30,$49,$02,$EA,$6B,$D5,$88
,$46);
BitsOrder:array[0..16] of byte=(0,3,6,1,4,7,2,5,0,3,6,1,4,7,2,5,0);
procedure dct4_CalcSP(SomeImei: string; var SLMatrix: TSLMatrix);
implementation
procedure XORIMEI(Mask,SourceImei: array8; var DestIMEI: array8);
var f: integer;
a: byte;
begin
for f:=0 to 7 do begin
a:=Mask[f];
DestIMEI[f]:=SourceIMEI[f] xor a;
end;
end;
procedure MaskIMEI(var SomeRollOver: byte; Idx: integer; SomeMirror: array8; var DestIMEI: array8);
var f,g: integer;
a: byte;
begin
g:=0;
for f:=Idx to (Idx+7) do begin
a:=MaskArray[f] xor $FF;
inc(SomeRollOver,a);
DestIMEI[g]:=SomeMirror[g] xor a;
inc(g);
end;
end;
function Lookup1(var Counter: byte; SomeXorEncodedIMEI: array8):byte;
var a,R0,R6,R7: byte;
f: integer;
begin
Lookup1:=0;
if Counter>136 then exit;
R6:=Counter;a:=R6;
inc(Counter);
a:=a and 7;
a:=SomeXOREncodedIMEI[a];
R7:=a;
a:=R6;
//a:=(a shr 3) and $1F;
asm
push ax
mov al,a
rcr al,1
rcr al,1
rcr al,1
and al,$1F
mov a,al
pop ax
end;
a:=BitsOrder[a];
R0:=a;
a:=R7;
//inc(R0);
for f:=1 to R0 do begin
asm
push ax
mov al,a
rol al,1
mov a, al
pop ax
end;
end;
R7:=a;
a:=R6;
a:=TblLookup3[a] xor $FF;
inc(a,R7);
R7:=a;
Lookup1:=R7;
end;
procedure Calc_1(SomeXorEncodedIMEI: array8; var DestIMEI: array8);
var
f: integer;
LookUpCtr: byte;
a,b: byte;
begin
LookupCtr:=0;
for f:=0 to 7 do begin
//no-lookup operations here
a:=lookup1(LookUpCtr,SomeXorEncodedIMEI);
DestIMEI[0]:=DestIMEI[0] xor a;
a:=lookup1(LookUpCtr,SomeXorEncodedIMEI);
DestIMEI[1]:=DestIMEI[1] + a;
a:=lookup1(LookUpCtr,SomeXorEncodedIMEI);
DestIMEI[2]:=DestIMEI[2] + a;
a:=lookup1(LookUpCtr,SomeXorEncodedIMEI);
DestIMEI[3]:=DestIMEI[3] xor a;
a:=lookup1(LookUpCtr,SomeXorEncodedIMEI);
DestIMEI[4]:=DestIMEI[4] xor a;
a:=lookup1(LookUpCtr,SomeXorEncodedIMEI);
DestIMEI[5]:=DestIMEI[5] + a;
a:=lookup1(LookUpCtr,SomeXorEncodedIMEI);
DestIMEI[6]:=DestIMEI[6] + a;
a:=lookup1(LookUpCtr,SomeXorEncodedIMEI);
DestIMEI[7]:=DestIMEI[7] xor a;
//Lookup operations here
a:=lookup1(LookUpCtr,SomeXorEncodedIMEI);
b:=TblLookup1[DestIMEI[0]] xor $FF;
DestIMEI[0]:=b+a;
a:=lookup1(LookUpCtr,SomeXorEncodedIMEI);
b:=TblLookup2[DestIMEI[1]] xor $FF;
DestIMEI[1]:=b xor a;
a:=lookup1(LookUpCtr,SomeXorEncodedIMEI);
b:=TblLookup2[DestIMEI[2]] xor $FF;
DestIMEI[2]:=b xor a;
a:=lookup1(LookUpCtr,SomeXorEncodedIMEI);
b:=TblLookup1[DestIMEI[3]] xor $FF;
DestIMEI[3]:=b+a;
a:=lookup1(LookUpCtr,SomeXorEncodedIMEI);
b:=TblLookup1[DestIMEI[4]] xor $FF;
DestIMEI[4]:=b+a;
a:=lookup1(LookUpCtr,SomeXorEncodedIMEI);
b:=TblLookup2[DestIMEI[5]] xor $FF;
DestIMEI[5]:=b xor a;
a:=lookup1(LookUpCtr,SomeXorEncodedIMEI);
b:=TblLookup2[DestIMEI[6]] xor $FF;
DestIMEI[6]:=b xor a;
a:=lookup1(LookUpCtr,SomeXorEncodedIMEI);
b:=TblLookup1[DestIMEI[7]] xor $FF;
DestIMEI[7]:=b+a;
//Permutations here
a:=DestIMEI[0]; //perm 1
inc(a,DestIMEI[1]);
DestIMEI[1]:=a;
inc(a,DestIMEI[0]);
DestIMEI[0]:=a;
a:=DestIMEI[2]; //perm 2
inc(a,DestIMEI[3]);
DestIMEI[3]:=a;
inc(a,DestIMEI[2]);
DestIMEI[2]:=a;
a:=DestIMEI[4]; //perm 3
inc(a,DestIMEI[5]);
DestIMEI[5]:=a;
inc(a,DestIMEI[4]);
DestIMEI[4]:=a;
a:=DestIMEI[6]; //perm 4
inc(a,DestIMEI[7]);
DestIMEI[7]:=a;
inc(a,DestIMEI[6]);
DestIMEI[6]:=a;
a:=DestIMEI[0]; //perm 5
inc(a,DestIMEI[2]);
DestIMEI[2]:=a;
inc(a,DestIMEI[0]);
DestIMEI[0]:=a;
a:=DestIMEI[4]; //perm 6
inc(a,DestIMEI[6]);
DestIMEI[6]:=a;
inc(a,DestIMEI[4]);
DestIMEI[4]:=a;
a:=DestIMEI[1]; //perm 7
inc(a,DestIMEI[3]);
DestIMEI[3]:=a;
inc(a,DestIMEI[1]);
DestIMEI[1]:=a;
a:=DestIMEI[5]; //perm 8
inc(a,DestIMEI[7]);
DestIMEI[7]:=a;
inc(a,DestIMEI[5]);
DestIMEI[5]:=a;
a:=DestIMEI[0]; //perm 9
inc(a,DestIMEI[4]);
DestIMEI[4]:=a;
inc(a,DestIMEI[0]);
DestIMEI[0]:=a;
a:=DestIMEI[1]; //perm 10
inc(a,DestIMEI[5]);
DestIMEI[5]:=a;
inc(a,DestIMEI[1]);
DestIMEI[1]:=a;
a:=DestIMEI[2]; //perm 11
inc(a,DestIMEI[6]);
DestIMEI[6]:=a;
inc(a,DestIMEI[2]);
DestIMEI[2]:=a;
a:=DestIMEI[3]; //perm 12
inc(a,DestIMEI[7]);
DestIMEI[7]:=a;
inc(a,DestIMEI[3]);
DestIMEI[3]:=a;
//Final swap //perm 13
a:=DestIMEI[1];
DestIMEI[1]:=DestIMEI[4];
DestIMEI[4]:=DestIMEI[2];
DestIMEI[2]:=a;
a:=DestIMEI[3];
DestIMEI[3]:=DestIMEI[5];
DestIMEI[5]:=DestIMEI[6];
DestIMEI[6]:=a;
end;
a:=lookup1(LookUpCtr,SomeXorEncodedIMEI);
DestIMEI[0]:=DestIMEI[0] xor a;
a:=lookup1(LookUpCtr,SomeXorEncodedIMEI);
DestIMEI[1]:=DestIMEI[1] + a;
a:=lookup1(LookUpCtr,SomeXorEncodedIMEI);
DestIMEI[2]:=DestIMEI[2] + a;
a:=lookup1(LookUpCtr,SomeXorEncodedIMEI);
DestIMEI[3]:=DestIMEI[3] xor a;
a:=lookup1(LookUpCtr,SomeXorEncodedIMEI);
DestIMEI[4]:=DestIMEI[4] xor a;
a:=lookup1(LookUpCtr,SomeXorEncodedIMEI);
DestIMEI[5]:=DestIMEI[5] + a;
a:=lookup1(LookUpCtr,SomeXorEncodedIMEI);
DestIMEI[6]:=DestIMEI[6] + a;
a:=lookup1(LookUpCtr,SomeXorEncodedIMEI);
DestIMEI[7]:=DestIMEI[7] xor a;
end;
function Hex2int(Digit: Char): byte;
var b: byte;
c: char;
begin
c:=Digit;
b:=ord(c);
if (b<=$39) and (b>=$30) then b:=b-$30
else
b:=b-$41+10;
Hex2Int:=b;
end;
procedure dct4_CalcSP(SomeImei: string; var SLMatrix: TSLMatrix);
var
f,g,h: integer;
a,b: byte;
begin
f:=0;g:=0;
FillChar(SLMatrix,SizeOf(SLMatrix),0);
repeat
a:=(Hex2Int(SomeIMEI[f+1]))*16;
b:=Hex2Int(SomeIMEI[f+2]);
RecdIMEI[g]:=a + b;
inc(f,2);
inc(g);
until f=14;
RecdIMEI[7]:=$00;
for f:=0 to 7 do MirrorRecdIMEI[f]:=0; //Initialize mirror array
XORIMEI(DecodeIMEIMask,RecdIMEI,XOREncodedIMEI); //calculate XOR Encoded IMEI
RollOver1:=0; RollOver2:=0; //init CRC counters
f:=0;
repeat
MaskIMEI(RollOver1, f, MirrorRecdIMEI, Calced8Bytes);
Calc_1(XorEncodedIMEI, Calced8Bytes);
h:=0;
for g:=f to (f+7) do begin
a:=Calced8Bytes[h];
mirrorrecdimei[h]:=a;
SLMatrix[g]:=a; inc(h);
inc(RollOver2,a);
end;
inc(f,8);
until f=$3a0;
//Here calculation of verification data
Calced8Bytes[0]:=RollOver1;
Calced8Bytes[1]:=not RollOver1;
Calced8Bytes[2]:=RollOver2;
Calced8Bytes[3]:=not RollOver2;
Calced8Bytes[4]:=$5B;
Calced8Bytes[5]:=$72;
Calced8Bytes[6]:=$AE;
Calced8Bytes[7]:=$36;
XORIMEI(EncodeIMEIMask,RecdIMEI,XOREncodedIMEI);
Calc_1(XorEncodedIMEI, Calced8Bytes);
for f:=$3a0 to $3a7 do SLMatrix[f]:=Calced8Bytes[f-$3a0];
end;
end.
cheers
BR
;) ;) ;) :D
This unlocker prog connect to the internet?
djmarcuz
07-31-2002, 16:06
somebody tested it on other phones as 8310?
8310 works to me, but other phones i can't unlock with this tool!
somebody can help me further?
xfarenheitx
07-31-2002, 19:45
@Chryse,
I already know that,
It just wont compile... Its looking for a unit called Mbus_Constants!
By the way where is that thread by Legija?
regards
FH
@xfarenheitx
here...
http://forum.gsmhosting.com/vbb/showthread.php?s=&threadid=51208
BR
xfarenheitx
07-31-2002, 20:29
Thats obviously the source code cut & pasted from 'AlgoUnitDct4.pas'.. I wonder why the thread was deleted..
Doesn't make sense.
DavieB is right' and good luck to TechTron.. all we need is the Mbus Commands.
The Q is will we get those? :D
Regards
FH