Function at 0x402e8d
Capabilities:
Write file on windows

Disassembly:
push 0x68
mov eax, 0x410771
call fcn.0040f882
mov edi, ecx
xor eax, eax
xor esi, esi
cmp dword [edi + 0xf4], esi
sete al
inc eax
movzx ecx, ax
cmp dword [edi + 0x70], esi
jne 0x402ebb
cmp dword [edi + 0x74], esi
jne 0x402ebb
push 2
pop eax
jmp 0x402ebe
xor eax, eax
inc eax
mov ebx, dword [sym.imp.Common.dll_public:_void___thiscall_CTXCommPack::constructor_void_]
shl eax, 2
or eax, ecx
movzx eax, ax
lea ecx, [ebp - 0x4c]
mov dword [ebp - 0x20], eax
call ebx
mov dword [ebp - 4], esi
mov esi, dword [sym.imp.Common.dll_public:_int___thiscall_CTXCommPack::AddByte_unsigned_char_]
push 1
lea ecx, [ebp - 0x4c]
call esi
push 2
lea ecx, [ebp - 0x4c]
call esi
push 1
push dword [ebp - 0x20]
lea ecx, [ebp - 0x4c]
call dword [sym.imp.Common.dll_public:_int___thiscall_CTXCommPack::AddWord_unsigned_short_int__int_]
push 4
pop ecx
lea eax, [edi + 0x128]
mov edx, dword [eax]
or edx, dword [eax + 4]
jne 0x402f14
mov edx, dword [eax + 8]
mov dword [eax], edx
mov edx, dword [eax + 0xc]
mov dword [eax + 4], edx
dec ecx
sub eax, 8
test ecx, ecx
jg 0x402f02
lea eax, [edi + 0x110]
mov dword [ebp - 0x10], 2
mov dword [ebp - 0x20], eax
jmp 0x402f31
mov eax, dword [ebp - 0x20]
mov ecx, dword [eax + 8]
sub ecx, dword [eax]
mov dword [ebp - 0x1c], ecx
jns 0x402f42
and dword [ebp - 0x1c], 0
mov ecx, dword [ebp - 0x1c]
mov eax, dword [ebp - 0x10]
push ecx
dec eax
push eax
push 0x4140c8
push str.StorageTool
push 2
push str.func
push 0x169
push str.file
call fcn.00402950
add esp, 0x20
push dword [ebp - 0x10]
lea ecx, [ebp - 0x4c]
call esi
push 2
lea ecx, [ebp - 0x4c]
call esi
push 1
push dword [ebp - 0x1c]
lea ecx, [ebp - 0x4c]
call dword [sym.imp.Common.dll_public:_int___thiscall_CTXCommPack::AddWord_unsigned_short_int__int_]
inc dword [ebp - 0x10]
add dword [ebp - 0x20], 8
cmp dword [ebp - 0x10], 5
jle 0x402f2e
call dword [sym.imp.Common.dll_void___cdecl_TXLog::FlushLog_void_]
and dword [ebp - 0x14], 0
and dword [ebp - 0x18], 0
lea ecx, [ebp - 0x74]
mov byte [ebp - 4], 2
call ebx
mov esi, dword [sym.imp.Common.dll_public:_int___thiscall_CTXCommPack::GetBufferOut_class_CTXBuffer__]
lea eax, [ebp - 0x18]
push eax
lea ecx, [ebp - 0x4c]
mov byte [ebp - 4], 3
call esi
push 2
lea eax, [ebp - 0x18]
push eax
push 0x30005002
lea ecx, [ebp - 0x74]
call dword [sym.imp.Common.dll_public:_int___thiscall_CTXCommPack::AddTLV_unsigned_long_int__class_CTXBuffer_const___enum_TXCommPackDataType_]
lea eax, [ebp - 0x14]
push eax
lea ecx, [ebp - 0x74]
call esi
lea eax, [ebp - 0x20]
push eax
call fcn.0040f429
mov dword [esp], str.TencentQQDR8BEC1F8C_3230_4d11_BA13_922AF73D228B.dr
push eax
lea eax, [ebp - 0x24]
push eax
mov byte [ebp - 4], 4
call dword [sym.imp.Common.dll_class_CTXStringW___cdecl_operator_class_CTXStringW_const___wchar_t_const__]
add esp, 0xc
mov esi, dword [sym.imp.Common.dll_public:_void___thiscall_CTXStringW::destructor_void_]
lea ecx, [ebp - 0x20]
mov byte [ebp - 4], 6
call esi
xor eax, eax
push eax
push 0x80
push 2
push eax
push eax
push 0xc0000000
lea ecx, [ebp - 0x24]
call dword [sym.imp.Common.dll_public:_wchar_t_const____thiscall_CTXStringW::operator_wchar_t_const__void_const]
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov ebx, eax
cmp ebx, 0xffffffff
je 0x40305f
and dword [ebp - 0x1c], 0
push 0
lea eax, [ebp - 0x1c]
push eax
lea ecx, [ebp - 0x14]
call fcn.00401e05
push eax
lea ecx, [ebp - 0x14]
call fcn.00401de6
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_WriteFile]
push ebx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
xor ebx, ebx
push 0x3f
pop ecx
cmp dword [edi + 0x7c], ebx
je 0x40306c
push 0x3e
pop ecx
cmp dword [edi + 0x80], ebx
je 0x40307a
and ecx, 0xfffd
cmp dword [edi + 0x70], ebx
je 0x403085
and ecx, 0xfffb
cmp dword [edi + 0x84], ebx
je 0x4030b4
mov eax, dword [edi + 0x6c]
cmp eax, 0xfffffffd
je 0x4030ae
cmp eax, 0xffffffff
je 0x4030a6
cmp eax, ebx
jne 0x4030b4
and ecx, 0xffdf
jmp 0x4030b4
and ecx, 0xffef
jmp 0x4030b4
and ecx, 0xfff7
mov eax, dword [edi + 0x6c]
cmp eax, 0xfffffffd
je 0x4030ec
cmp eax, 0xffffffff
je 0x4030e4
cmp eax, ebx
je 0x4030dc
cmp eax, 1
je 0x4030d7
cmp eax, 2
jne 0x4030f2
or ecx, 0x80
jmp 0x4030f2
or ecx, 0x40
jmp 0x4030f2
or ecx, 0x140
jmp 0x4030f2
or ecx, 0x100
jmp 0x4030f2
or ecx, 0xc0
push 0x8c004010
push ecx
call fcn.00402c7a
movzx eax, word [edi + 0x138]
push 0x8c004012
push eax
call fcn.00402c7a
add esp, 0x10
lea ecx, [ebp - 0x24]
mov byte [ebp - 4], 3
call esi
mov esi, dword [sym.imp.Common.dll_public_virtual:_void___thiscall_CTXCommPack::destructor_void_]
lea ecx, [ebp - 0x74]
mov byte [ebp - 4], 2
call esi
mov eax, dword [ebp - 0x18]
mov byte [ebp - 4], 1
cmp eax, ebx
je 0x40313e
mov ecx, dword [eax]
push eax
call dword [ecx + 8]
mov dword [ebp - 0x18], ebx
mov eax, dword [ebp - 0x14]
mov byte [ebp - 4], bl
cmp eax, ebx
je 0x403151
mov ecx, dword [eax]
push eax
call dword [ecx + 8]
mov dword [ebp - 0x14], ebx
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x4c]
call esi
call fcn.0040f921
ret