Function at 0x40c340
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x421090
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0xd48
push ebx
push esi
push edi
xor ebx, ebx
push 0x103
lea eax, [ebp - 0x153]
push ebx
push eax
mov dword [ebp - 4], ebx
xor edi, edi
mov byte [ebp - 0x154], bl
call sub.msvcrt.dll_memset
push 0x3ff
lea ecx, [ebp - 0xd53]
push ebx
push ecx
mov dword [ebp - 0x18], 0x104
mov byte [ebp - 0xd54], bl
call sub.msvcrt.dll_memset
push 0x3ff
lea edx, [ebp - 0x553]
push ebx
push edx
mov byte [ebp - 0x554], bl
call sub.msvcrt.dll_memset
push 0x3ff
lea eax, [ebp - 0x953]
push ebx
push eax
mov byte [ebp - 0x954], bl
call sub.msvcrt.dll_memset
mov esi, 0x400
push esi
lea ecx, [ebp - 0xd54]
push ebx
push ecx
call sub.msvcrt.dll_memset
push esi
lea edx, [ebp - 0x554]
push ebx
push edx
call sub.msvcrt.dll_memset
add esp, 0x48
push esi
lea eax, [ebp - 0x954]
push ebx
push eax
call sub.msvcrt.dll_memset
add esp, 0xc
lea ecx, [ebp - 0x10]
push ecx
push 1
push ebx
push str.SoftwareMartin_PrikrylWinSCP_2Configuration
push SysReAllocString
mov dword [ebp - 0x28], esi
mov dword [ebp - 0x30], esi
mov dword [ebp - 0x24], esi
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
je 0x40c440
lea ecx, [ebp + 0x28]
mov dword [ebp - 4], 2
call fcn.0040fdf0
mov byte [ebp - 4], 1
jmp 0x40c7b4
mov ecx, dword [ebp - 0x10]
mov esi, dword [sym.imp.ADVAPI32.dll_RegGetValueA]
lea edx, [ebp - 0x44]
push edx
lea eax, [ebp - 0x34]
push eax
push ebx
push 0x10
push str.UseMasterPassword
push str.Security
push ecx
call esi
test eax, eax
mov eax, dword [ebp - 0x10]
je 0x40c478
cmp eax, ebx
je 0x40c486
push eax
call dword [0x6400cc]
xor eax, eax
mov dword [ebp - 0x10], eax
cmp eax, ebx
je 0x40c486
push eax
call dword [0x6400cc]
mov dword [ebp - 0x10], ebx
lea edx, [ebp - 0x10]
push edx
push 9
push ebx
push str.SoftwareMartin_PrikrylWinSCP_2Sessions
push SysReAllocString
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
je 0x40c4b9
lea ecx, [ebp + 0x28]
mov dword [ebp - 4], 4
call fcn.0040fdf0
mov byte [ebp - 4], 3
jmp 0x40c7b4
mov edx, dword [ebp - 0x10]
push ebx
push ebx
push ebx
push ebx
lea eax, [ebp - 0x18]
push eax
lea ecx, [ebp - 0x154]
push ecx
push ebx
push edx
call dword [0x640158]
cmp eax, ebx
je 0x40c500
mov eax, dword [ebp - 0x10]
cmp eax, ebx
je 0x40c4e8
push eax
call dword [0x6400cc]
mov dword [ebp - 0x10], ebx
lea ecx, [ebp + 0x28]
mov dword [ebp - 4], 6
call fcn.0040fdf0
mov byte [ebp - 4], 5
jmp 0x40c7b4
push 0xf423f
push ebx
call dword [0x640164]
push eax
call dword [0x6400fc]
mov dword [ebp - 0x14], eax
jmp 0x40c523
mov edi, dword [ebp - 0x20]
mov eax, dword [ebp - 0x14]
push str.Soft:_WinSCP_n
push eax
call dword [0x640110]
mov ecx, dword [ebp - 0x14]
push 0x426bc8
push ecx
call dword [0x640110]
lea edx, [ebp - 0x28]
push edx
mov edx, dword [ebp - 0x10]
lea eax, [ebp - 0xd54]
push eax
push ebx
push 2
push str.HostName
lea ecx, [ebp - 0x154]
push ecx
push edx
call esi
mov ecx, dword [ebp - 0x14]
lea eax, [ebp - 0xd54]
push eax
push ecx
call dword [0x640110]
lea edx, [ebp - 0x2c]
push edx
mov edx, dword [ebp - 0x10]
lea eax, [ebp - 0x1c]
push eax
push ebx
push 0xffff
push str.PortNumber
lea ecx, [ebp - 0x154]
push ecx
push edx
mov dword [ebp - 0x2c], 4
call esi
test eax, eax
jne 0x40c5d0
mov eax, dword [ebp - 0x1c]
push eax
lea ecx, [ebp - 0x50]
push ecx
call fcn.00411ae0
add esp, 8
mov ecx, eax
mov byte [ebp - 4], 7
call fcn.00410010
mov edx, dword [ebp - 0x14]
push eax
push edx
call dword [0x640110]
lea ecx, [ebp - 0x50]
mov byte [ebp - 4], bl
call fcn.0040fdf0
jmp 0x40c5df
mov eax, dword [ebp - 0x14]
push 0x426be8
push eax
call dword [0x640110]
mov ecx, dword [ebp - 0x14]
push 0x426bec
push ecx
call dword [0x640110]
mov edx, dword [ebp - 0x14]
push 0x426bf0
push edx
call dword [0x640110]
lea eax, [ebp - 0x30]
push eax
mov eax, dword [ebp - 0x10]
lea ecx, [ebp - 0x554]
push ecx
push ebx
push 2
push str.UserName
lea edx, [ebp - 0x154]
push edx
push eax
call esi
mov edx, dword [ebp - 0x14]
lea ecx, [ebp - 0x554]
push ecx
push edx
call dword [0x640110]
mov eax, dword [ebp - 0x14]
push 0x426c04
push eax
call dword [0x640110]
lea ecx, [ebp - 0x24]
push ecx
mov ecx, dword [ebp - 0x10]
lea edx, [ebp - 0x954]
push edx
push ebx
push 2
push str.Password
lea eax, [ebp - 0x154]
push eax
push ecx
call esi
mov edx, dword [ebp - 0x14]
push 0x426c14
push edx
call dword [0x640110]
push 0x4268df
lea eax, [ebp - 0x954]
push eax
call dword [0x64013c]
test eax, eax
je 0x40c6c4
lea ecx, [ebp - 0x954]
push ecx
lea edx, [ebp - 0x554]
push edx
lea eax, [ebp - 0xd54]
push eax
lea ecx, [ebp - 0x40]
push ecx
call fcn.0040be40
add esp, 0x10
mov ecx, eax
mov byte [ebp - 4], 8
call fcn.00410010
mov edx, dword [ebp - 0x14]
push eax
push edx
call dword [0x640110]
lea ecx, [ebp - 0x40]
mov byte [ebp - 4], bl
call fcn.0040fdf0
mov eax, dword [ebp - 0x14]
push 0x426c20
push eax
call dword [0x640110]
mov ecx, dword [ebp - 0x14]
push 0x426c24
push ecx
call dword [0x640110]
mov ecx, dword [ebp - 0x10]
push ebx
push ebx
push ebx
push ebx
lea edx, [ebp - 0x18]
push edx
lea eax, [ebp - 0x154]
push eax
inc edi
push edi
push ecx
mov dword [ebp - 0x18], 0x104
mov dword [ebp - 0x20], edi
call dword [0x640158]
push ebx
lea edx, [ebp - 0x554]
push ebx
push edx
mov edi, eax
call sub.msvcrt.dll_memset
push ebx
lea eax, [ebp - 0x954]
push ebx
push eax
call sub.msvcrt.dll_memset
add esp, 0x18
cmp edi, 0x103
jne 0x40c520
mov ecx, dword [ebp - 0x14]
push ecx
call dword [0x640020]
mov edx, dword [ebp - 0x14]
push eax
push edx
sub esp, 0xc
mov ecx, esp
mov dword [ebp - 0x20], esp
push 0x426c28
call fcn.0040fd70
sub esp, 0x5c
lea eax, [ebp + 8]
mov ecx, esp
mov dword [ebp - 0x1c], esp
push eax
mov byte [ebp - 4], 9
call fcn.00401060
lea ecx, [ebp - 0x40]
push ecx
mov byte [ebp - 4], bl
call fcn.00415320
add esp, 0x74
lea ecx, [ebp - 0x40]
call fcn.0040fdf0
push 4
lea edx, [ebp - 0x14]
push ebx
push edx
call sub.msvcrt.dll_memset
mov eax, dword [ebp - 0x10]
add esp, 0xc
cmp eax, ebx
je 0x40c7a1
push eax
call dword [0x6400cc]
mov dword [ebp - 0x10], ebx
lea ecx, [ebp + 0x28]
mov dword [ebp - 4], 0xb
call fcn.0040fdf0
mov byte [ebp - 4], 0xa
lea ecx, [ebp + 0x14]
call fcn.0040fdf0
lea ecx, [ebp + 8]
mov dword [ebp - 4], 0xffffffff
call fcn.0040fdf0
mov ecx, dword [ebp - 0xc]
pop edi
pop esi
mov dword fs:[0], ecx
pop ebx
mov esp, ebp
pop ebp
ret