Function at 0x40cb00
Capabilities:
Get file size

Disassembly:
sub esp, 0x68
push ebx
push ebp
push esi
push edi
mov edi, dword [0x473a28]
mov ebp, ecx
mov dword [esp + 0x18], edi
call fcn.0040ca90
xor esi, esi
call fcn.00446290
mov byte [esp + esi + 0x4c], al
inc esi
cmp esi, 0x24
jl 0x40cb1a
mov ecx, dword [esp + 0x5c]
mov eax, dword [esp + 0x60]
mov edx, ecx
and eax, 0xffff
cmp ecx, 0x12
mov dword [esp + 0x14], edx
mov dword [esp + 0x10], eax
jge 0x40cb56
mov edx, 0x10
mov dword [esp + 0x10], 1
mov dword [esp + 0x14], edx
mov eax, dword [esp + 0x50]
mov ebx, dword [esp + 0x4e]
lea ecx, [eax + edi + 8]
mov dword [esp + 0x1c], ecx
mov ecx, dword [esp + 0x4c]
cmp cl, 0x52
jne 0x40cdfe
cmp byte [esp + 0x4d], 0x49
jne 0x40cdfe
cmp bl, 0x46
jne 0x40cdfe
cmp bh, bl
jne 0x40cdfe
cmp eax, 0x24
jl 0x40cdfe
cmp byte [esp + 0x54], 0x57
jne 0x40cdfe
cmp byte [esp + 0x55], 0x41
jne 0x40cdfe
cmp byte [esp + 0x56], 0x56
jne 0x40cdfe
cmp byte [esp + 0x57], 0x45
jne 0x40cdfe
cmp byte [esp + 0x58], 0x66
jne 0x40cdfe
cmp byte [esp + 0x59], 0x6d
jne 0x40cdfe
cmp byte [esp + 0x5a], 0x74
jne 0x40cdfe
cmp byte [esp + 0x5b], 0x20
jne 0x40cdfe
cmp edx, 0x186a0
jg 0x40cdfe
mov edi, dword [esp + 0x14]
lea ecx, [edi + 0x10]
call fcn.00435b70
mov dx, word [esp + 0x10]
mov ecx, dword [esp + 0x64]
mov ebx, eax
mov ax, word [esp + 0x62]
add edi, 0xfffffff0
xor esi, esi
mov word [ebx], dx
mov edx, dword [esp + 0x68]
mov word [ebx + 2], ax
mov ax, word [esp + 0x6c]
mov dword [ebx + 4], ecx
mov cx, word [esp + 0x6e]
test edi, edi
mov dword [ebx + 8], edx
mov word [ebx + 0xc], ax
mov word [ebx + 0xe], cx
jle 0x40cc52
call fcn.00446290
mov byte [ebx + esi + 0x10], al
inc esi
cmp esi, edi
jl 0x40cc44
mov eax, dword [esp + 0x10]
cmp eax, 1
je 0x40cc71
mov edx, dword [esp + 0x14]
add edx, 0xffffffee
cmp eax, 0x55
mov word [ebx + 0x10], dx
jne 0x40cc71
mov word [ebx + 0x10], 0xc
mov edi, dword [esp + 0x1c]
mov eax, dword [0x473a28]
cmp eax, edi
jge 0x40cdde
xor esi, esi
call fcn.00446290
mov byte [esp + esi + 0x70], al
inc esi
cmp esi, 8
jl 0x40cc84
cmp byte [esp + 0x70], 0x64
jne 0x40ccaf
cmp byte [esp + 0x71], 0x61
jne 0x40ccaf
cmp byte [esp + 0x72], 0x74
jne 0x40ccaf
cmp byte [esp + 0x73], 0x61
je 0x40ccd1
mov ecx, dword [esp + 0x74]
test ecx, ecx
jl 0x40cdde
mov eax, dword [0x473a28]
add eax, ecx
cmp eax, edi
mov dword [0x473a28], eax
jge 0x40cdde
jmp 0x40cc82
mov esi, dword [esp + 0x74]
test esi, esi
jl 0x40cdde
cmp dword [esp + 0x10], 1
jne 0x40cd08
push esi
mov ecx, ebp
call fcn.0040cab0
mov eax, dword [ebp]
push esi
mov ecx, dword [eax + 0x1c]
push ecx
call fcn.00446380
mov edx, dword [ebp]
add esp, 8
mov dword [edx + 0x18], 0
jmp 0x40cd56
mov esi, dword [esp + 0x14]
mov eax, dword [esp + 0x74]
add eax, esi
mov ecx, ebp
push eax
call fcn.0040cab0
mov edx, dword [ebp]
mov ecx, esi
mov eax, ecx
mov esi, ebx
mov edi, dword [edx + 0x1c]
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov edx, dword [ebp]
mov esi, dword [esp + 0x14]
mov ecx, dword [esp + 0x74]
mov eax, dword [edx + 0x1c]
push ecx
add eax, esi
push eax
call fcn.00446380
mov ecx, dword [ebp]
mov edi, dword [esp + 0x24]
add esp, 8
mov dword [ecx + 0x18], esi
mov ecx, dword [esp + 0x10]
xor esi, esi
xor eax, eax
mov dword [0x473a28], edi
mov si, word [ebx + 2]
mov edi, dword [ebx + 4]
mov ax, word [ebx + 0xe]
cmp ecx, 1
jne 0x40cdb1
cmp edi, 0x4099
jge 0x40cd83
mov edi, 0x2b11
jmp 0x40cd9d
xor edx, edx
cmp edi, 0x8133
setle dl
dec edx
and edx, 0x5622
add edx, 0x5622
mov edi, edx
cmp esi, 2
je 0x40cda7
mov esi, 1
cmp eax, 0x10
je 0x40cdb1
mov eax, 8
mov ecx, dword [ebp]
mov dword [ecx + 8], edi
mov edx, dword [ebp]
mov word [edx + 0x10], si
mov ecx, dword [ebp]
mov word [ecx + 0x12], ax
mov edx, dword [ebp]
mov eax, dword [esp + 0x10]
mov ecx, ebx
mov dword [edx + 0xc], eax
call fcn.00435be0
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x68
ret
mov ecx, dword [esp + 0x18]
mov byte [0x473a18], 1
mov dword [0x473a28], ecx
mov ecx, ebx
call fcn.00435be0
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x68
ret
mov edx, ecx
and edx, 0xffffff
cmp edx, 0x334449
jne 0x40ce52
mov esi, 0xbb8
mov ebx, dword [0x473a28]
call fcn.00446290
cmp al, 0xff
je 0x40ce29
dec esi
test esi, esi
jg 0x40ce13
jmp 0x40ce2f
mov dword [0x473a28], ebx
test esi, esi
jne 0x40ce39
mov dword [0x473a28], edi
xor esi, esi
call fcn.00446290
mov byte [esp + esi + 0x4c], al
inc esi
cmp esi, 0x24
jl 0x40ce3b
mov ebx, dword [esp + 0x4e]
mov ecx, dword [esp + 0x4c]
mov eax, ecx
mov edx, ecx
mov esi, ecx
mov edi, 4
shr eax, 9
shr edx, 0x12
shr esi, 0xb
and eax, 3
and edx, 3
and esi, 1
sub edi, eax
mov eax, dword [edx*4 + 0x470300]
mov dword [esp + 0x20], esi
test esi, esi
mov dword [esp + 0x14], eax
jne 0x40ce8d
cdq
sub eax, edx
sar eax, 1
mov dword [esp + 0x14], eax
mov eax, ecx
xor edx, edx
shr eax, 0x1e
lea esi, [edi + esi*4]
mov dl, byte [eax + 0x470310]
xor eax, eax
mov dword [esp + 0x10], edx
mov edx, ecx
shr edx, 0x14
shl esi, 4
and edx, 0xf
and ecx, 0xf0ff
mov al, byte [esi + edx + 0x470308]
lea eax, [eax + eax*4]
lea eax, [eax + eax*4]
lea eax, [eax + eax*4]
shl eax, 3
cmp ecx, 0xf0ff
mov dword [esp + 0x1c], eax
jne 0x40d03f
cmp edi, 3
jne 0x40d03f
mov ecx, dword [esp + 0x14]
test ecx, ecx
jle 0x40d03f
test eax, eax
jle 0x40d03f
call fcn.004460d0
test al, al
je 0x40d03f
call fcn.00445fb0
test al, al
je 0x40d03f
mov ecx, dword [0x473a24]
mov eax, dword [esp + 0x18]
push 0
push ecx
mov dword [0x473a28], eax
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov ebx, eax
mov eax, dword [0x473a28]
sub ebx, eax
jns 0x40cf33
xor ebx, ebx
lea edx, [ebx + 0x2e]
mov ecx, ebp
push edx
call fcn.0040cab0
mov eax, dword [ebp]
mov edx, dword [esp + 0x10]
push ebx
mov ecx, dword [eax + 4]
add ecx, 0xfffffff0
mov dword [eax + 4], ecx
mov ecx, dword [ebp]
mov eax, dword [esp + 0x18]
mov dword [ecx + 8], eax
mov ecx, dword [ebp]
mov word [ecx + 0x10], dx
mov esi, dword [ebp]
xor ecx, ecx
dec edi
mov word [esi + 0x12], cx
mov esi, dword [ebp]
neg edi
mov dword [esi + 0xc], 0x55
mov esi, dword [ebp]
sbb edi, edi
mov dword [esi + 0x14], ecx
mov esi, dword [ebp]
and edi, 0xfffffffd
mov dword [esi + 0x18], 0x1e
mov esi, dword [ebp]
add edi, 4
mov esi, dword [esi + 0x1c]
mov dword [esi + 4], eax
mov eax, dword [esp + 0x20]
mov dword [esi + 8], eax
mov word [esi + 0xe], cx
mov ecx, dword [esp + 0x24]
mov eax, 0x120
shl eax, cl
mov word [esi + 2], dx
mov word [esi + 0xc], di
mov edi, 1
mov word [esi], 0x55
mov word [esi + 0x10], 0xc
mov word [esi + 0x12], di
imul eax, dword [esp + 0x20]
imul eax, edx
cdq
idiv dword [esp + 0x18]
mov dword [esi + 0x14], 2
mov word [esi + 0x1a], di
mov word [esi + 0x1c], 0x571
mov word [esi + 0x18], ax
mov ecx, dword [ebp]
mov edx, dword [ecx + 0x1c]
add edx, 0x1e
push edx
call fcn.00446380
mov ebp, dword [ebp]
add esp, 8
mov eax, dword [ebp + 4]
cmp eax, 0x9e
jl 0x40d2a8
mov ecx, dword [ebp + 0x1c]
add ecx, eax
cmp byte [ecx - 0x80], 0x54
jne 0x40d2a8
cmp byte [ecx - 0x7f], 0x41
jne 0x40d2a8
cmp byte [ecx - 0x7e], 0x47
jne 0x40d2a8
add eax, 0xffffff80
pop edi
mov dword [ebp + 4], eax
pop esi
pop ebp
pop ebx
add esp, 0x68
ret
mov ecx, dword [esp + 0x4f]
mov word [esp + 0x24], 0x50
and ecx, 0xff
mov word [esp + 0x30], 1
mov eax, ecx
shr eax, 6
shr ecx, 4
movzx dx, byte [eax + 0x470314]
movzx ax, byte [eax + 0x470310]
mov word [esp + 0x3c], dx
mov word [esp + 0x26], ax
mov edx, 1
mov al, bh
shl edx, cl
and al, 3
xor cx, cx
mov cl, al
mov eax, dword [esp + 0x4d]
inc ecx
mov word [esp + 0x3e], dx
mov dl, al
mov word [esp + 0x40], cx
and dl, 1
xor cx, cx
mov cl, dl
mov dl, al
and dl, 8
and eax, 0xff
movzx dx, dl
lea ecx, [edx + ecx*4]
mov dl, bh
shr dl, 2
and dl, 2
movzx dx, dl
lea ecx, [edx + ecx*2]
mov dl, bh
and dl, 4
movzx dx, dl
add ecx, edx
mov dl, bl
and dl, 1
and ebx, 0xff
movzx dx, dl
add ecx, edx
mov edx, eax
shr edx, 1
mov word [esp + 0x42], cx
and edx, 3
mov ecx, 4
sub ecx, edx
mov edx, 8
sar edx, cl
shr eax, 3
and eax, 1
mov word [esp + 0x36], dx
mov edx, ebx
shr edx, 2
and edx, 3
lea esi, [ecx + eax*4]
shl esi, 4
mov edi, dword [edx*4 + 0x470300]
mov edx, ebx
shr edx, 4
xor eax, eax
mov dword [esp + 0x28], edi
mov al, byte [esi + edx + 0x470308]
lea eax, [eax + eax*4]
lea esi, [eax + eax*4]
lea esi, [esi + esi*4]
shl esi, 3
cmp edi, 0xac44
mov dword [esp + 0x2c], esi
lea eax, [esi*8]
mov dword [esp + 0x38], eax
je 0x40d17d
cmp ecx, 3
jne 0x40d15a
test ebx, 0xfffffff0
je 0x40d17d
cmp ecx, 1
jne 0x40d16e
lea eax, [eax + eax*2]
xor edx, edx
shl eax, 2
div edi
shl eax, 2
jmp 0x40d178
lea eax, [eax + eax*8]
xor edx, edx
shl eax, 4
div edi
mov word [esp + 0x30], ax
mov eax, dword [esp + 0x4c]
xor ebx, ebx
and eax, 0xf0ff
mov word [esp + 0x32], bx
cmp eax, 0xf0ff
mov word [esp + 0x34], 0x16
mov dword [esp + 0x44], ebx
mov dword [esp + 0x48], ebx
jne 0x40d297
cmp edi, ebx
jbe 0x40d297
cmp esi, ebx
jbe 0x40d297
call fcn.004460d0
test al, al
je 0x40d297
call fcn.00445fb0
test al, al
je 0x40d297
mov ecx, dword [0x473a24]
mov eax, dword [esp + 0x18]
push ebx
push ecx
mov dword [0x473a28], eax
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov ebx, eax
mov eax, dword [0x473a28]
sub ebx, eax
jns 0x40d1f5
xor ebx, ebx
lea edx, [ebx + 0x38]
mov ecx, ebp
push edx
call fcn.0040cab0
mov eax, dword [ebp]
mov dx, word [esp + 0x26]
lea esi, [esp + 0x24]
push ebx
mov ecx, dword [eax + 4]
add ecx, 0xfffffff0
mov dword [eax + 4], ecx
mov eax, dword [ebp]
mov dword [eax + 8], edi
mov ecx, dword [ebp]
xor eax, eax
mov word [ecx + 0x10], dx
mov ecx, dword [ebp]
mov word [ecx + 0x12], ax
mov edx, dword [ebp]
mov dword [edx + 0xc], 0x50
mov ecx, dword [ebp]
mov dword [ecx + 0x14], eax
mov edx, dword [ebp]
mov ecx, 0xa
mov dword [edx + 0x18], 0x28
mov eax, dword [ebp]
mov edi, dword [eax + 0x1c]
rep movsd dword es:[edi], dword [esi]
mov ecx, dword [ebp]
mov edx, dword [ecx + 0x1c]
add edx, 0x28
push edx
call fcn.00446380
mov ebp, dword [ebp]
add esp, 8
mov eax, dword [ebp + 4]
cmp eax, 0xa8
jb 0x40d2a8
mov ecx, dword [ebp + 0x1c]
add ecx, eax
cmp byte [ecx - 0x80], 0x54
jne 0x40d2a8
cmp byte [ecx - 0x7f], 0x41
jne 0x40d2a8
cmp byte [ecx - 0x7e], 0x47
jne 0x40d2a8
add eax, 0xffffff80
pop edi
mov dword [ebp + 4], eax
pop esi
pop ebp
pop ebx
add esp, 0x68
ret
mov edx, dword [esp + 0x18]
mov byte [0x473a18], 1
mov dword [0x473a28], edx
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x68
ret