Function at 0x40e7b8
Capabilities:
Query or enumerate registry value

Disassembly:
mov eax, 0x42057d
call sub.msvcrt.dll__EH_prolog
sub esp, 0xde4
push ebx
push esi
push edi
xor ebx, ebx
push 0x103
lea eax, [ebp - 0x1ef]
push ebx
push eax
mov dword [ebp - 4], ebx
mov dword [ebp - 0x24], ebx
mov byte [ebp - 0x1f0], bl
call sub.msvcrt.dll_memset
mov esi, 0x3ff
push esi
lea eax, [ebp - 0xdef]
push ebx
push eax
mov dword [ebp - 0x20], 0x104
mov byte [ebp - 0xdf0], bl
call sub.msvcrt.dll_memset
push esi
lea eax, [ebp - 0x5ef]
push ebx
push eax
mov byte [ebp - 0x5f0], bl
call sub.msvcrt.dll_memset
push esi
lea eax, [ebp - 0x9ef]
push ebx
push eax
mov byte [ebp - 0x9f0], bl
call sub.msvcrt.dll_memset
inc esi
push esi
lea eax, [ebp - 0xdf0]
push ebx
push eax
call sub.msvcrt.dll_memset
push esi
lea eax, [ebp - 0x5f0]
push ebx
push eax
call sub.msvcrt.dll_memset
add esp, 0x48
push esi
lea eax, [ebp - 0x9f0]
push ebx
push eax
call sub.msvcrt.dll_memset
mov edi, dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
add esp, 0xc
lea eax, [ebp - 0x10]
push eax
push 1
push ebx
push str.SoftwareMartin_PrikrylWinSCP_2Configuration
push 0x80000001
mov dword [ebp - 0x34], esi
mov dword [ebp - 0x3c], esi
mov dword [ebp - 0x30], esi
call edi
test eax, eax
jne 0x40eced
mov esi, dword [sym.imp.ADVAPI32.dll_RegGetValueA]
lea eax, [ebp - 0x4c]
push eax
lea eax, [ebp - 0x38]
push eax
push ebx
push 0x10
push str.UseMasterPassword
push str.Security
push dword [ebp - 0x10]
call esi
test eax, eax
je 0x40e8cc
cmp dword [ebp - 0x10], ebx
je 0x40eced
push dword [ebp - 0x10]
call dword [0x6400cc]
mov dword [ebp - 0x10], ebx
jmp 0x40eced
cmp dword [ebp - 0x38], ebx
jne 0x40e8b2
cmp dword [ebp - 0x10], ebx
je 0x40e8e2
push dword [ebp - 0x10]
call dword [0x6400cc]
mov dword [ebp - 0x10], ebx
lea eax, [ebp - 0x10]
push eax
push 9
push ebx
push str.SoftwareMartin_PrikrylWinSCP_2Sessions
push 0x80000001
call edi
test eax, eax
jne 0x40eced
push ebx
push ebx
push ebx
push ebx
lea eax, [ebp - 0x20]
push eax
lea eax, [ebp - 0x1f0]
push eax
push ebx
push dword [ebp - 0x10]
call dword [0x640158]
cmp eax, ebx
jne 0x40e8b2
push 0x425c37
lea ecx, [ebp - 0x1c]
call fcn.0040f923
mov byte [ebp - 4], 1
push str.Soft:_WinSCP_n
lea eax, [ebp - 0x70]
push eax
lea ecx, [ebp - 0x1c]
call fcn.0040fa9c
push eax
lea ecx, [ebp - 0x1c]
mov byte [ebp - 4], 2
call fcn.0040f9e1
lea ecx, [ebp - 0x70]
mov byte [ebp - 4], 1
call fcn.0040f98e
push 0x425fd8
lea eax, [ebp - 0x94]
push eax
lea ecx, [ebp - 0x1c]
call fcn.0040fa9c
push eax
lea ecx, [ebp - 0x1c]
mov byte [ebp - 4], 3
call fcn.0040f9e1
lea ecx, [ebp - 0x94]
mov byte [ebp - 4], 1
call fcn.0040f98e
lea eax, [ebp - 0x34]
push eax
lea eax, [ebp - 0xdf0]
push eax
push ebx
push 2
push str.HostName
lea eax, [ebp - 0x1f0]
push eax
push dword [ebp - 0x10]
call esi
lea eax, [ebp - 0xdf0]
push eax
lea eax, [ebp - 0x58]
push eax
lea ecx, [ebp - 0x1c]
call fcn.0040fa9c
push eax
lea ecx, [ebp - 0x1c]
mov byte [ebp - 4], 4
call fcn.0040f9e1
lea ecx, [ebp - 0x58]
mov byte [ebp - 4], 1
call fcn.0040f98e
lea eax, [ebp - 0x28]
push eax
lea eax, [ebp - 0x2c]
push eax
push ebx
push 0xffff
push str.PortNumber
lea eax, [ebp - 0x1f0]
push eax
push dword [ebp - 0x10]
mov dword [ebp - 0x28], 4
call esi
test eax, eax
jne 0x40ea43
push dword [ebp - 0x2c]
lea eax, [ebp - 0x88]
push eax
call fcn.0041118e
pop ecx
pop ecx
push eax
lea eax, [ebp - 0xac]
push eax
lea ecx, [ebp - 0x1c]
mov byte [ebp - 4], 5
call fcn.0040fa28
push eax
lea ecx, [ebp - 0x1c]
mov byte [ebp - 4], 6
call fcn.0040f9e1
lea ecx, [ebp - 0xac]
mov byte [ebp - 4], 5
call fcn.0040f98e
lea ecx, [ebp - 0x88]
jmp 0x40ea6a
push 0x425ff8
lea eax, [ebp - 0xb8]
push eax
lea ecx, [ebp - 0x1c]
call fcn.0040fa9c
push eax
lea ecx, [ebp - 0x1c]
mov byte [ebp - 4], 7
call fcn.0040f9e1
lea ecx, [ebp - 0xb8]
mov byte [ebp - 4], 1
call fcn.0040f98e
push str._nLogin:
lea eax, [ebp - 0xa0]
push eax
lea ecx, [ebp - 0x1c]
call fcn.0040fa9c
push eax
lea ecx, [ebp - 0x1c]
mov byte [ebp - 4], 8
call fcn.0040f9e1
lea ecx, [ebp - 0xa0]
mov byte [ebp - 4], 1
call fcn.0040f98e
lea eax, [ebp - 0x3c]
push eax
lea eax, [ebp - 0x5f0]
push eax
push ebx
push 2
push str.UserName
lea eax, [ebp - 0x1f0]
push eax
push dword [ebp - 0x10]
call esi
lea eax, [ebp - 0x5f0]
push eax
lea eax, [ebp - 0xd0]
push eax
lea ecx, [ebp - 0x1c]
call fcn.0040fa9c
push eax
lea ecx, [ebp - 0x1c]
mov byte [ebp - 4], 9
call fcn.0040f9e1
lea ecx, [ebp - 0xd0]
mov byte [ebp - 4], 1
call fcn.0040f98e
push 0x426014
lea eax, [ebp - 0xc4]
push eax
lea ecx, [ebp - 0x1c]
call fcn.0040fa9c
push eax
lea ecx, [ebp - 0x1c]
mov byte [ebp - 4], 0xa
call fcn.0040f9e1
lea ecx, [ebp - 0xc4]
mov byte [ebp - 4], 1
call fcn.0040f98e
lea eax, [ebp - 0x30]
push eax
lea eax, [ebp - 0x9f0]
push eax
push ebx
push 2
push str.Password
lea eax, [ebp - 0x1f0]
push eax
push dword [ebp - 0x10]
call esi
push 0x426024
lea eax, [ebp - 0x64]
push eax
lea ecx, [ebp - 0x1c]
call fcn.0040fa9c
push eax
lea ecx, [ebp - 0x1c]
mov byte [ebp - 4], 0xb
call fcn.0040f9e1
lea ecx, [ebp - 0x64]
mov byte [ebp - 4], 1
call fcn.0040f98e
push 0x425c3a
lea eax, [ebp - 0x9f0]
push eax
call dword [0x64013c]
test eax, eax
je 0x40ebeb
lea eax, [ebp - 0x9f0]
push eax
lea eax, [ebp - 0x5f0]
push eax
lea eax, [ebp - 0xdf0]
push eax
lea eax, [ebp - 0xec]
push eax
call fcn.0040e2ff
add esp, 0x10
cmp dword [eax + 0x14], 0x10
mov byte [ebp - 4], 0xc
jb 0x40ebb3
mov eax, dword [eax]
push eax
lea eax, [ebp - 0x7c]
push eax
lea ecx, [ebp - 0x1c]
call fcn.0040fa9c
push eax
lea ecx, [ebp - 0x1c]
mov byte [ebp - 4], 0xd
call fcn.0040f9e1
lea ecx, [ebp - 0x7c]
mov byte [ebp - 4], 0xc
call fcn.0040f98e
push ebx
push 1
lea ecx, [ebp - 0xec]
mov byte [ebp - 4], 1
call fcn.0040dd10
push 0x426030
lea eax, [ebp - 0x48]
push eax
lea ecx, [ebp - 0x1c]
call fcn.0040fa9c
push eax
lea ecx, [ebp - 0x1c]
mov byte [ebp - 4], 0xe
call fcn.0040f9e1
lea ecx, [ebp - 0x48]
mov byte [ebp - 4], 1
call fcn.0040f98e
inc dword [ebp - 0x24]
push ebx
push ebx
push ebx
push ebx
lea eax, [ebp - 0x20]
push eax
lea eax, [ebp - 0x1f0]
push eax
push dword [ebp - 0x24]
mov dword [ebp - 0x20], 0x104
push dword [ebp - 0x10]
call dword [0x640158]
push ebx
mov edi, eax
lea eax, [ebp - 0x5f0]
push ebx
push eax
call sub.msvcrt.dll_memset
push ebx
lea eax, [ebp - 0x9f0]
push ebx
push eax
call sub.msvcrt.dll_memset
add esp, 0x18
cmp edi, 0x103
jne 0x40e92b
lea ecx, [ebp - 0x1c]
call fcn.0040fb4d
push eax
call dword [0x640020]
push eax
lea ecx, [ebp - 0x1c]
call fcn.0040fb4d
push eax
sub esp, 0xc
mov ecx, esp
mov dword [ebp - 0x2c], esp
push 0x426034
call fcn.0040f923
sub esp, 0x68
lea eax, [ebp + 8]
mov ecx, esp
mov dword [ebp - 0x28], esp
push eax
mov byte [ebp - 4], 0xf
call fcn.004010b1
lea eax, [ebp - 0x48]
push eax
mov byte [ebp - 4], 1
call fcn.00414437
add esp, 0x80
lea ecx, [ebp - 0x48]
call fcn.0040f98e
push 0xc
lea eax, [ebp - 0x1c]
push ebx
push eax
call sub.msvcrt.dll_memset
add esp, 0xc
cmp dword [ebp - 0x10], ebx
je 0x40ece2
push dword [ebp - 0x10]
call dword [0x6400cc]
mov dword [ebp - 0x10], ebx
lea ecx, [ebp - 0x1c]
mov byte [ebp - 4], bl
call fcn.0040f98e
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp + 8]
call fcn.00401061
mov ecx, dword [ebp - 0xc]
pop edi
pop esi
mov dword fs:[0], ecx
pop ebx
leave
ret