Function at 0x403c00
Capabilities:
Capture screenshot
Query environment variable
Read file on windows
Write file on windows

Disassembly:
push ebp
mov ebp, esp
push ebx
push edi
push esi
sub esp, 0x488
mov eax, dword [ebp + 0xc]
mov ecx, dword [ebp + 8]
xor edx, edx
mov esi, dword [0x4103e4]
mov edi, dword [0x41040c]
sub edx, 1
mov ebx, esi
add ebx, edx
imul esi, ebx
and esi, 1
cmp esi, 0
sete dl
and dl, 1
mov byte [ebp - 0xb6], dl
cmp edi, 0xa
setl dl
and dl, 1
mov byte [ebp - 0xb5], dl
mov dword [ebp - 0xbc], 0x6992bc60
mov dword [ebp - 0xc0], eax
mov dword [ebp - 0xc4], ecx
mov eax, dword [ebp - 0xbc]
mov ecx, eax
sub ecx, 0x8281f050
mov dword [ebp - 0xc8], eax
mov dword [ebp - 0xcc], ecx
je 0x4053fb
jmp 0x403c86
mov eax, dword [ebp - 0xc8]
sub eax, 0x82a884dd
mov dword [ebp - 0xd0], eax
je 0x4058c5
jmp 0x403ca2
mov eax, dword [ebp - 0xc8]
sub eax, 0x82e5b70a
mov dword [ebp - 0xd4], eax
je 0x40504f
jmp 0x403cbe
mov eax, dword [ebp - 0xc8]
sub eax, 0x86783483
mov dword [ebp - 0xd8], eax
je 0x407cea
jmp 0x403cda
mov eax, dword [ebp - 0xc8]
sub eax, 0x872505f4
mov dword [ebp - 0xdc], eax
je 0x4076a1
jmp 0x403cf6
mov eax, dword [ebp - 0xc8]
sub eax, 0x8b7f99b0
mov dword [ebp - 0xe0], eax
je 0x406026
jmp 0x403d12
mov eax, dword [ebp - 0xc8]
sub eax, 0x8da67dd9
mov dword [ebp - 0xe4], eax
je 0x4060ce
jmp 0x403d2e
mov eax, dword [ebp - 0xc8]
sub eax, 0x8e3de14b
mov dword [ebp - 0xe8], eax
je 0x405ec6
jmp 0x403d4a
mov eax, dword [ebp - 0xc8]
sub eax, 0x8e88af68
mov dword [ebp - 0xec], eax
je 0x4071cb
jmp 0x403d66
mov eax, dword [ebp - 0xc8]
sub eax, 0x8f4aa324
mov dword [ebp - 0xf0], eax
je 0x407a37
jmp 0x403d82
mov eax, dword [ebp - 0xc8]
sub eax, 0x90cb503e
mov dword [ebp - 0xf4], eax
je 0x405f39
jmp 0x403d9e
mov eax, dword [ebp - 0xc8]
sub eax, 0x91ac9c1b
mov dword [ebp - 0xf8], eax
je 0x4059b1
jmp 0x403dba
mov eax, dword [ebp - 0xc8]
sub eax, 0x9369bd9c
mov dword [ebp - 0xfc], eax
je 0x407ad0
jmp 0x403dd6
mov eax, dword [ebp - 0xc8]
sub eax, 0x96073f41
mov dword [ebp - 0x100], eax
je 0x405c63
jmp 0x403df2
mov eax, dword [ebp - 0xc8]
sub eax, 0x96d96ed1
mov dword [ebp - 0x104], eax
je 0x407387
jmp 0x403e0e
mov eax, dword [ebp - 0xc8]
sub eax, 0x96eebb12
mov dword [ebp - 0x108], eax
je 0x407182
jmp 0x403e2a
mov eax, dword [ebp - 0xc8]
sub eax, 0x9ad51ad3
mov dword [ebp - 0x10c], eax
je 0x407e6a
jmp 0x403e46
mov eax, dword [ebp - 0xc8]
sub eax, 0x9fed2b54
mov dword [ebp - 0x110], eax
je 0x407750
jmp 0x403e62
mov eax, dword [ebp - 0xc8]
sub eax, 0xa216e593
mov dword [ebp - 0x114], eax
je 0x405a2c
jmp 0x403e7e
mov eax, dword [ebp - 0xc8]
sub eax, 0xa3081d95
mov dword [ebp - 0x118], eax
je 0x406575
jmp 0x403e9a
mov eax, dword [ebp - 0xc8]
sub eax, 0xa3a1fdf7
mov dword [ebp - 0x11c], eax
je 0x405c54
jmp 0x403eb6
mov eax, dword [ebp - 0xc8]
sub eax, 0xa55bf4e0
mov dword [ebp - 0x120], eax
je 0x40506c
jmp 0x403ed2
mov eax, dword [ebp - 0xc8]
sub eax, 0xa6ff7119
mov dword [ebp - 0x124], eax
je 0x406d45
jmp 0x403eee
mov eax, dword [ebp - 0xc8]
sub eax, 0xa76b0258
mov dword [ebp - 0x128], eax
je 0x40760f
jmp 0x403f0a
mov eax, dword [ebp - 0xc8]
sub eax, 0xa79b9b79
mov dword [ebp - 0x12c], eax
je 0x406caa
jmp 0x403f26
mov eax, dword [ebp - 0xc8]
sub eax, 0xaa985aa0
mov dword [ebp - 0x130], eax
je 0x407e3d
jmp 0x403f42
mov eax, dword [ebp - 0xc8]
sub eax, 0xabe52036
mov dword [ebp - 0x134], eax
je 0x40519c
jmp 0x403f5e
mov eax, dword [ebp - 0xc8]
sub eax, 0xadb312f2
mov dword [ebp - 0x138], eax
je 0x405da5
jmp 0x403f7a
mov eax, dword [ebp - 0xc8]
sub eax, 0xb1b8461c
mov dword [ebp - 0x13c], eax
je 0x405a94
jmp 0x403f96
mov eax, dword [ebp - 0xc8]
sub eax, 0xb2300c17
mov dword [ebp - 0x140], eax
je 0x4052ef
jmp 0x403fb2
mov eax, dword [ebp - 0xc8]
sub eax, 0xb33cc710
mov dword [ebp - 0x144], eax
je 0x40606f
jmp 0x403fce
mov eax, dword [ebp - 0xc8]
sub eax, 0xb3e41931
mov dword [ebp - 0x148], eax
je 0x405282
jmp 0x403fea
mov eax, dword [ebp - 0xc8]
sub eax, 0xb4018b23
mov dword [ebp - 0x14c], eax
je 0x405530
jmp 0x404006
mov eax, dword [ebp - 0xc8]
sub eax, 0xb6ff974b
mov dword [ebp - 0x150], eax
je 0x40695a
jmp 0x404022
mov eax, dword [ebp - 0xc8]
sub eax, 0xba1a157f
mov dword [ebp - 0x154], eax
je 0x4065e9
jmp 0x40403e
mov eax, dword [ebp - 0xc8]
sub eax, 0xbc9cb885
mov dword [ebp - 0x158], eax
je 0x4058a8
jmp 0x40405a
mov eax, dword [ebp - 0xc8]
sub eax, 0xbf07bca9
mov dword [ebp - 0x15c], eax
je 0x405640
jmp 0x404076
mov eax, dword [ebp - 0xc8]
sub eax, 0xbf93b039
mov dword [ebp - 0x160], eax
je 0x406d71
jmp 0x404092
mov eax, dword [ebp - 0xc8]
sub eax, 0xbfdf5080
mov dword [ebp - 0x164], eax
je 0x406311
jmp 0x4040ae
mov eax, dword [ebp - 0xc8]
sub eax, 0xc51a1bd0
mov dword [ebp - 0x168], eax
je 0x406e2f
jmp 0x4040ca
mov eax, dword [ebp - 0xc8]
sub eax, 0xc66d63ed
mov dword [ebp - 0x16c], eax
je 0x4062c1
jmp 0x4040e6
mov eax, dword [ebp - 0xc8]
sub eax, 0xc9d84916
mov dword [ebp - 0x170], eax
je 0x40629e
jmp 0x404102
mov eax, dword [ebp - 0xc8]
sub eax, 0xcb101118
mov dword [ebp - 0x174], eax
je 0x407ca2
jmp 0x40411e
mov eax, dword [ebp - 0xc8]
sub eax, 0xcc9de790
mov dword [ebp - 0x178], eax
je 0x405a65
jmp 0x40413a
mov eax, dword [ebp - 0xc8]
sub eax, 0xcdb64081
mov dword [ebp - 0x17c], eax
je 0x4068ce
jmp 0x404156
mov eax, dword [ebp - 0xc8]
sub eax, 0xd3d826a0
mov dword [ebp - 0x180], eax
je 0x40782c
jmp 0x404172
mov eax, dword [ebp - 0xc8]
sub eax, 0xd518b830
mov dword [ebp - 0x184], eax
je 0x405b91
jmp 0x40418e
mov eax, dword [ebp - 0xc8]
sub eax, 0xd5b39a31
mov dword [ebp - 0x188], eax
je 0x40669a
jmp 0x4041aa
mov eax, dword [ebp - 0xc8]
sub eax, 0xd5e855ec
mov dword [ebp - 0x18c], eax
je 0x4077a0
jmp 0x4041c6
mov eax, dword [ebp - 0xc8]
sub eax, 0xd60ccc3b
mov dword [ebp - 0x190], eax
je 0x406158
jmp 0x4041e2
mov eax, dword [ebp - 0xc8]
sub eax, 0xd727c220
mov dword [ebp - 0x194], eax
je 0x40733e
jmp 0x4041fe
mov eax, dword [ebp - 0xc8]
sub eax, 0xd797fdb1
mov dword [ebp - 0x198], eax
je 0x407e9b
jmp 0x40421a
mov eax, dword [ebp - 0xc8]
sub eax, 0xd8ae67a8
mov dword [ebp - 0x19c], eax
je 0x406599
jmp 0x404236
mov eax, dword [ebp - 0xc8]
sub eax, 0xd9a8abcb
mov dword [ebp - 0x1a0], eax
je 0x405365
jmp 0x404252
mov eax, dword [ebp - 0xc8]
sub eax, 0xdb0ef19a
mov dword [ebp - 0x1a4], eax
je 0x406473
jmp 0x40426e
mov eax, dword [ebp - 0xc8]
sub eax, 0xde226559
mov dword [ebp - 0x1a8], eax
je 0x4061ce
jmp 0x40428a
mov eax, dword [ebp - 0xc8]
sub eax, 0xde257ae1
mov dword [ebp - 0x1ac], eax
je 0x406b15
jmp 0x4042a6
mov eax, dword [ebp - 0xc8]
sub eax, 0xe149b861
mov dword [ebp - 0x1b0], eax
je 0x407254
jmp 0x4042c2
mov eax, dword [ebp - 0xc8]
sub eax, 0xe27a7705
mov dword [ebp - 0x1b4], eax
je 0x407263
jmp 0x4042de
mov eax, dword [ebp - 0xc8]
sub eax, 0xe2883672
mov dword [ebp - 0x1b8], eax
je 0x405cd2
jmp 0x4042fa
mov eax, dword [ebp - 0xc8]
sub eax, 0xe44c2e8b
mov dword [ebp - 0x1bc], eax
je 0x405740
jmp 0x404316
mov eax, dword [ebp - 0xc8]
sub eax, 0xe4f0f9fa
mov dword [ebp - 0x1c0], eax
je 0x406942
jmp 0x404332
mov eax, dword [ebp - 0xc8]
sub eax, 0xe7ef25cf
mov dword [ebp - 0x1c4], eax
je 0x406490
jmp 0x40434e
mov eax, dword [ebp - 0xc8]
sub eax, 0xe8df8339
mov dword [ebp - 0x1c8], eax
je 0x406de0
jmp 0x40436a
mov eax, dword [ebp - 0xc8]
sub eax, 0xe96cf125
mov dword [ebp - 0x1cc], eax
je 0x4057c9
mov al, byte [ebp - 0x17]
test al, 1
mov ecx, 0xa55bf4e0
mov edx, 0xabe52036
cmovne edx, ecx
mov dword [ebp - 0xbc], edx
jmp 0x407fcf
mov eax, dword [0x4103e4]
mov ecx, dword [0x41040c]
mov edx, eax
add edx, 0xb9276ffb
sub edx, 1
sub edx, 0xb9276ffb
imul eax, edx
and eax, 1
cmp eax, 0
sete bl
cmp ecx, 0xa
setl bh
mov al, bl
and al, bh
xor bl, bh
or al, bl
test al, 1
mov ecx, 0x661504ce
mov edx, 0x1fbed205
cmovne edx, ecx
mov dword [ebp - 0xbc], edx
jmp 0x407fcf
xor eax, eax
mov ecx, dword [ebp - 0xb0]
mov ecx, dword [ecx]
mov edx, dword [ebp - 0xa0]
mov edx, dword [edx]
sub eax, 0x9c
add edx, eax
sub esp, 0x10
lea eax, str._s_DEVMODE_size_d__DriverExtralSize_d_n
mov dword [esp], eax
mov dword [esp + 4], ecx
mov dword [esp + 8], 0x9c
mov dword [esp + 0xc], edx
call sym.dbg_log_char_const__..._
add esp, 0x10
mov eax, dword [ebp - 0xa0]
mov eax, dword [eax]
sub esp, 8
mov dword [esp], 1
mov dword [esp + 4], eax
call sub.msvcrt.dll_calloc
add esp, 8
mov ecx, dword [ebp - 0xa4]
mov dword [ecx], eax
mov dword [ebp - 0xbc], 0x21c9ef77
jmp 0x407fcf
mov eax, dword [ebp - 0xa4]
mov eax, dword [eax]
mov eax, dword [eax + 0x28]
sub esp, 4
mov dword [esp], eax
call sym.DumpPrinterCaps_unsigned_long_
add esp, 4
mov dword [ebp - 0xbc], 0xb2300c17
jmp 0x407fcf
mov eax, dword [0x4103e4]
mov ecx, dword [0x41040c]
mov edx, eax
sub edx, 0xf06a8fef
sub edx, 1
add edx, 0xf06a8fef
imul eax, edx
and eax, 1
cmp eax, 0
sete bl
cmp ecx, 0xa
setl bh
mov al, bl
xor al, 0xff
mov ah, bh
xor ah, 0xff
mov cl, 1
xor cl, 1
mov ch, al
and ch, 0xff
and bl, cl
mov dl, ah
and dl, 0xff
and bh, cl
or ch, bl
or dl, bh
xor ch, dl
or al, ah
xor al, 0xff
or cl, 1
and al, cl
or ch, al
test ch, 1
mov esi, 0xd9a8abcb
mov edi, 0x8f4aa324
cmovne edi, esi
mov dword [ebp - 0xbc], edi
jmp 0x407fcf
sub esp, 4
lea eax, str.PAGESIZE
mov dword [esp], eax
call sub.msvcrt.dll_getenv
add esp, 4
mov ecx, dword [ebp - 0x98]
mov dword [ecx], eax
cmp eax, 0
setne dl
and dl, 1
mov byte [ebp - 0x16], dl
mov eax, dword [0x4103e4]
mov ecx, dword [0x41040c]
mov esi, eax
add esi, 0xcde112
sub esi, 1
sub esi, 0xcde112
imul eax, esi
and eax, 1
cmp eax, 0
sete dl
cmp ecx, 0xa
setl dh
mov bl, dl
and bl, dh
xor dl, dh
or bl, dl
test bl, 1
mov eax, 0x88bca61
mov ecx, 0x8f4aa324
cmovne ecx, eax
mov dword [ebp - 0xbc], ecx
jmp 0x407fcf
xor eax, eax
mov ecx, dword [0x4103e4]
mov edx, dword [0x41040c]
sub eax, 1
mov esi, ecx
add esi, eax
imul ecx, esi
and ecx, 1
cmp ecx, 0
sete bl
cmp edx, 0xa
setl bh
mov al, bl
and al, bh
xor bl, bh
or al, bl
test al, 1
mov ecx, 0x168ff60
mov edx, 0xfc2d355a
cmovne edx, ecx
mov dword [ebp - 0xbc], edx
jmp 0x407fcf
sub esp, 4
lea eax, [0x40f116]
mov dword [esp], eax
call sub.msvcrt.dll_getenv
add esp, 4
mov ecx, dword [ebp - 0x98]
mov dword [ecx], eax
cmp eax, 0
mov eax, 0x1a31d504
mov ecx, 0xdc77c4d
cmovne ecx, eax
mov dword [ebp - 0xbc], ecx
jmp 0x407fcf
xor eax, eax
mov ecx, dword [0x4103e4]
mov edx, dword [0x41040c]
sub eax, 1
mov esi, ecx
add esi, eax
imul ecx, esi
and ecx, 1
cmp ecx, 0
sete bl
cmp edx, 0xa
setl bh
mov al, bl
xor al, 0xff
mov ah, bh
xor ah, 0xff
mov cl, 1
xor cl, 1
mov ch, al
and ch, 0xff
and bl, cl
mov dl, ah
and dl, 0xff
and bh, cl
or ch, bl
or dl, bh
xor ch, dl
or al, ah
xor al, 0xff
or cl, 1
and al, cl
or ch, al
test ch, 1
mov esi, 0x6d40bcb0
mov edi, 0x13a8aa7d
cmovne edi, esi
mov dword [ebp - 0xbc], edi
jmp 0x407fcf
mov eax, dword [ebp - 0x98]
mov eax, dword [eax]
sub esp, 4
mov dword [esp], eax
call sub.msvcrt.dll_atoi
add esp, 4
mov cx, ax
mov eax, dword [ebp - 0xa4]
mov eax, dword [eax]
mov word [eax + 0x40], cx
mov eax, dword [ebp - 0xa4]
mov eax, dword [eax]
mov edx, dword [eax + 0x28]
mov esi, edx
and esi, 0x2000
xor edx, 0x2000
or esi, edx
mov dword [eax + 0x28], esi
mov dword [ebp - 0xbc], 0xdc77c4d
jmp 0x407fcf
mov eax, dword [ebp - 0xa4]
mov eax, dword [eax]
mov word [eax + 0x3e], 3
mov dword [ebp - 0xbc], 0x82a884dd
jmp 0x407fcf
xor eax, eax
mov ecx, dword [0x4103e4]
mov edx, dword [0x41040c]
sub eax, 1
mov esi, ecx
add esi, eax
imul ecx, esi
and ecx, 1
cmp ecx, 0
sete bl
cmp edx, 0xa
setl bh
mov al, bl
xor al, 0xff
mov ah, bh
xor ah, 0xff
mov cl, 1
xor cl, 1
mov ch, al
and ch, 0xff
and bl, cl
mov dl, ah
and dl, 0xff
and bh, cl
or ch, bl
or dl, bh
xor ch, dl
or al, ah
xor al, 0xff
or cl, 1
and al, cl
or ch, al
test ch, 1
mov esi, 0x1d2aff76
mov edi, 0x9369bd9c
cmovne edi, esi
mov dword [ebp - 0xbc], edi
jmp 0x407fcf
mov eax, dword [ebp - 0xac]
mov eax, dword [eax]
sub esp, 4
mov dword [esp], eax
call sub.WINSPOOL.DRV_ClosePrinter
xor ecx, ecx
mov edx, dword [ebp - 0xb0]
mov edx, dword [edx]
mov esi, dword [ebp - 0xa4]
mov esi, dword [esi]
sub esp, 0x10
mov dword [esp], 0
mov dword [esp + 4], edx
mov dword [esp + 8], 0
mov dword [esp + 0xc], esi
mov dword [ebp - 0x350], eax
mov dword [ebp - 0x354], ecx
call dword [sym.imp.GDI32.dll_CreateDCA]
xor ecx, ecx
mov edx, dword [ebp - 0xa8]
mov dword [edx], eax
mov eax, dword [ebp - 0xa8]
cmp ecx, dword [eax]
mov eax, 0xa216e593
mov ecx, 0xcc9de790
cmove ecx, eax
mov dword [ebp - 0xbc], ecx
jmp 0x407fcf
call dword [sym.imp.KERNEL32.dll_GetLastError]
sub esp, 8
lea ecx, str.failed_to_CreateDC:_d_n
mov dword [esp], ecx
mov dword [esp + 4], eax
call sym.dbg_log_char_const__..._
add esp, 8
mov eax, dword [ebp - 0xb4]
mov dword [eax], 0
mov dword [ebp - 0xbc], 0x9fed2b54
jmp 0x407fcf
mov eax, dword [ebp - 0xa8]
mov eax, dword [eax]
sub esp, 8
lea ecx, str.CreateDC_got_hdc_08x_n
mov dword [esp], ecx
mov dword [esp + 4], eax
call sym.dbg_log_char_const__..._
add esp, 8
mov dword [ebp - 0xbc], 0xb1b8461c
jmp 0x407fcf
mov eax, dword [ebp - 0x88]
mov dword [eax], 0
mov eax, dword [ebp - 0xa8]
mov eax, dword [eax]
sub esp, 8
mov dword [esp], eax
mov dword [esp + 4], 8
call dword [sym.imp.GDI32.dll_GetDeviceCaps]
mov ecx, dword [ebp - 0x8c]
mov dword [ecx], eax
mov eax, dword [ebp - 0xa8]
mov eax, dword [eax]
sub esp, 8
mov dword [esp], eax
mov dword [esp + 4], 0xa
call dword [sym.imp.GDI32.dll_GetDeviceCaps]
mov ecx, dword [ebp - 0x88]
mov dword [ecx], eax
mov eax, dword [ebp - 0x8c]
mov eax, dword [eax]
mov ecx, dword [ebp - 0x88]
mov ecx, dword [ecx]
sub esp, 0xc
lea edx, str.Device_printable_area___d_x__d_n
mov dword [esp], edx
mov dword [esp + 4], eax
mov dword [esp + 8], ecx
call sym.dbg_log_char_const__..._
add esp, 0xc
mov eax, dword [ebp - 0x9c]
mov dword [eax], 0x14
mov eax, dword [ebp - 0x9c]
lea ecx, str.My_Document
mov dword [eax + 4], ecx
mov eax, dword [ebp - 0x9c]
mov dword [eax + 8], 0
mov eax, dword [ebp - 0x9c]
lea ecx, [0x40f0d0]
mov dword [eax + 0xc], ecx
mov eax, dword [ebp - 0x9c]
mov dword [eax + 0x10], 0
mov eax, dword [ebp - 0xa8]
mov eax, dword [eax]
mov ecx, dword [ebp - 0x9c]
sub esp, 8
mov dword [esp], eax
mov dword [esp + 4], ecx
call dword [sym.imp.GDI32.dll_StartDocA]
cmp eax, 0
mov eax, 0xd518b830
mov ecx, 0x96073f41
cmovle ecx, eax
mov dword [ebp - 0xbc], ecx
jmp 0x407fcf
xor eax, eax
mov ecx, dword [0x4103e4]
mov edx, dword [0x41040c]
sub eax, 1
mov esi, ecx
add esi, eax
imul ecx, esi
and ecx, 1
cmp ecx, 0
sete bl
cmp edx, 0xa
setl bh
mov al, bl
and al, bh
xor bl, bh
or al, bl
test al, 1
mov ecx, 0x175d1fca
mov edx, 0x7c43359e
cmovne edx, ecx
mov dword [ebp - 0xbc], edx
jmp 0x407fcf
mov dword [ebp - 0xbc], 0x9fed2b54
jmp 0x407fcf
xor eax, eax
mov ecx, dword [0x4103e4]
mov edx, dword [0x41040c]
sub eax, 1
mov esi, ecx
add esi, eax
imul ecx, esi
and ecx, 1
cmp ecx, 0
sete bl
cmp edx, 0xa
setl bh
mov al, bl
xor al, 0xff
mov ah, bh
xor ah, 0xff
mov cl, 1
xor cl, 0
mov ch, al
and ch, 0
and bl, cl
mov dl, ah
and dl, 0
and bh, cl
or ch, bl
or dl, bh
xor ch, dl
or al, ah
xor al, 0xff
or cl, 0
and al, cl
or ch, al
test ch, 1
mov esi, 0xe2883672
mov edi, 0xf4789792
cmovne edi, esi
mov dword [ebp - 0xbc], edi
jmp 0x407fcf
xor eax, eax
mov ecx, dword [ebp - 0x58]
mov dword [ecx], 0
mov ecx, dword [ebp - 0x54]
mov dword [ecx], 0
mov ecx, dword [ebp - 0x50]
mov dword [ecx], 0
sub esp, 4
mov dword [esp], 0
mov dword [ebp - 0x358], eax
call dword [0x40e094]
add esp, 4
xor ecx, ecx
mov edx, dword [ebp - 0x4c]
mov dword [edx], eax
sub esp, 4
mov dword [esp], 0
mov dword [ebp - 0x35c], ecx
call dword [0x40e094]
mov dword [esp], eax
call sub.msvcrt.dll__fileno
sub esp, 4
mov dword [esp], eax
mov dword [esp + 4], 0x8000
call sub.msvcrt.dll__setmode
add esp, 8
xor ecx, ecx
mov edx, dword [ebp - 0x5c]
mov dword [edx], 0
mov edx, dword [ebp - 0x60]
mov dword [edx], 0
mov edx, dword [0x4103e4]
mov esi, dword [0x41040c]
sub ecx, 1
mov edi, edx
add edi, ecx
imul edx, edi
and edx, 1
cmp edx, 0
sete bl
cmp esi, 0xa
setl bh
mov cl, bl
and cl, bh
xor bl, bh
or cl, bl
test cl, 1
mov edx, 0xadb312f2
mov esi, 0xf4789792
cmovne esi, edx
mov dword [ebp - 0xbc], esi
mov dword [ebp - 0x360], eax
jmp 0x407fcf
mov dword [ebp - 0xbc], 0xf9060eed
jmp 0x407fcf
sub esp, 4
lea eax, str.read_pipe_error._n
mov dword [esp], eax
call sym.dbg_log_char_const__..._
add esp, 4
mov dword [ebp - 0xbc], 0x2ec327cd
jmp 0x407fcf
xor eax, eax
mov ecx, dword [ebp - 0x5c]
mov ecx, dword [ecx]
mov edx, dword [ebp - 0x60]
mov edx, dword [edx]
sub eax, ecx
sub edx, eax
mov eax, dword [ebp - 0x60]
mov dword [eax], edx
mov eax, dword [ebp - 0xa8]
mov eax, dword [eax]
sub esp, 4
mov dword [esp], eax
call dword [sym.imp.GDI32.dll_StartPage]
xor ecx, ecx
cmp eax, 0
setle bl
and bl, 1
mov byte [ebp - 0x14], bl
mov eax, dword [0x4103e4]
mov edx, dword [0x41040c]
sub ecx, 1
mov esi, eax
add esi, ecx
imul eax, esi
and eax, 1
cmp eax, 0
sete bl
cmp edx, 0xa
setl bh
mov al, bl
and al, bh
xor bl, bh
or al, bl
test al, 1
mov ecx, 0xf6b9050a
mov edx, 0x42f092cb
cmovne edx, ecx
mov dword [ebp - 0xbc], edx
jmp 0x407fcf
mov eax, dword [ebp - 0x84]
movzx eax, word [eax]
cmp eax, 0x4d42
mov eax, 0x21690acb
mov ecx, 0xb33cc710
cmovne ecx, eax
mov dword [ebp - 0xbc], ecx
jmp 0x407fcf
mov eax, dword [ebp - 0x84]
mov eax, dword [eax + 2]
sub esp, 8
lea ecx, str.BMP_file_size__d_n
mov dword [esp], ecx
mov dword [esp + 4], eax
call sym.dbg_log_char_const__..._
add esp, 8
xor eax, eax
mov ecx, dword [ebp - 0x84]
mov ecx, dword [ecx + 2]
sub eax, 0xe
add ecx, eax
sub esp, 4
mov dword [esp], ecx
call sym._malloc
add esp, 4
mov ecx, dword [ebp - 0x80]
mov dword [ecx], eax
cmp eax, 0
mov eax, 0x15c80c66
mov ecx, 0x8da67dd9
cmovne ecx, eax
mov dword [ebp - 0xbc], ecx
jmp 0x407fcf
sub esp, 4
lea eax, str.out_of_memory._n
mov dword [esp], eax
call sym.dbg_log_char_const__..._
add esp, 4
mov dword [ebp - 0xbc], 0x2ec327cd
jmp 0x407fcf
mov eax, dword [0x4103e4]
mov ecx, dword [0x41040c]
mov edx, eax
sub edx, 0x5eefcc26
sub edx, 1
add edx, 0x5eefcc26
imul eax, edx
and eax, 1
cmp eax, 0
sete bl
cmp ecx, 0xa
setl bh
mov al, bl
xor al, 0xff
mov ah, bh
xor ah, 0xff
mov cl, 1
xor cl, 0
mov ch, al
and ch, 0
and bl, cl
mov dl, ah
and dl, 0
and bh, cl
or ch, bl
or dl, bh
xor ch, dl
or al, ah
xor al, 0xff
or cl, 0
and al, cl
or ch, al
test ch, 1
mov esi, 0xde226559
mov edi, 0xcb101118
cmovne edi, esi
mov dword [ebp - 0xbc], edi
jmp 0x407fcf
xor eax, eax
mov ecx, dword [ebp - 0x5c]
mov ecx, dword [ecx]
mov edx, dword [ebp - 0x84]
mov edx, dword [edx + 2]
sub eax, 0xe
add edx, eax
sub esp, 0xc
lea eax, str.BMP_file_corrupt__d__d_n
mov dword [esp], eax
mov dword [esp + 4], ecx
mov dword [esp + 8], edx
call sym.dbg_log_char_const__..._
add esp, 0xc
xor eax, eax
mov ecx, dword [0x4103e4]
mov edx, dword [0x41040c]
sub eax, 1
mov esi, ecx
add esi, eax
imul ecx, esi
and ecx, 1
cmp ecx, 0
sete bl
cmp edx, 0xa
setl bh
mov al, bl
and al, bh
xor bl, bh
or al, bl
test al, 1
mov ecx, 0x48def4ae
mov edx, 0xcb101118
cmovne edx, ecx
mov dword [ebp - 0xbc], edx
jmp 0x407fcf
sub esp, 4
lea eax, str.unsupported_BMP_file_header._n
mov dword [esp], eax
call sym.dbg_log_char_const__..._
add esp, 4
mov dword [ebp - 0xbc], 0x2ec327cd
jmp 0x407fcf
mov eax, dword [0x4103e4]
mov ecx, dword [0x41040c]
mov edx, eax
sub edx, 0xed5518d9
sub edx, 1
add edx, 0xed5518d9
imul eax, edx
and eax, 1
cmp eax, 0
sete bl
cmp ecx, 0xa
setl bh
mov al, bl
and al, bh
xor bl, bh
or al, bl
test al, 1
mov ecx, 0xbfdf5080
mov edx, 0x86783483
cmovne edx, ecx
mov dword [ebp - 0xbc], edx
jmp 0x407fcf
mov eax, dword [ebp - 0x80]
mov eax, dword [eax]
mov ecx, dword [ebp - 0x48]
mov dword [ecx], eax
mov eax, dword [ebp - 0x48]
mov eax, dword [eax]
mov eax, dword [eax + 4]
mov ecx, dword [ebp - 0x7c]
mov dword [ecx], eax
mov eax, dword [ebp - 0x48]
mov eax, dword [eax]
mov eax, dword [eax + 8]
mov ecx, dword [ebp - 0x78]
mov dword [ecx], eax
mov eax, dword [ebp - 0x48]
mov eax, dword [eax]
mov eax, dword [eax + 0x10]
mov ecx, dword [ebp - 0x70]
mov dword [ecx], eax
mov eax, dword [ebp - 0x48]
mov eax, dword [eax]
mov eax, dword [eax + 0x20]
mov ecx, dword [ebp - 0x6c]
mov dword [ecx], eax
mov eax, dword [ebp - 0x7c]
mov eax, dword [eax]
mov ecx, dword [ebp - 0x78]
mov ecx, dword [ecx]
mov edx, dword [ebp - 0x48]
mov edx, dword [edx]
movzx edx, word [edx + 0xc]
mov esi, dword [ebp - 0x48]
mov esi, dword [esi]
movzx esi, word [esi + 0xe]
mov edi, dword [ebp - 0x70]
mov edi, dword [edi]
mov ebx, dword [ebp - 0x48]
mov ebx, dword [ebx]
mov ebx, dword [ebx + 0x14]
mov dword [ebp - 0x368], eax
mov eax, dword [ebp - 0x48]
mov eax, dword [eax]
mov eax, dword [eax + 0x18]
mov dword [ebp - 0x36c], eax
mov eax, dword [ebp - 0x48]
mov eax, dword [eax]
mov eax, dword [eax + 0x1c]
mov dword [ebp - 0x370], eax
mov eax, dword [ebp - 0x6c]
mov eax, dword [eax]
mov dword [ebp - 0x374], eax
mov eax, dword [ebp - 0x48]
mov eax, dword [eax]
mov eax, dword [eax + 0x24]
sub esp, 0x2c
mov dword [ebp - 0x378], eax
lea eax, str.size___d_d___plane:_d__bpp:_d__compress:_d_n____________________pixel_size:0x_x__resolution___d_d___color___d__d__n
mov dword [esp], eax
mov eax, dword [ebp - 0x368]
mov dword [esp + 4], eax
mov dword [esp + 8], ecx
mov dword [esp + 0xc], edx
mov dword [esp + 0x10], esi
mov dword [esp + 0x14], edi
mov dword [esp + 0x18], ebx
mov eax, dword [ebp - 0x36c]
mov dword [esp + 0x1c], eax
mov eax, dword [ebp - 0x370]
mov dword [esp + 0x20], eax
mov eax, dword [ebp - 0x374]
mov dword [esp + 0x24], eax
mov eax, dword [ebp - 0x378]
mov dword [esp + 0x28], eax
call sym.dbg_log_char_const__..._
add esp, 0x2c
mov eax, dword [ebp - 0x48]
mov eax, dword [eax]
movzx eax, word [eax + 0xe]
cmp eax, 8
setle al
and al, 1
mov byte [ebp - 0x13], al
mov ecx, dword [0x4103e4]
mov edx, dword [0x41040c]
mov esi, ecx
add esi, 0x8e3756f5
sub esi, 1
sub esi, 0x8e3756f5
imul ecx, esi
and ecx, 1
cmp ecx, 0
sete al
cmp edx, 0xa
setl ah
mov cl, al
and cl, ah
xor al, ah
or cl, al
test cl, 1
mov edx, 0xdb0ef19a
mov esi, 0x86783483
cmovne esi, edx
mov dword [ebp - 0xbc], esi
jmp 0x407fcf
mov al, byte [ebp - 0x13]
test al, 1
mov ecx, 0xe7ef25cf
mov edx, 0xd8ae67a8
cmovne edx, ecx
mov dword [ebp - 0xbc], edx
jmp 0x407fcf
xor eax, eax
mov ecx, dword [0x4103e4]
mov edx, dword [0x41040c]
sub eax, 1
mov esi, ecx
add esi, eax
imul ecx, esi
and ecx, 1
cmp ecx, 0
sete bl
cmp edx, 0xa
setl bh
mov al, bl
xor al, 0xff
mov ah, bh
xor ah, 0xff
mov cl, 1
xor cl, 1
mov ch, al
and ch, 0xff
and bl, cl
mov dl, ah
and dl, 0xff
and bh, cl
or ch, bl
or dl, bh
xor ch, dl
or al, ah
xor al, 0xff
or cl, 1
and al, cl
or ch, al
test ch, 1
mov esi, 0xf3e5efbd
mov edi, 0x59a72242
cmovne edi, esi
mov dword [ebp - 0xbc], edi
jmp 0x407fcf
mov eax, dword [ebp - 0x48]
mov eax, dword [eax]
movzx ecx, word [eax + 0xe]
mov eax, 1
shl eax, cl
mov edx, dword [ebp - 0x6c]
mov dword [edx], eax
mov dword [ebp - 0xbc], 0xd8ae67a8
jmp 0x407fcf
mov eax, dword [0x4103e4]
mov ecx, dword [0x41040c]
mov edx, eax
add edx, 0x64372bb4
sub edx, 1
sub edx, 0x64372bb4
imul eax, edx
and eax, 1
cmp eax, 0
sete bl
cmp ecx, 0xa
setl bh
mov al, bl
and al, bh
xor bl, bh
or al, bl
test al, 1
mov ecx, 0xba1a157f
mov edx, 0x1d76ba56
cmovne edx, ecx
mov dword [ebp - 0xbc], edx
jmp 0x407fcf
mov eax, dword [ebp - 0x80]
mov eax, dword [eax]
mov ecx, dword [ebp - 0x74]
add eax, dword [ecx]
mov ecx, dword [ebp - 0x64]
mov dword [ecx], eax
mov eax, dword [ebp - 0x70]
cmp dword [eax], 3
sete dl
and dl, 1
mov byte [ebp - 0x11], dl
mov eax, dword [0x4103e4]
mov ecx, dword [0x41040c]
mov esi, eax
sub esi, 0x3c7a07ae
sub esi, 1
add esi, 0x3c7a07ae
imul eax, esi
and eax, 1
cmp eax, 0
sete dl
cmp ecx, 0xa
setl dh
mov bl, dl
xor bl, 0xff
mov bh, dh
xor bh, 0xff
mov al, 1
xor al, 0
mov ah, bl
and ah, 0
and dl, al
mov cl, bh
and cl, 0
and dh, al
or ah, dl
or cl, dh
xor ah, cl
or bl, bh
xor bl, 0xff
or al, 0
and bl, al
or ah, bl
test ah, 1
mov esi, 0x779e812
mov edi, 0x1d76ba56
cmovne edi, esi
mov dword [ebp - 0xbc], edi
jmp 0x407fcf
mov eax, dword [ebp - 0x64]
mov eax, dword [eax]
add eax, 0xc
mov ecx, dword [ebp - 0x64]
mov dword [ecx], eax
mov dword [ebp - 0xbc], 0x25b6b660
jmp 0x407fcf
mov eax, dword [ebp - 0x40]
mov dword [eax], 0
mov eax, dword [ebp - 0x48]
mov eax, dword [eax]
movzx eax, word [eax + 0xe]
cmp eax, 8
mov eax, 0xea6e6fc0
mov ecx, 0xe4f0f9fa
cmovle ecx, eax
mov dword [ebp - 0xbc], ecx
jmp 0x407fcf
mov eax, dword [ebp - 0x40]
mov dword [eax], 0x2c
mov dword [ebp - 0xbc], 0xb6ff974b
jmp 0x407fcf
mov eax, dword [ebp - 0x40]
mov eax, dword [eax]
sub esp, 4
mov dword [esp], eax
call sym._malloc
add esp, 4
xor ecx, ecx
mov edx, dword [ebp - 0x3c]
mov dword [edx], eax
mov eax, dword [ebp - 0x3c]
mov eax, dword [eax]
mov edx, dword [ebp - 0x40]
mov edx, dword [edx]
sub esp, 0xc
mov dword [esp], eax
mov dword [esp + 4], 0
mov dword [esp + 8], edx
mov dword [ebp - 0x390], ecx
call sub.msvcrt.dll_memset
add esp, 0xc
mov eax, dword [ebp - 0x3c]
mov eax, dword [eax]
mov ecx, dword [ebp - 0x38]
mov dword [ecx], eax
mov eax, dword [ebp - 0x38]
mov eax, dword [eax]
mov dword [eax], 0x28
mov eax, dword [ebp - 0x34]
mov dword [eax], 0
mov eax, dword [ebp - 0x50]
mov eax, dword [eax]
mov ecx, dword [ebp - 0x44]
mov ecx, dword [ecx]
mov edx, dword [ebp - 0x38]
mov edx, dword [edx]
sub esp, 0x1c
mov dword [esp], eax
mov dword [esp + 4], ecx
mov dword [esp + 8], 0
mov dword [esp + 0xc], 0
mov dword [esp + 0x10], 0
mov dword [esp + 0x14], edx
mov dword [esp + 0x18], 0
call dword [sym.imp.GDI32.dll_GetDIBits]
mov ecx, dword [ebp - 0x34]
mov dword [ecx], eax
mov eax, dword [ebp - 0x34]
cmp dword [eax], 0
mov eax, 0x2182e672
mov ecx, 0xde257ae1
cmove ecx, eax
mov dword [ebp - 0xbc], ecx
jmp 0x407fcf
mov eax, dword [ebp - 0x38]
mov eax, dword [eax]
mov dword [eax + 0x10], 0
mov eax, dword [ebp - 0x38]
mov eax, dword [eax]
mov eax, dword [eax + 8]
sub esp, 4
mov dword [esp], eax
call method.std.abs_long_
add esp, 4
mov ecx, dword [ebp - 0x38]
mov ecx, dword [ecx]
mov dword [ecx + 8], eax
mov eax, dword [ebp - 0x48]
mov eax, dword [eax]
mov dx, word [eax + 0xc]
mov eax, dword [ebp - 0x38]
mov eax, dword [eax]
mov word [eax + 0xc], dx
mov eax, dword [ebp - 0x48]
mov eax, dword [eax]
mov dx, word [eax + 0xe]
mov eax, dword [ebp - 0x38]
mov eax, dword [eax]
mov word [eax + 0xe], dx
mov eax, dword [ebp - 0x48]
mov eax, dword [eax]
mov eax, dword [eax + 0x18]
mov ecx, dword [ebp - 0x38]
mov ecx, dword [ecx]
mov dword [ecx + 0x18], eax
mov eax, dword [ebp - 0x48]
mov eax, dword [eax]
mov eax, dword [eax + 0x1c]
mov ecx, dword [ebp - 0x38]
mov ecx, dword [ecx]
mov dword [ecx + 0x1c], eax
mov eax, dword [ebp - 0x48]
mov eax, dword [eax]
mov eax, dword [eax + 0x20]
mov ecx, dword [ebp - 0x38]
mov ecx, dword [ecx]
mov dword [ecx + 0x20], eax
mov eax, dword [ebp - 0x48]
mov eax, dword [eax]
mov eax, dword [eax + 0x24]
mov ecx, dword [ebp - 0x38]
mov ecx, dword [ecx]
mov dword [ecx + 0x24], eax
mov eax, dword [ebp - 0x30]
mov dword [eax], 0
mov eax, dword [ebp - 0x38]
mov eax, dword [eax]
mov eax, dword [eax + 4]
mov ecx, dword [ebp - 0x38]
mov ecx, dword [ecx]
movzx ecx, word [ecx + 0xe]
imul eax, ecx
sub eax, 0x9344404d
add eax, 0x1f
add eax, 0x9344404d
xor eax, 0xffffffff
mov ecx, 0xffffffff
mov esi, ecx
xor esi, 0xffffffe0
xor ecx, 0x5caa163c
or eax, esi
or ecx, 0x5caa163c
xor eax, 0xffffffff
and eax, ecx
sar eax, 3
mov ecx, dword [ebp - 0x30]
mov dword [ecx], eax
mov eax, dword [ebp - 0x38]
mov eax, dword [eax]
mov eax, dword [eax + 8]
sub esp, 4
mov dword [esp], eax
call method.std.abs_long_
add esp, 4
mov ecx, dword [ebp - 0x30]
imul eax, dword [ecx]
mov ecx, dword [ebp - 0x38]
mov ecx, dword [ecx]
mov dword [ecx + 0x14], eax
mov eax, dword [ebp - 0x38]
mov eax, dword [eax]
mov eax, dword [eax + 0x14]
sub esp, 4
mov dword [esp], eax
call sym._malloc
add esp, 4
xor ecx, ecx
mov esi, dword [ebp - 0x58]
mov dword [esi], eax
mov eax, dword [ebp - 0x50]
mov eax, dword [eax]
mov esi, dword [ebp - 0x44]
mov esi, dword [esi]
mov edi, dword [ebp - 0x88]
mov edi, dword [edi]
mov ebx, dword [ebp - 0x58]
mov ebx, dword [ebx]
mov edx, dword [ebp - 0x38]
mov edx, dword [edx]
sub esp, 0x1c
mov dword [esp], eax
mov dword [esp + 4], esi
mov dword [esp + 8], 0
mov dword [esp + 0xc], edi
mov dword [esp + 0x10], ebx
mov dword [esp + 0x14], edx
mov dword [esp + 0x18], 0
mov dword [ebp - 0x394], ecx
call dword [sym.imp.GDI32.dll_GetDIBits]
mov ecx, dword [ebp - 0x34]
mov dword [ecx], eax
mov eax, dword [ebp - 0x34]
cmp dword [eax], 0
mov eax, 0xa79b9b79
mov ecx, 0x5b77bcf8
cmove ecx, eax
mov dword [ebp - 0xbc], ecx
jmp 0x407fcf
call dword [sym.imp.KERNEL32.dll_GetLastError]
sub esp, 8
lea ecx, str.GetDIBits_failed:__d_n
mov dword [esp], ecx
mov dword [esp + 4], eax
call sym.dbg_log_char_const__..._
add esp, 8
mov dword [ebp - 0xbc], 0x2ec327cd
jmp 0x407fcf
mov eax, dword [ebp - 0x2c]
mov word [eax], 0x4d42
mov eax, dword [ebp - 0x38]
mov eax, dword [eax]
movzx eax, word [eax + 0xe]
cmp eax, 1
mov eax, 0xbf93b039
mov ecx, 0x451eab2b
cmove ecx, eax
mov dword [ebp - 0xbc], ecx
jmp 0x407fcf
mov eax, dword [ebp - 0x38]
mov eax, dword [eax]
mov eax, dword [eax + 0x14]
mov ecx, 0x1c
sub ecx, 0x612a9107
add ecx, eax
add ecx, 0x612a9107
add ecx, 0xb61d4a19
add ecx, 8
sub ecx, 0xb61d4a19
mov eax, dword [ebp - 0x2c]
mov dword [eax + 2], ecx
mov dword [ebp - 0xbc], 0xe8df8339
jmp 0x407fcf
mov eax, dword [ebp - 0x2c]
mov word [eax + 6], 0
mov eax, dword [ebp - 0x2c]
mov word [eax + 8], 0
mov eax, dword [ebp - 0x38]
mov eax, dword [eax]
movzx eax, word [eax + 0xe]
cmp eax, 1
mov eax, 0xeedb1958
mov ecx, 0xc51a1bd0
cmove ecx, eax
mov dword [ebp - 0xbc], ecx
jmp 0x407fcf
mov eax, dword [ebp - 0x2c]
mov dword [eax + 0xa], 0x1c
mov dword [ebp - 0xbc], 0xf2f472e
jmp 0x407fcf
xor eax, eax
mov ecx, dword [0x4103e4]
mov edx, dword [0x41040c]
sub eax, 1
mov esi, ecx
add esi, eax
imul ecx, esi
and ecx, 1
cmp ecx, 0
sete bl
cmp edx, 0xa
setl bh
mov al, bl
and al, bh
xor bl, bh
or al, bl
test al, 1
mov ecx, 0x8e88af68
mov edx, 0x9ad51ad3
cmovne edx, ecx
mov dword [ebp - 0xbc], edx
jmp 0x407fcf
mov eax, dword [ebp - 0x3c]
mov eax, dword [eax]
sub esp, 4
mov dword [esp], eax
call sub.msvcrt.dll_free
add esp, 4
mov eax, dword [0x4103e4]
mov ecx, dword [0x41040c]
mov edx, eax
add edx, 0x3b881336
sub edx, 1
sub edx, 0x3b881336
imul eax, edx
and eax, 1
cmp eax, 0
sete bl
cmp ecx, 0xa
setl bh
mov al, bl
xor al, 0xff
mov ah, bh
xor ah, 0xff
mov cl, 1
xor cl, 1
mov ch, al
and ch, 0xff
and bl, cl
mov dl, ah
and dl, 0xff
and bh, cl
or ch, bl
or dl, bh
xor ch, dl
or al, ah
xor al, 0xff
or cl, 1
and al, cl
or ch, al
test ch, 1
mov esi, 0xe149b861
mov edi, 0x9ad51ad3
cmovne edi, esi
mov dword [ebp - 0xbc], edi
jmp 0x407fcf
mov dword [ebp - 0xbc], 0x5bcdae3
jmp 0x407fcf
xor eax, eax
mov ecx, dword [ebp - 0xa8]
mov ecx, dword [ecx]
mov edx, dword [ebp - 0x7c]
mov edx, dword [edx]
mov esi, dword [ebp - 0x78]
mov esi, dword [esi]
mov edi, dword [ebp - 0x7c]
mov edi, dword [edi]
mov ebx, dword [ebp - 0x78]
mov ebx, dword [ebx]
mov dword [ebp - 0x3d4], eax
mov eax, dword [ebp - 0x64]
mov eax, dword [eax]
mov dword [ebp - 0x3d8], eax
mov eax, dword [ebp - 0x80]
mov eax, dword [eax]
sub esp, 0x34
mov dword [esp], ecx
mov dword [esp + 4], 0
mov dword [esp + 8], 0
mov dword [esp + 0xc], edx
mov dword [esp + 0x10], esi
mov dword [esp + 0x14], 0
mov dword [esp + 0x18], 0
mov dword [esp + 0x1c], edi
mov dword [esp + 0x20], ebx
mov ecx, dword [ebp - 0x3d8]
mov dword [esp + 0x24], ecx
mov dword [esp + 0x28], eax
mov dword [esp + 0x2c], 0
mov dword [esp + 0x30], 0xcc0020
call dword [sym.imp.GDI32.dll_StretchDIBits]
mov ecx, dword [ebp - 0x68]
mov dword [ecx], eax
cmp eax, 0
mov eax, 0x49171a47
mov ecx, 0xd727c220
cmove ecx, eax
mov dword [ebp - 0xbc], ecx
jmp 0x407fcf
xor eax, eax
mov ecx, dword [0x4103e4]
mov edx, dword [0x41040c]
sub eax, 1
mov esi, ecx
add esi, eax
imul ecx, esi
and ecx, 1
cmp ecx, 0
sete bl
cmp edx, 0xa
setl bh
mov al, bl
and al, bh
xor bl, bh
or al, bl
test al, 1
mov ecx, 0x96d96ed1
mov edx, 0x5a301854
cmovne edx, ecx
mov dword [ebp - 0xbc], edx
jmp 0x407fcf
xor eax, eax
mov ecx, dword [0x4103e4]
mov edx, dword [0x41040c]
sub eax, 1
mov esi, ecx
add esi, eax
imul ecx, esi
and ecx, 1
cmp ecx, 0
sete bl
cmp edx, 0xa
setl bh
mov al, bl
and al, bh
xor bl, bh
or al, bl
test al, 1
mov ecx, 0xf2f1e2ce
mov edx, 0x5a301854
cmovne edx, ecx
mov dword [ebp - 0xbc], edx
jmp 0x407fcf
mov al, 1
test al, 1
mov ecx, 0xf9060eed
mov edx, 0x2ec327cd
cmovne edx, ecx
mov dword [ebp - 0xbc], edx
jmp 0x407fcf
mov eax, dword [ebp - 0xa4]
mov eax, dword [eax]
sub esp, 4
mov dword [esp], eax
call sub.msvcrt.dll_free
add esp, 4
mov eax, dword [ebp - 0xa8]
mov eax, dword [eax]
sub esp, 4
mov dword [esp], eax
call dword [sym.imp.GDI32.dll_EndDoc]
mov ecx, dword [ebp - 0xa8]
mov ecx, dword [ecx]
sub esp, 4
mov dword [esp], ecx
mov dword [ebp - 0x3ec], eax
call dword [sym.imp.GDI32.dll_DeleteDC]
xor ecx, ecx
mov edx, dword [ebp - 0xb4]
mov dword [edx], 1
mov edx, dword [0x4103e4]
mov esi, dword [0x41040c]
sub ecx, 1
mov edi, edx
add edi, ecx
imul edx, edi
and edx, 1
cmp edx, 0
sete bl
cmp esi, 0xa
setl bh
mov cl, bl
and cl, bh
xor bl, bh
or cl, bl
test cl, 1
mov edx, 0x508bd15b
mov esi, 0xfa8612dc
cmovne esi, edx
mov dword [ebp - 0xbc], esi
mov dword [ebp - 0x3f0], eax
jmp 0x407fcf
mov eax, dword [0x4103e4]
mov ecx, dword [0x41040c]
mov edx, eax
sub edx, 0xf29fcf4a
sub edx, 1
add edx, 0xf29fcf4a
imul eax, edx
and eax, 1
cmp eax, 0
sete bl
cmp ecx, 0xa
setl bh
mov al, bl
and al, bh
xor bl, bh
or al, bl
test al, 1
mov ecx, 0xd5e855ec
mov edx, 0x18800d9
cmovne edx, ecx
mov dword [ebp - 0xbc], edx
jmp 0x407fcf
mov eax, dword [ebp - 0xb4]
mov eax, dword [eax]
mov dword [ebp - 0x10], eax
mov eax, dword [0x4103e4]
mov ecx, dword [0x41040c]
mov edx, eax
sub edx, 0x43264d99
sub edx, 1
add edx, 0x43264d99
imul eax, edx
and eax, 1
cmp eax, 0
sete bl
cmp ecx, 0xa
setl bh
mov al, bl
xor al, 0xff
mov ah, bh
xor ah, 0xff
mov cl, 1
xor cl, 1
mov ch, al
and ch, 0xff
and bl, cl
mov dl, ah
and dl, 0xff
and bh, cl
or ch, bl
or dl, bh
xor ch, dl
or al, ah
xor al, 0xff
or cl, 1
and al, cl
or ch, al
test ch, 1
mov esi, 0x3311af5a
mov edi, 0x18800d9
cmovne edi, esi
mov dword [ebp - 0xbc], edi
jmp 0x407fcf
xor eax, eax
push eax
mov ecx, esp
push eax
mov edx, esp
push eax
mov esi, esp
push eax
mov edi, esp
push eax
mov ebx, esp
sub esp, 0x10
mov dword [ebp - 0x3f4], eax
mov eax, esp
push eax
mov dword [ebp - 0x3f8], eax
mov eax, esp
push eax
mov dword [ebp - 0x3fc], eax
mov eax, esp
sub esp, 0x14
mov dword [ebp - 0x400], eax
mov eax, esp
push eax
mov dword [ebp - 0x404], eax
mov eax, esp
push eax
mov dword [ebp - 0x408], eax
mov eax, esp
push eax
mov dword [ebp - 0x40c], eax
mov eax, esp
push eax
mov dword [ebp - 0x410], eax
mov eax, esp
push eax
mov dword [ebp - 0x414], eax
mov eax, esp
push eax
mov dword [ebp - 0x418], eax
mov eax, esp
mov dword [ebp - 0x41c], eax
mov eax, dword [ebp - 0xc4]
mov dword [edx], eax
mov eax, dword [ebp - 0xc0]
mov dword [esi], eax
mov esi, dword [ebp - 0x3f8]
sub esp, 0xc
mov dword [esp], esi
mov dword [esp + 4], 0
mov dword [esp + 8], 0x10
mov dword [ebp - 0x420], ebx
mov dword [ebp - 0x424], ecx
mov dword [ebp - 0x428], edx
mov dword [ebp - 0x42c], edi
call sub.msvcrt.dll_memset
add esp, 0xc
mov eax, dword [ebp - 0x3fc]
mov dword [eax], 0
mov ecx, dword [ebp - 0x400]
mov dword [ecx], 0
mov edx, dword [ebp - 0x414]
mov dword [edx], 0
mov esi, dword [ebp - 0x418]
mov dword [esi], 0
mov edi, dword [ebp - 0x41c]
mov dword [edi], 0
mov ebx, dword [ebp - 0x428]
mov eax, dword [ebx]
sub esp, 0xc
mov dword [esp], eax
mov eax, dword [ebp - 0x42c]
mov dword [esp + 4], eax
mov dword [esp + 8], 0
call sub.WINSPOOL.DRV_OpenPrinterA
mov dword [ebp - 0xbc], 0x4a83993
mov dword [ebp - 0x430], eax
jmp 0x407fcf
sub esp, 4
lea eax, str.PAGESIZE
mov dword [esp], eax
call sub.msvcrt.dll_getenv
add esp, 4
mov ecx, dword [ebp - 0x98]
mov dword [ecx], eax
mov dword [ebp - 0xbc], 0xd9a8abcb
jmp 0x407fcf
mov eax, dword [ebp - 0xa4]
mov eax, dword [eax]
mov ecx, dword [eax + 0x28]
mov edx, ecx
xor edx, 0xffffffff
mov esi, 0xffffffff
mov edi, esi
xor edi, 0x1000
xor esi, 0x2c24c7de
mov ebx, edx
and ebx, 0x2c24c7de
and ecx, esi
mov dword [ebp - 0x444], eax
mov eax, edi
and eax, 0x2c24c7de
mov dword [ebp - 0x448], eax
mov eax, esi
and eax, 0x1000
or ebx, ecx
mov ecx, dword [ebp - 0x448]
or ecx, eax
xor ebx, ecx
or edx, edi
xor edx, 0xffffffff
or esi, 0x2c24c7de
and edx, esi
or ebx, edx
mov eax, dword [ebp - 0x444]
mov dword [eax + 0x28], ebx
mov dword [ebp - 0xbc], 0x1d2aff76
jmp 0x407fcf
mov eax, dword [ebp - 0x5c]
mov eax, dword [eax]
mov ecx, dword [ebp - 0x84]
mov ecx, dword [ecx + 2]
sub ecx, 0x11268418
sub ecx, 0xe
add ecx, 0x11268418
sub esp, 0xc
lea edx, str.BMP_file_corrupt__d__d_n
mov dword [esp], edx
mov dword [esp + 4], eax
mov dword [esp + 8], ecx
call sym.dbg_log_char_const__..._
add esp, 0xc
mov dword [ebp - 0xbc], 0xde226559
jmp 0x407fcf
mov eax, dword [ebp - 0x80]
mov eax, dword [eax]
mov ecx, dword [ebp - 0x48]
mov dword [ecx], eax
mov eax, dword [ebp - 0x48]
mov eax, dword [eax]
mov eax, dword [eax + 4]
mov ecx, dword [ebp - 0x7c]
mov dword [ecx], eax
mov eax, dword [ebp - 0x48]
mov eax, dword [eax]
mov eax, dword [eax + 8]
mov ecx, dword [ebp - 0x78]
mov dword [ecx], eax
mov eax, dword [ebp - 0x48]
mov eax, dword [eax]
mov eax, dword [eax + 0x10]
mov ecx, dword [ebp - 0x70]
mov dword [ecx], eax
mov eax, dword [ebp - 0x48]
mov eax, dword [eax]
mov eax, dword [eax + 0x20]
mov ecx, dword [ebp - 0x6c]
mov dword [ecx], eax
mov eax, dword [ebp - 0x7c]
mov eax, dword [eax]
mov ecx, dword [ebp - 0x78]
mov ecx, dword [ecx]
mov edx, dword [ebp - 0x48]
mov edx, dword [edx]
movzx edx, word [edx + 0xc]
mov esi, dword [ebp - 0x48]
mov esi, dword [esi]
movzx esi, word [esi + 0xe]
mov edi, dword [ebp - 0x70]
mov edi, dword [edi]
mov ebx, dword [ebp - 0x48]
mov ebx, dword [ebx]
mov ebx, dword [ebx + 0x14]
mov dword [ebp - 0x45c], eax
mov eax, dword [ebp - 0x48]
mov eax, dword [eax]
mov eax, dword [eax + 0x18]
mov dword [ebp - 0x460], eax
mov eax, dword [ebp - 0x48]
mov eax, dword [eax]
mov eax, dword [eax + 0x1c]
mov dword [ebp - 0x464], eax
mov eax, dword [ebp - 0x6c]
mov eax, dword [eax]
mov dword [ebp - 0x468], eax
mov eax, dword [ebp - 0x48]
mov eax, dword [eax]
mov eax, dword [eax + 0x24]
sub esp, 0x2c
mov dword [ebp - 0x46c], eax
lea eax, str.size___d_d___plane:_d__bpp:_d__compress:_d_n____________________pixel_size:0x_x__resolution___d_d___color___d__d__n
mov dword [esp], eax
mov eax, dword [ebp - 0x45c]
mov dword [esp + 4], eax
mov dword [esp + 8], ecx
mov dword [esp + 0xc], edx
mov dword [esp + 0x10], esi
mov dword [esp + 0x14], edi
mov dword [esp + 0x18], ebx
mov eax, dword [ebp - 0x460]
mov dword [esp + 0x1c], eax
mov eax, dword [ebp - 0x464]
mov dword [esp + 0x20], eax
mov eax, dword [ebp - 0x468]
mov dword [esp + 0x24], eax
mov eax, dword [ebp - 0x46c]
mov dword [esp + 0x28], eax
call sym.dbg_log_char_const__..._
add esp, 0x2c
mov eax, dword [ebp - 0x48]
mov dword [ebp - 0xbc], 0xbfdf5080
mov dword [ebp - 0x470], eax
jmp 0x407fcf
call dword [sym.imp.KERNEL32.dll_GetLastError]
sub esp, 8
lea ecx, str.2._failed:__d_n
mov dword [esp], ecx
mov dword [esp + 4], eax
call sym.dbg_log_char_const__..._
add esp, 8
mov dword [ebp - 0xbc], 0x2ca5df4b
jmp 0x407fcf
mov eax, dword [ebp - 0x3c]
mov eax, dword [eax]
sub esp, 4
mov dword [esp], eax
call sub.msvcrt.dll_free
add esp, 4
mov dword [ebp - 0xbc], 0x8e88af68
jmp 0x407fcf
mov eax, dword [ebp - 0x68]
mov eax, dword [eax]
sub esp, 8
lea ecx, str.copy__d_scanline_n
mov dword [esp], ecx
mov dword [esp + 4], eax
call sym.dbg_log_char_const__..._
add esp, 8
mov eax, dword [ebp - 0x80]
mov eax, dword [eax]
sub esp, 4
mov dword [esp], eax
call sub.msvcrt.dll_free
add esp, 4
mov eax, dword [ebp - 0x58]
mov eax, dword [eax]
sub esp, 4
mov dword [esp], eax
call sub.msvcrt.dll_free
add esp, 4
xor eax, eax
mov ecx, dword [ebp - 0x54]
mov ecx, dword [ecx]
sub esp, 8
mov dword [esp], 0
mov dword [esp + 4], ecx
mov dword [ebp - 0x47c], eax
call dword [sym.imp.USER32.dll_ReleaseDC]
mov ecx, dword [ebp - 0x50]
mov ecx, dword [ecx]
sub esp, 4
mov dword [esp], ecx
mov dword [ebp - 0x480], eax
call dword [sym.imp.GDI32.dll_DeleteDC]
mov ecx, dword [ebp - 0xa8]
mov ecx, dword [ecx]
sub esp, 4
mov dword [esp], ecx
mov dword [ebp - 0x484], eax
call dword [sym.imp.GDI32.dll_EndPage]
mov dword [ebp - 0xbc], 0x8d24e95
mov dword [ebp - 0x488], eax
jmp 0x407fcf
jmp 0x403c61