Function at 0x403940
Capabilities:
Read file on windows
Terminate process
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x134
mov eax, dword [0x42c004]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push esi
push edi
push str.Initialize__
mov dword [ebp - 0x128], 0
call fcn.00402d80
add esp, 4
call fcn.00403290
test eax, eax
jne 0x403996
push str.GetCryptoProvider_failed__
call fcn.00402d80
add esp, 4
xor eax, eax
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.004052f0
mov esp, ebp
pop ebp
ret
mov edx, 0x114
mov dword [ebp - 0x120], 0x206
lea ecx, [ebp - 0x120]
mov dword [ebp - 0x11c], 0xa400
mov dword [ebp - 0x118], 0x31415352
mov dword [ebp - 0x114], 0x800
mov dword [ebp - 0x110], 0x10001
mov dword [ebp - 0x10c], 0xfb5da58d
mov dword [ebp - 0x108], 0xd310ef74
mov dword [ebp - 0x104], 0xf7ca7e98
mov dword [ebp - 0x100], 0x1f9e8e98
mov dword [ebp - 0xfc], 0x7a6fedd8
mov dword [ebp - 0xf8], 0x81f8ae6e
mov dword [ebp - 0xf4], 0xa26aa78c
mov dword [ebp - 0xf0], 0xd8b49be0
mov dword [ebp - 0xec], 0xc3c59d2a
mov dword [ebp - 0xe8], 0xb6d785d6
mov dword [ebp - 0xe4], 0x3b71d86f
mov dword [ebp - 0xe0], 0xc0d521c9
mov dword [ebp - 0xdc], 0x144eeed4
mov dword [ebp - 0xd8], 0xe3acef9c
mov dword [ebp - 0xd4], 0xdd448339
mov dword [ebp - 0xd0], 0x8466f323
mov dword [ebp - 0xcc], 0x4ecf1e60
mov dword [ebp - 0xc8], 0x9d06c1fc
mov dword [ebp - 0xc4], 0x6945b11
mov dword [ebp - 0xc0], 0x1b498598
mov dword [ebp - 0xbc], 0x795bbf4e
mov dword [ebp - 0xb8], 0xbf63cb07
mov dword [ebp - 0xb4], 0x1dec214e
mov dword [ebp - 0xb0], 0x8b31e68d
mov dword [ebp - 0xac], 0x116e07e8
mov dword [ebp - 0xa8], 0x1e68ecb7
mov dword [ebp - 0xa4], 0xc8d86af
mov dword [ebp - 0xa0], 0xf0ee8e5c
mov dword [ebp - 0x9c], 0x6696fb00
mov dword [ebp - 0x98], 0xb1799a78
mov dword [ebp - 0x94], 0x5b36e69c
mov dword [ebp - 0x90], 0x7cdbbabc
mov dword [ebp - 0x8c], 0x3a43d189
mov dword [ebp - 0x88], 0x4cd2ada2
mov dword [ebp - 0x84], 0xd6083ac8
mov dword [ebp - 0x80], 0x9adb1d88
mov dword [ebp - 0x7c], 0x30ea1d65
mov dword [ebp - 0x78], 0x75a455ed
mov dword [ebp - 0x74], 0x742a30d
mov dword [ebp - 0x70], 0x3fa3444a
mov dword [ebp - 0x6c], 0xcaa64786
mov dword [ebp - 0x68], 0x9b7018ea
mov dword [ebp - 0x64], 0x6a917972
mov dword [ebp - 0x60], 0x379e84df
mov dword [ebp - 0x5c], 0x94e04275
mov dword [ebp - 0x58], 0x77e71e63
mov dword [ebp - 0x54], 0x3b0e0c75
mov dword [ebp - 0x50], 0x5092b72f
mov dword [ebp - 0x4c], 0x6754c897
mov dword [ebp - 0x48], 0x801e7bc
mov dword [ebp - 0x44], 0xd5733901
mov dword [ebp - 0x40], 0xdc2403cb
mov dword [ebp - 0x3c], 0x20d3c11c
mov dword [ebp - 0x38], 0x74efa73
mov dword [ebp - 0x34], 0xe05b1d3b
mov dword [ebp - 0x30], 0x90f3e72b
mov dword [ebp - 0x2c], 0x77fc3692
mov dword [ebp - 0x28], 0x308aeb98
mov dword [ebp - 0x24], 0xbe9e53c0
mov dword [ebp - 0x20], 0x72d0305e
mov dword [ebp - 0x1c], 0x3feeba1f
mov dword [ebp - 0x18], 0xeb754829
mov dword [ebp - 0x14], 0x88aa5f44
mov dword [ebp - 0x10], 0xa829ff1b
call fcn.00401240
cmp eax, 0x9b3b042b
je 0x403c28
push str.KEY_ERROR_100
call fcn.00402d80
add esp, 4
push 0x4b0
call dword [sym.imp.KERNEL32.DLL_Sleep]
push 1
call dword [sym.imp.KERNEL32.DLL_ExitProcess]
push 0x4353f0
push 0
push 0
push 0x114
lea eax, [ebp - 0x120]
push eax
push dword [0x43e0b4]
call dword [sym.imp.ADVAPI32.dll_CryptImportKey]
test eax, eax
jne 0x403c6d
push str.CryptImportKey_failed__
call fcn.00402d80
add esp, 4
xor eax, eax
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.004052f0
mov esp, ebp
pop ebp
ret
push 0x41f230
push str.C:ProgramDataRisen_ID.txt
mov dword [ebp - 0x124], 0
call fcn.004090dd
add esp, 8
test eax, eax
jne 0x403ca7
push 0x41f230
push str.Risen_ID.txt
call fcn.004090dd
add esp, 8
test eax, eax
je 0x403d72
push eax
call fcn.00406e1d
mov edi, dword [sym.imp.KERNEL32.DLL_CreateFileW]
add esp, 4
push 0
push 0
push 3
push 0
push 0
push SysReAllocString
push str.C:ProgramDataRisen_ID.txt
call edi
mov esi, eax
test esi, esi
jne 0x403d0a
push eax
push eax
push 3
push eax
push eax
push SysReAllocString
push str.Risen_ID.txt
call edi
mov esi, eax
test esi, esi
jne 0x403d0a
push str.Cannot_Open_ID_File
call fcn.00402d80
add esp, 4
xor eax, eax
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.004052f0
mov esp, ebp
pop ebp
ret
xor eax, eax
push eax
mov word [0x435408], ax
lea eax, [ebp - 0x124]
push eax
push 0x14
push 0x4353f4
push esi
call dword [sym.imp.KERNEL32.DLL_ReadFile]
test eax, eax
jne 0x403d4c
push str.Cannot_read_ID_File
call fcn.00402d80
add esp, 4
xor eax, eax
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.004052f0
mov esp, ebp
pop ebp
ret
xor ecx, ecx
nop
movzx eax, word [ecx + 0x4353f4]
lea ecx, [ecx + 2]
mov word [ecx + 0x43f3ee], ax
test ax, ax
jne 0x403d50
push esi
call dword [sym.imp.KERNEL32.DLL_CloseHandle]
jmp 0x403e73
push str.IDGEN
call fcn.00402d80
mov esi, dword [sym.imp.KERNEL32.DLL_CreateFileW]
add esp, 4
push 0
push 0
push 1
push 0
push 0
push 0x40000000
push str.C:ProgramDataRisen_ID.txt
call esi
mov edi, eax
test edi, edi
jne 0x403dc6
push eax
push eax
push 1
push eax
push eax
push 0x40000000
push str.Risen_ID.txt
call esi
mov edi, eax
test edi, edi
jne 0x403dc6
push str.Cannot_Create_ID_File
call fcn.00402d80
add esp, 4
xor eax, eax
mov word [0x4353fc], 0
mov word [0x435408], ax
xorps xmm0, xmm0
lea eax, [ebp - 0x130]
movq qword [0x4353f4], xmm0
push eax
mov byte [0x4353fe], 0
call fcn.004091a6
add esp, 4
push eax
call fcn.00409115
add esp, 4
xor esi, esi
lea ebx, [esi + 0x7d]
call fcn.004090f4
cdq
idiv ebx
inc edx
cmp edx, 0x2f
jbe 0x403e19
cmp edx, 0x3a
jb 0x403e21
lea eax, [edx - 0x41]
cmp eax, 0x19
ja 0x403e2b
mov word [esi + 0x4353f4], dx
add esi, 2
cmp esi, 0x14
jb 0x403e06
push 0
lea eax, [ebp - 0x128]
push eax
push 0x14
push 0x4353f4
push edi
call dword [sym.imp.KERNEL32.DLL_WriteFile]
test eax, eax
jne 0x403e5f
call dword [sym.imp.KERNEL32.DLL_GetLastError]
push eax
push str.Cannot_Write_ID_To_File__GetLastError___lu_n
call fcn.00402d80
add esp, 8
push edi
call dword [sym.imp.KERNEL32.DLL_CloseHandle]
push str.END_IDGEN
call fcn.00402d80
add esp, 4
movups xmm0, xmmword [str._Risen_]
mov ebx, 0x4353f4
mov esi, ebx
movups xmmword [0x43e0c8], xmm0
nop dword [eax + eax]
mov ax, word [ebx]
add ebx, 2
test ax, ax
jne 0x403e90
mov edx, 0x43e0c8
sub ebx, esi
lea edi, [edx - 2]
mov ax, word [edi + 2]
add edi, 2
test ax, ax
jne 0x403ea5
mov ecx, ebx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, ebx
and ecx, 3
add edx, 0xfffffffe
rep movsb byte es:[edi], byte [esi]
mov ax, word [edx + 2]
lea edx, [edx + 2]
test ax, ax
jne 0x403ec2
mov eax, dword [str._.Public]
mov ebx, 0x4353f4
mov dword [edx], eax
mov esi, ebx
mov eax, dword [0x4209d4]
mov dword [edx + 4], eax
mov eax, dword [0x4209d8]
mov dword [edx + 8], eax
mov eax, dword [0x4209dc]
mov dword [edx + 0xc], eax
mov ax, word [0x4209e0]
mov word [edx + 0x10], ax
movups xmmword [0x43f408], xmm0
mov ax, word [ebx]
add ebx, 2
test ax, ax
jne 0x403f05
mov edx, 0x43f408
sub ebx, esi
lea edi, [edx - 2]
nop word [eax + eax]
mov ax, word [edi + 2]
add edi, 2
test ax, ax
jne 0x403f20
mov ecx, ebx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, ebx
and ecx, 3
add edx, 0xfffffffe
rep movsb byte es:[edi], byte [esi]
nop dword [eax]
mov ax, word [edx + 2]
lea edx, [edx + 2]
test ax, ax
jne 0x403f40
mov eax, dword [str._.Private]
movups xmm0, xmmword [str.C:ProgramData_]
mov dword [edx], eax
mov eax, dword [0x4209e8]
movups xmm1, xmmword [0x420a08]
mov dword [edx + 4], eax
mov eax, dword [0x4209ec]
mov dword [edx + 8], eax
mov eax, dword [0x4209f0]
mov dword [edx + 0xc], eax
mov eax, dword [0x4209f4]
mov dword [edx + 0x10], eax
mov edx, 0x43e0c8
movups xmmword [0x43fb18], xmm0
mov esi, edx
movups xmmword [0x43fb28], xmm1
mov ax, word [edx]
add edx, 2
test ax, ax
jne 0x403f96
mov edi, 0x43fb18
sub edx, esi
add edi, 0xfffffffe
nop dword [eax + eax]
mov ax, word [edi + 2]
add edi, 2
test ax, ax
jne 0x403fb0
mov ecx, edx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
mov edx, 0x43f408
and ecx, 3
rep movsb byte es:[edi], byte [esi]
movups xmmword [0x43f790], xmm0
mov esi, edx
movups xmmword [0x43f7a0], xmm1
nop
mov ax, word [edx]
add edx, 2
test ax, ax
jne 0x403fe0
mov edi, 0x43f790
sub edx, esi
add edi, 0xfffffffe
mov ax, word [edi + 2]
add edi, 2
test ax, ax
jne 0x403ff5
mov ecx, edx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
and ecx, 3
push 0x41f230
rep movsb byte es:[edi], byte [esi]
push 0x43e0c8
call fcn.004090dd
add esp, 8
test eax, eax
jne 0x404067
push 0x41f230
push 0x43f408
call fcn.004090dd
add esp, 8
test eax, eax
jne 0x404067
push 0x41f230
push 0x43fb18
call fcn.004090dd
add esp, 8
test eax, eax
jne 0x404067
push 0x41f230
push 0x43f790
call fcn.004090dd
add esp, 8
test eax, eax
je 0x4040a6
push eax
call fcn.00406e1d
add esp, 4
push str.Key_Found___LoadKeys
call fcn.00402d80
add esp, 4
call fcn.00403310
test eax, eax
jne 0x4040dc
push str.Cannot_Load_Client_Pair_Key
call fcn.00402d80
add esp, 4
xor eax, eax
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.004052f0
mov esp, ebp
pop ebp
ret
push str.Key_NotFound___GenerateKeys
call fcn.00402d80
add esp, 4
call fcn.00403470
test eax, eax
jne 0x4040dc
push str.Cannot_Generate_Client_Pair_Key
call fcn.00402d80
add esp, 4
xor eax, eax
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.004052f0
mov esp, ebp
pop ebp
ret
push str.return_Initialize__
call fcn.00402d80
mov ecx, dword [ebp - 4]
add esp, 4
xor ecx, ebp
mov eax, 1
pop edi
pop esi
pop ebx
call fcn.004052f0
mov esp, ebp
pop ebp
ret