في منتدى t u t s 4 y o u رأيت منذ فترة طويلة أن المستخدمين تحدثوا عن هذا البرنامج وأعطوا بعض التوضيحات، لكن بعد محاولات عديدة لم أتمكن بعد من النجاح.
لقد وجدت الدالة التالية في x32dbg التي تحتوي على القيم التالية:
01137AA2 | 8B47 54 | mov eax,dword ptr ds:[edi+54] |
01137AA5 | 99 | cdq |
01137AA6 | F77D E8 | idiv dword ptr ss:[ebp-18] |
01137AA9 | 8B45 0C | mov eax,dword ptr ss:[ebp+C] |
01137AAC | 32D1 | xor dl,cl | this is the next XOR key
01137AAE | 8B4D F0 | mov ecx,dword ptr ss:[ebp-10] |
01137AB1 | 301403 | xor byte ptr ds:[ebx+eax],dl | this decrypts data
01137AB4 | 43 | inc ebx |
01137AB5 | FF47 54 | inc dword ptr ds:[edi+54] |
01137AB8 | 3BD9 | cmp ebx,ecx |
01137ABA | 7C 84 | jl spotplayer.1137A40 |
بعد فترة من التحليل، عند العنوان:
01137AB1 | 301403 | xor byte ptr ds:[ebx+eax],dl
كانت قيم EDX للفيديو الذي اختبرته كالتالي:
تتغير قيمة Cl في EDX التالي بالتتابع. القيم الابتدائية التي تبدأ من 00000000 هي أيضًا عداد موجود في EBX، لكنني قمت بفحص فقط إلى القيمة 00000050، ولم أتمكن من فهم الكثير أو بالأحرى لم أتمكن من اكتشاف كيفية عمل خوارزمية تشفير هذه الفيديوهات، فقط أريد خوارزمية هذا التشفير:
EDX = 00000000 => 0000009A
EDX = 00000001 => 000000A7
EDX = 00000002 => 000000D8
EDX = 00000003 => 0000001F
EDX = 00000004 => 00000077
EDX = 00000005 => 000000EF
EDX = 00000006 => 000000B1
EDX = 00000007 => 00000052
EDX = 00000008 => 00000093
EDX = 00000009 => 00000097
EDX = 0000000A => 00000035
EDX = 0000000B => 000000D7
EDX = 0000000C => 00000019
EDX = 0000000D => 0000009E
EDX = 0000000E => 000000E8
EDX = 0000000F => 00000097
EDX = 00000010 => 00000050
EDX = 00000011 => 000000F1
EDX = 00000012 => 000000B8
EDX = 00000013 => 000000E5
EDX = 00000014 => 000000DC
EDX = 00000015 => 00000006
EDX = 00000016 => 0000007B
EDX = 00000017 => 00000098
EDX = 00000018 => 00000008
EDX = 00000019 => 000000FF
EDX = 0000001A => 000000A4
EDX = 0000001B => 00000095
EDX = 0000001C => 00000052
EDX = 0000001D => 00000036
EDX = 0000001E => 00000062
EDX = 0000001F => 000000B4
EDX = 00000020 => 0000004C
EDX = 00000021 => 00000071
EDX = 00000022 => 000000F8
EDX = 00000023 => 00000092
EDX = 00000024 => 0000001F
EDX = 00000025 => 0000009D
EDX = 00000026 => 000000D4
EDX = 00000027 => 00000075
EDX = 00000028 => 00000045
EDX = 00000029 => 000000A2
EDX = 0000002A => 00000094
EDX = 0000002B => 00000031
EDX = 0000002C => 00000038
EDX = 0000002D => 000000FE
EDX = 0000002E => 0000000C
EDX = 0000002F => 0000007D
EDX = 00000030 => 00000087
EDX = 00000031 => 000000DB
EDX = 00000032 => 0000005E
EDX = 00000033 => 000000CE
EDX = 00000034 => 0000005A
EDX = 00000035 => 000000DB
EDX = 00000036 => 00000093
EDX = 00000037 => 0000007D
EDX = 00000038 => 000000D5
EDX = 00000039 => 000000E3
EDX = 0000003A => 00000076
EDX = 0000003B => 0000004B
EDX = 0000003C => 000000F1
EDX = 0000003D => 0000007F
EDX = 0000003E => 000000D6
EDX = 0000003F => 0000008F
EDX = 00000040 => 000000E8
EDX = 00000041 => 000000D0
EDX = 00000042 => 00000097
EDX = 00000043 => 0000002A
EDX = 00000044 => 00000068
EDX = 00000045 => 000000D6
EDX = 00000046 => 00000037
EDX = 00000047 => 00000060
EDX = 00000048 => 000000B6
EDX = 00000049 => 00000088
EDX = 0000004A => 000000F1
EDX = 0000004B => 000000B4
EDX = 0000004C => 0000004D
EDX = 0000004D => 000000DA
EDX = 0000004E => 00000091
EDX = 0000004F => 000000FE
EDX = 00000050 => 000000B2
إليكم هذا الاقتباس من نفس التوضيحات من منتدى
T u t s 4 Y o u للأصدقاء الذين لا يملكون حسابًا هناك أو لا يرغبون في التسجيل في ذلك المنتدى:
@
h 4 s h 3 m is right, the buffer is 128kb.
![[صورة مرفقة: default_smile.png]](https://forum.tuts4you.com/uploads/emoticons/default_smile.png)
Encryption is simple XOR with 127byte key, file headers are slightly mangled but overall it's a quite simple "protection".
Decryption key is located in the first few bytes of the .spot file.
Easiest way seems to be - put breakpoints on CreateFile/ReadFile, wait until .spot file is being read, and then see what's being done with the data. You should land somewhere in this function (address 04A4830) and see this code decrypting data:
.text:004A4AEF 8B 47 64 mov eax, [edi+64h]
.text:004A4AF2 99 cdq
.text:004A4AF3 F7 7D E8 idiv [ebp+var_18]
.text:004A4AF6 8B 45 0C mov eax, [ebp+arg_4_buffer]
.text:004A4AF9 32 D1 xor dl, cl ;------ this is the next XOR key
.text:004A4AFB B9 7F 00 00 00 mov ecx, 7Fh
.text:004A4B00 30 14 03 xor [ebx+eax], dl ;<----- this decrypts data
.text:004A4B03 43 inc ebx
.text:004A4B04 FF 47 64 inc dword ptr [edi+64h]
.text:004A4B07 8B 47 64 mov eax, [edi+64h]
.text:004A4B0A 3B 5D F0 cmp ebx, [ebp+buffer_size]
.text:004A4B0D 7C 84 jl short loop_xor_all_bytes
and the decryption key begins with bytes
4D 8C D5 4D F5 ....
I believe that's all you need to know to be able to create your own tool to decrypt your videos.
EDIT#2: in case you are using 64-bit version of the player, I believe this is the place where data are being decrypted:
.text:00000001400B5910 69 C2 FB 00 00 00 imul eax, edx, 0FBh
.text:00000001400B5916 2B C8 sub ecx, eax
.text:00000001400B5918 41 32 C8 xor cl, r8b <--- calculate next XOR key
.text:00000001400B591B 41 30 0F xor [r15], cl <--- decrypt next byte