Function at 0x10057800
Capabilities:
Accept command line arguments
Get common file path

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x624
mov eax, dword [0x102519c8]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 8]
lea ecx, [ebp - 0x414]
push ebx
push esi
mov esi, dword [ebp + 0x10]
push edi
mov edi, dword [ebp + 0xc]
push 0x104
push ecx
push eax
call dword [sym.imp.KERNEL32.dll_GetLongPathNameW]
test eax, eax
je 0x10057b2c
push 0x104
lea eax, [ebp - 0x61c]
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryW]
test eax, eax
je 0x10057abd
push str.regsvr32.exe
lea eax, [ebp - 0x61c]
mov dword [ebp - 0x624], 0
push eax
lea eax, [ebp - 0x20c]
push eax
call dword [sym.imp.SHLWAPI.dll_PathCombineW]
test eax, eax
je 0x10057934
lea eax, [ebp - 0x414]
push eax
lea eax, [ebp - 0x20c]
push eax
call dword [sym.imp.SHLWAPI.dll_StrStrIW]
test eax, eax
je 0x10057934
lea eax, [ebp - 0x620]
push eax
push edi
call dword [sym.imp.SHELL32.dll_CommandLineToArgvW]
mov ebx, eax
test ebx, ebx
je 0x10057b2c
mov eax, dword [ebp - 0x620]
cmp eax, 2
jl 0x10057916
mov edi, 1
cmp eax, edi
jle 0x10057916
mov ecx, dword [ebx + edi*4]
cmp word [ecx], 0x2f
je 0x100578e9
push esi
push str..dll
push ecx
call fcn.10057be0
add esp, 0xc
test eax, eax
jne 0x1005790c
mov eax, dword [ebp - 0x620]
inc edi
cmp edi, eax
jl 0x100578c7
push ebx
call dword [sym.imp.KERNEL32.dll_LocalFree]
mov eax, dword [ebp - 0x624]
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.101f99c6
mov esp, ebp
pop ebp
ret
mov dword [ebp - 0x624], 1
push ebx
call dword [sym.imp.KERNEL32.dll_LocalFree]
mov eax, dword [ebp - 0x624]
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.101f99c6
mov esp, ebp
pop ebp
ret
push str.rundll32.exe
lea eax, [ebp - 0x61c]
xor ebx, ebx
push eax
lea eax, [ebp - 0x20c]
push eax
call dword [sym.imp.SHLWAPI.dll_PathCombineW]
test eax, eax
je 0x100579e2
lea eax, [ebp - 0x414]
push eax
lea eax, [ebp - 0x20c]
push eax
call dword [sym.imp.SHLWAPI.dll_StrStrIW]
test eax, eax
je 0x100579e2
lea eax, [ebp - 0x624]
push eax
push edi
call dword [sym.imp.SHELL32.dll_CommandLineToArgvW]
mov edi, eax
test edi, edi
je 0x10057b2c
cmp dword [ebp - 0x624], 2
jl 0x100579c8
mov eax, dword [edi + 4]
push 0x2c
push eax
mov dword [ebp - 0x620], eax
call dword [sym.imp.SHLWAPI.dll_StrChrW]
test eax, eax
je 0x100579ab
xor ecx, ecx
mov word [eax], cx
push esi
push str..dll
push dword [ebp - 0x620]
call fcn.10057be0
add esp, 0xc
test eax, eax
je 0x100579c8
mov ebx, 1
push edi
call dword [sym.imp.KERNEL32.dll_LocalFree]
pop edi
pop esi
mov eax, ebx
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.101f99c6
mov esp, ebp
pop ebp
ret
push str.cmd.exe
lea eax, [ebp - 0x61c]
mov dword [ebp - 0x620], ebx
push eax
lea eax, [ebp - 0x20c]
push eax
call dword [sym.imp.SHLWAPI.dll_PathCombineW]
test eax, eax
je 0x10057abd
lea eax, [ebp - 0x414]
push eax
lea eax, [ebp - 0x20c]
push eax
call dword [sym.imp.SHLWAPI.dll_StrStrIW]
test eax, eax
je 0x10057abd
lea eax, [ebp - 0x624]
push eax
push edi
call dword [sym.imp.SHELL32.dll_CommandLineToArgvW]
mov ebx, eax
test ebx, ebx
je 0x10057b2c
mov ecx, dword [ebp - 0x624]
mov edi, 1
cmp ecx, edi
jle 0x10057a9f
lea esp, [esp]
mov eax, dword [ebx + edi*4]
cmp word [eax], 0x2f
je 0x10057a72
push esi
push str..exe
push eax
call fcn.10057be0
add esp, 0xc
test eax, eax
jne 0x10057a95
mov ecx, dword [ebp - 0x624]
inc edi
cmp edi, ecx
jl 0x10057a50
push ebx
call dword [sym.imp.KERNEL32.dll_LocalFree]
mov eax, dword [ebp - 0x620]
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.101f99c6
mov esp, ebp
pop ebp
ret
mov dword [ebp - 0x620], 1
push ebx
call dword [sym.imp.KERNEL32.dll_LocalFree]
mov eax, dword [ebp - 0x620]
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.101f99c6
mov esp, ebp
pop ebp
ret
lea edx, [ebp - 0x414]
mov ecx, 0x104
sub edx, esi
lea ebx, [ebx]
lea eax, [ecx + 0x7ffffefa]
test eax, eax
je 0x10057b0a
movzx eax, word [edx + esi]
test ax, ax
je 0x10057b0a
mov word [esi], ax
add esi, 2
sub ecx, 1
jne 0x10057ad0
sub esi, 2
xor eax, eax
pop edi
mov word [esi], ax
lea eax, [ecx + 1]
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.101f99c6
mov esp, ebp
pop ebp
ret
test ecx, ecx
jne 0x10057b11
sub esi, 2
xor eax, eax
pop edi
mov word [esi], ax
mov eax, 1
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.101f99c6
mov esp, ebp
pop ebp
ret
mov ecx, dword [ebp - 4]
xor eax, eax
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.101f99c6
mov esp, ebp
pop ebp
ret