Function at 0x1002176
Capabilities:
Terminate process

Disassembly:
sub esp, 0x4c
or dword [esp], 0xffffffff
push ebp
mov ebp, dword [esp + 0x54]
cmp ebp, 1
jne 0x1002194
call fcn.01001410
push eax
call dword [sym.imp.msvcrt.dll_exit]
push ebx
push esi
push edi
mov edi, dword [esp + 0x64]
push 4
xor esi, esi
pop ebx
add edi, ebx
mov dword [section..data], esi
mov edx, dword [edi]
dec ebp
cmp edx, esi
je 0x100230b
mov al, byte [edx]
cmp al, 0x2d
je 0x10021dc
cmp al, 0x2f
je 0x10021dc
push edx
call fcn.010013a9
test al, al
je 0x1002317
push edx
call dword [sym.imp.msvcrt.dll_atoi]
pop ecx
mov dword [esp + 0x10], eax
jmp 0x10022f4
lea ecx, [edx + 1]
cmp byte [ecx], 0
je 0x1002323
mov dl, byte [ecx]
inc ecx
test dl, dl
je 0x10022f4
movsx eax, dl
cmp eax, 0x61
jg 0x10022b1
je 0x100224d
sub eax, 0x41
je 0x100224d
sub eax, 0xd
je 0x10022d6
sub eax, ebx
je 0x1002229
dec eax
jne 0x100233b
mov dword [section..data], 0x40
jmp 0x10022ec
cmp byte [ecx], 0x52
jne 0x100223e
inc ecx
mov dword [section..data], 0x800
jmp 0x10022ec
mov dword [section..data], 0x1000
jmp 0x10022ec
cmp dl, 0x41
mov dword [section..data], 1
jne 0x1002266
mov dword [section..data], 2
and byte [esp + 0x28], 0
dec ebp
je 0x10022ec
add edi, ebx
mov ecx, dword [edi]
test ecx, ecx
je 0x100232f
cmp byte [ecx], 0
je 0x100232f
mov eax, ecx
lea esi, [eax + 1]
mov dl, byte [eax]
inc eax
test dl, dl
jne 0x1002288
sub eax, esi
cmp eax, 0x32
jae 0x100232f
lea esi, [esp + 0x28]
mov eax, ecx
sub esi, ecx
mov dl, byte [eax]
mov byte [esi + eax], dl
inc eax
test dl, dl
jne 0x10022a2
xor esi, esi
inc esi
jmp 0x10022ec
sub eax, 0x63
je 0x10022e2
sub eax, 0xb
je 0x10022d6
sub eax, ebx
je 0x10022ce
dec eax
jne 0x100233b
mov dword [section..data], 0x10
jmp 0x10022ec
mov dword [section..data], ebx
jmp 0x10022ec
mov dword [section..data], 0x200
jmp 0x10022ec
mov dword [section..data], 8
test esi, esi
je 0x10021e8
add edi, ebx
mov edx, dword [edi]
xor esi, esi
dec ebp
cmp edx, esi
jne 0x10021b3
cmp dword [section..data], esi
jne 0x1002347
call fcn.01001410
push eax
call dword [sym.imp.msvcrt.dll_exit]
call fcn.01001410
push eax
call dword [sym.imp.msvcrt.dll_exit]
call fcn.01001410
push eax
call dword [sym.imp.msvcrt.dll_exit]
call fcn.01001410
push eax
call dword [sym.imp.msvcrt.dll_exit]
call fcn.01001410
push eax
call dword [sym.imp.msvcrt.dll_exit]
call fcn.01001efb
mov edi, eax
cmp edi, esi
jge 0x1002368
push 0x2710
push 2
call fcn.010026d6
pop ecx
pop ecx
push 1
call dword [sym.imp.msvcrt.dll_exit]
cmp dword [0x10032ec], esi
jne 0x1002386
push 0x2713
push 2
call fcn.010026d6
pop ecx
pop ecx
push 1
call dword [sym.imp.msvcrt.dll_exit]
xor ebp, ebp
cmp dword [0x10032ec], esi
jbe 0x10024b9
mov ebx, 0x1003320
push ebp
call fcn.0100146d
mov esi, eax
push 0x100d86c
push esi
call fcn.010015c6
mov eax, dword [section..data]
test ax, 0x1804
jne 0x1002411
push ebx
call fcn.010012c0
push eax
push 0x100128c
call fcn.01001374
mov eax, dword [0x100d86c]
movzx ecx, al
push ecx
movzx eax, ah
push eax
mov ax, word [0x100d86e]
movzx ecx, al
movzx eax, ah
push ecx
push eax
lea eax, [esp + 0x2c]
push 0x1001148
push eax
call dword [sym.imp.msvcrt.dll_sprintf]
push 0x100d880
lea eax, [esp + 0x38]
push eax
push 0x2716
push 1
call fcn.010026d6
mov eax, dword [section..data]
add esp, 0x30
cmp eax, 0x40
jg 0x1002462
je 0x1002430
test eax, eax
jle 0x1002448
cmp eax, 2
jle 0x1002441
cmp eax, 4
je 0x1002439
cmp eax, 8
je 0x1002487
cmp eax, 0x10
jne 0x1002448
push eax
push esi
call fcn.01001af8
jmp 0x100248e
push esi
call fcn.01001ddb
jmp 0x100248e
cmp byte [esp + 0x28], 0
jne 0x1002454
call fcn.01001410
or dword [esp + 0x10], 0xffffffff
jmp 0x1002490
push eax
lea eax, [esp + 0x2c]
push eax
push esi
call fcn.010017f3
jmp 0x100248e
cmp eax, 0x200
je 0x1002487
cmp eax, 0x800
je 0x100247f
cmp eax, 0x1000
jne 0x1002448
push esi
call fcn.01001d49
jmp 0x100248e
push esi
call fcn.01001d86
jmp 0x100248e
push eax
push esi
call fcn.01001619
mov edi, eax
push esi
call dword [sym.imp.ntdll.dll_NtClose]
test word [section..data], 0x1804
je 0x10024a6
test edi, edi
jge 0x10024b9
inc ebp
add ebx, 0x28b
cmp ebp, dword [0x10032ec]
jb 0x1002399
xor esi, esi
cmp dword [esp + 0x10], esi
jle 0x10024d7
mov eax, dword [esp + 0x10]
imul eax, eax, 0x3e8
push eax
call dword [sym.imp.KERNEL32.dll_Sleep]
jmp 0x1002386
pop edi
pop esi
pop ebx
xor eax, eax
pop ebp
add esp, 0x4c
ret