Function at 0x4a6de0
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x5675ff
mov eax, dword fs:[0]
push eax
sub esp, 0x68
mov eax, dword [0x61308c]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
xor eax, eax
mov dword [ebp - 0x30], 0
mov dword [ebp - 0x2c], 0
xor bl, bl
mov dword [ebp - 0x2c], 7
mov dword [ebp - 0x30], 0
mov word [ebp - 0x40], ax
mov dword [ebp - 4], 1
mov eax, dword [0x61e20c]
sub eax, dword [0x61e208]
sar eax, 2
test eax, eax
je 0x4a6ff2
xor eax, eax
mov dword [ebp - 0x18], 0
mov dword [ebp - 0x14], 0
mov dword [ebp - 0x14], 7
mov dword [ebp - 0x18], 0
mov word [ebp - 0x28], ax
mov byte [ebp - 4], 3
lea ecx, [ebp - 0x40]
push 0x29
push 0x5b9ac8
call fcn.00404d30
push 0xf
push 0x5b9b1c
lea ecx, [ebp - 0x40]
call fcn.00406f60
push 1
lea eax, [ebp - 0x28]
push 0x5b9b50
push eax
call fcn.0040d480
add esp, 0xc
lea edx, [ebp - 0x28]
cmp dword [ebp - 0x14], 8
cmovae edx, dword [ebp - 0x28]
cmp word [edx], 0
jne 0x4a6eb8
xor ecx, ecx
jmp 0x4a6ecf
mov ecx, edx
lea esi, [ecx + 2]
nop dword [eax]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x4a6ec0
sub ecx, esi
sar ecx, 1
push ecx
push edx
lea ecx, [ebp - 0x40]
call fcn.00406f60
push 9
push 0x5b9b3c
lea ecx, [ebp - 0x40]
call fcn.00406f60
mov esi, dword [0x61e208]
cmp esi, dword [0x61e20c]
je 0x4a6fa7
nop word [eax + eax]
mov eax, dword [esi]
push dword [eax + 0x24]
push dword [eax + 0x20]
lea eax, [ebp - 0x28]
push str._n___DevHW_SelDrvID__d_____CDATA_
push eax
call fcn.0040d480
add esp, 0x10
lea edx, [ebp - 0x28]
cmp dword [ebp - 0x14], 8
cmovae edx, dword [ebp - 0x28]
cmp word [edx], 0
jne 0x4a6f2e
xor ecx, ecx
jmp 0x4a6f42
mov ecx, edx
lea edi, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x4a6f33
sub ecx, edi
sar ecx, 1
push ecx
push edx
lea ecx, [ebp - 0x40]
call fcn.00406f60
mov edx, dword [esi]
add edx, 4
cmp dword [edx + 0x14], 8
jb 0x4a6f59
mov edx, dword [edx]
cmp word [edx], 0
jne 0x4a6f63
xor ecx, ecx
jmp 0x4a6f7f
mov ecx, edx
lea edi, [ecx + 2]
nop dword [eax + eax]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x4a6f70
sub ecx, edi
sar ecx, 1
push ecx
push edx
lea ecx, [ebp - 0x40]
call fcn.00406f60
push 0xb
push 0x5b9bf4
lea ecx, [ebp - 0x40]
call fcn.00406f60
add esi, 4
cmp esi, dword [0x61e20c]
jne 0x4a6f00
push 0xc
push 0x5b9c0c
lea ecx, [ebp - 0x40]
call fcn.00406f60
push 0x10
push 0x5b9c28
lea ecx, [ebp - 0x40]
call fcn.00406f60
mov byte [ebp - 4], 1
mov eax, dword [ebp - 0x14]
cmp eax, 8
jb 0x4a6fde
inc eax
lea ecx, [ebp - 0x28]
push eax
push dword [ebp - 0x28]
call fcn.00404be0
xor eax, eax
mov dword [ebp - 0x14], 7
mov dword [ebp - 0x18], 0
mov word [ebp - 0x28], ax
cmp dword [ebp - 0x30], 0
je 0x4a71d3
mov dword [ebp - 0x48], 0
mov dword [ebp - 0x44], 0
mov dword [ebp - 0x44], 0xf
mov dword [ebp - 0x48], 0
mov byte [ebp - 0x58], 0
mov byte [ebp - 4], 5
lea eax, [ebp - 0x40]
cmp dword [ebp - 0x2c], 8
lea ecx, [ebp - 0x58]
cmovae eax, dword [ebp - 0x40]
push eax
call fcn.0040d560
mov byte [ebp - 4], 6
mov edx, 0x5b9c4c
lea ecx, [ebp - 0x70]
call fcn.00411c40
mov byte [ebp - 4], 7
mov dword [ebp - 0x1c], vtable.CBaseFile.0
mov dword [ebp - 0x14], 0
mov byte [ebp - 0x18], 0
mov byte [ebp - 4], 8
lea eax, [ebp - 0x70]
cmp dword [ebp - 0x5c], 8
lea ecx, [ebp - 0x1c]
push 0x1a
cmovae eax, dword [ebp - 0x70]
push eax
call fcn.00404380
test al, al
je 0x4a70fd
mov cl, byte [ebp - 0x18]
mov eax, dword [ebp - 0x14]
mov word [ebp - 0x74], 0xbbef
mov byte [ebp - 0x72], 0xbf
test cl, cl
je 0x4a70b4
test eax, eax
je 0x4a70b4
push eax
push 3
lea eax, [ebp - 0x74]
push 1
push eax
call fcn.0052edd8
push dword [ebp - 0x14]
call fcn.0052eb75
mov eax, dword [ebp - 0x14]
add esp, 0x14
mov cl, byte [ebp - 0x18]
cmp dword [ebp - 0x44], 0x10
lea edx, [ebp - 0x58]
cmovae edx, dword [ebp - 0x58]
test cl, cl
je 0x4a70e1
test eax, eax
je 0x4a70f5
push eax
push dword [ebp - 0x48]
push 1
push edx
call fcn.0052edd8
push dword [ebp - 0x14]
call fcn.0052eb75
mov eax, dword [ebp - 0x14]
add esp, 0x14
test eax, eax
je 0x4a70f5
push eax
call fcn.0052e84e
add esp, 4
test eax, eax
jne 0x4a70f9
mov dword [ebp - 0x14], eax
mov byte [ebp - 0x18], 0
mov bl, 1
jmp 0x4a7155
cmp dword [ebp - 0x5c], 8
lea edi, [ebp - 0x70]
mov esi, dword [0x618d28]
cmovae edi, dword [ebp - 0x70]
test esi, esi
jne 0x4a7136
push 0x70
call fcn.005120b2
add esp, 4
mov dword [ebp - 0x74], eax
mov byte [ebp - 4], 9
mov ecx, eax
call fcn.00409ee0
mov esi, eax
mov byte [ebp - 4], 8
mov dword [0x618d28], esi
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push edi
push 0x5b9c74
push 0x56
push 0x5b9c8c
push 1
push esi
call fcn.0040a3e0
add esp, 0x1c
mov byte [ebp - 4], 7
mov eax, dword [ebp - 0x14]
mov dword [ebp - 0x1c], vtable.CBaseFile.0
test eax, eax
je 0x4a7177
push eax
call fcn.0052e84e
add esp, 4
test eax, eax
jne 0x4a717b
mov dword [ebp - 0x14], eax
mov byte [ebp - 0x18], 0
mov byte [ebp - 4], 6
mov eax, dword [ebp - 0x5c]
cmp eax, 8
jb 0x4a7194
inc eax
lea ecx, [ebp - 0x70]
push eax
push dword [ebp - 0x70]
call fcn.00404be0
xor eax, eax
mov dword [ebp - 0x5c], 7
mov dword [ebp - 0x60], 0
mov word [ebp - 0x70], ax
mov byte [ebp - 4], 1
mov eax, dword [ebp - 0x44]
cmp eax, 0x10
jb 0x4a71c1
inc eax
lea ecx, [ebp - 0x58]
push eax
push dword [ebp - 0x58]
call fcn.00409490
mov dword [ebp - 0x44], 0xf
mov dword [ebp - 0x48], 0
mov byte [ebp - 0x58], 0
call fcn.004a6ba0
mov dword [ebp - 4], 0xffffffff
mov eax, dword [ebp - 0x2c]
cmp eax, 8
jb 0x4a71f4
inc eax
lea ecx, [ebp - 0x40]
push eax
push dword [ebp - 0x40]
call fcn.00404be0
xor eax, eax
mov dword [ebp - 0x2c], 7
mov word [ebp - 0x40], ax
mov al, bl
mov dword [ebp - 0x30], 0
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.005120a1
mov esp, ebp
pop ebp
ret