Function at 0x50cc80
Capabilities:
Query or enumerate registry value
Set registry value

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x5d34ab
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x28c
push ebx
mov ebx, ecx
push esi
mov esi, dword [ebp + 8]
mov eax, dword [ebx + 0x64]
push edi
xor edi, edi
mov dword [ebp - 0x10], esp
cmp eax, edi
mov dword [ebp - 0x44], ebx
mov dword [ebp - 4], edi
je 0x50cd2b
push esi
call fcn.00511450
cmp eax, edi
je 0x50cd2b
mov eax, dword [esi + 0x40]
mov ecx, dword [esi + 0x44]
mov edx, dword [esi + 0x80]
mov dword [esi + 0x48], eax
mov dword [esi + 0x4c], ecx
mov dword [edx + 8], eax
mov dword [edx + 0xc], ecx
mov eax, dword [esi + 0xa0]
mov eax, dword [eax + 0x24]
cmp eax, 4
je 0x50cd0c
cmp eax, 5
je 0x50cd0c
mov ecx, esi
call fcn.00515fa0
mov eax, 1
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0x10
mov byte [esi + 0xb7], 1
mov eax, 1
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0x10
push str.Insert_next_chunk_in_list_n
mov ecx, ebx
mov byte [esi + 0xb7], 0
mov dword [ebp - 0x1c], edi
mov dword [ebp - 0x18], edi
call fcn.0050c380
mov al, byte [ebx + 0x7c]
test al, al
je 0x50cd87
mov ecx, dword [ebx + 0x70]
cmp dword [ecx], edi
jne 0x50cd87
cmp dword [ebp + 0xc], edi
jne 0x50cd87
cmp dword [ebx + 0x64], edi
jne 0x50cd87
lea edx, [ebp - 0x1c]
mov ecx, ebx
push edx
mov dword [ebp - 0x24], 1
call fcn.0050d360
cmp eax, edi
mov dword [ebp + 8], eax
je 0x50cd87
mov ecx, dword [ebp - 0x18]
cmp ecx, edi
jg 0x50cdad
jl 0x50cd87
cmp dword [ebp - 0x1c], 0x5b43
jae 0x50cdad
mov edi, dword [ebp + 0x10]
xor eax, eax
mov dword [ebp - 0x1c], eax
mov dword [ebp - 0x18], eax
lea eax, [ebp - 0x1c]
push edi
push eax
mov ecx, ebx
call fcn.0050d480
mov ecx, dword [ebp - 0x18]
mov dword [ebp + 8], eax
mov dword [ebp - 0x24], 0
jmp 0x50cdb0
mov edi, dword [ebp + 0x10]
test eax, eax
je 0x50ce56
test ecx, ecx
jg 0x50cdd2
jl 0x50cdc7
cmp dword [ebp - 0x1c], 0x5b43
jae 0x50cdd2
mov eax, dword [ebp + 0xc]
test eax, eax
je 0x50ce56
test edi, edi
je 0x50cded
xor eax, eax
lea edi, [edi + edi*2]
cmp ecx, eax
jg 0x50cded
jl 0x50cde6
cmp dword [ebp - 0x1c], edi
jae 0x50cded
mov eax, dword [ebp + 0xc]
test eax, eax
je 0x50ce56
push 0x50
call fcn.005a9fe9
mov ecx, eax
add esp, 4
mov dword [ebp - 0x28], ecx
test ecx, ecx
mov byte [ebp - 4], 1
je 0x50ce0d
call fcn.00512ae0
mov edi, eax
jmp 0x50ce0f
xor edi, edi
test edi, edi
mov dword [ebp - 0x20], edi
mov byte [ebp - 4], 0
je 0x50ce56
mov ecx, dword [ebx + 0x6c]
mov dword [edi + 0x44], ecx
mov edx, dword [ebx + 0x74]
mov dword [edi + 0x48], edx
mov eax, dword [ebx + 0x20]
mov ecx, dword [eax + 0x10]
push ecx
call fcn.00591712
lea edx, [eax + eax + 0x14]
push edx
call fcn.005a9fe9
add esp, 8
mov dword [ebp - 0x14], eax
test eax, eax
jne 0x50ce6b
mov ecx, edi
call fcn.00512b20
push edi
call fcn.005aa012
add esp, 4
xor eax, eax
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0x10
mov eax, dword [ebx + 0x2c]
inc eax
mov dword [ebx + 0x2c], eax
mov dword [edi + 0x40], eax
mov ecx, dword [ebx + 0x20]
mov eax, dword [ebx + 0x2c]
push eax
mov eax, dword [ebp - 0x14]
mov edx, dword [ecx + 0x10]
push edx
push 0x67ed74
push eax
call fcn.0059261e
mov ecx, dword [ebp - 0x14]
add esp, 0x10
push ecx
mov ecx, edi
call fcn.00512bb0
test eax, eax
je 0x50ceb6
mov ecx, edi
call fcn.00512b20
push edi
call fcn.005aa012
mov edx, dword [ebp - 0x14]
add esp, 4
push edx
jmp 0x50ce4e
mov eax, dword [ebp - 0x14]
lea ecx, [esi + 0x10]
push eax
call fcn.00518590
test eax, eax
je 0x50cf03
mov esi, dword [ebp - 0x14]
push eax
push esi
lea ecx, [ebp - 0x298]
push str.Error_opening_file__s__errcode___ld._n
push ecx
call fcn.005920ea
add esp, 0x10
lea edx, [ebp - 0x298]
mov ecx, ebx
push edx
call fcn.0050c380
mov ecx, edi
call fcn.00512b20
push edi
call fcn.005aa012
add esp, 4
push esi
jmp 0x50ce4e
mov eax, dword [ebp - 0x14]
push eax
call fcn.005aa012
add esp, 4
mov ecx, ebx
push 0x67ed70
call fcn.0050c380
mov edx, dword [ebp + 8]
mov dword [edi], esi
mov eax, dword [edx]
mov dword [ebp - 0x40], eax
mov ecx, dword [eax + 0xa0]
mov ecx, dword [ecx + 0x24]
cmp ecx, 4
je 0x50cfec
cmp ecx, 5
je 0x50cfec
mov ecx, dword [eax + 0x50]
mov dword [esi + 0x50], ecx
mov eax, dword [eax + 0x54]
mov dword [esi + 0x54], eax
mov eax, dword [ebx + 0x64]
test eax, eax
jne 0x50cfa1
mov eax, dword [ebp + 0xc]
test eax, eax
jne 0x50cfa1
mov eax, dword [ebx + 0x20]
cmp edx, eax
jne 0x50cfa1
mov ecx, dword [eax + 0x38]
test ecx, ecx
jne 0x50cfa1
mov ecx, dword [ebx + 0x70]
cmp dword [ecx], 0
jne 0x50cfa1
mov edx, dword [esi + 0xa0]
cmp dword [edx + 0xb8], 2
jne 0x50cfa1
mov eax, dword [ebp - 0x18]
test eax, eax
jl 0x50cf99
jg 0x50cf91
cmp dword [ebp - 0x1c], 0xb680
jbe 0x50cf99
mov eax, 0x5b40
cdq
jmp 0x50cfd7
mov eax, 0x2da0
cdq
jmp 0x50cfd7
mov eax, dword [ebp - 0x24]
test eax, eax
je 0x50cfc6
mov ecx, dword [ebx + 0x80]
mov dword [ebx + 0x78], edi
mov dword [esi + 0x40], ecx
mov edx, dword [ebx + 0x84]
mov dword [esi + 0x44], edx
mov byte [ebx + 0x7c], 0
jmp 0x50d0f2
mov eax, dword [ebp - 0x18]
mov ecx, dword [ebp - 0x1c]
push 0
push 2
push eax
push ecx
call fcn.00593520
mov ecx, dword [esi + 0x50]
sub ecx, eax
mov eax, dword [esi + 0x54]
sbb eax, edx
mov dword [esi + 0x40], ecx
mov dword [esi + 0x44], eax
jmp 0x50d0f2
mov ecx, dword [eax + 0xbc]
test ecx, ecx
jne 0x50d004
mov ecx, dword [eax + 0xc0]
mov edx, dword [eax + 0xb8]
add ecx, edx
mov dword [ebp + 0xc], ecx
mov ecx, dword [ebp + 8]
xor edi, edi
mov eax, dword [ecx + 0x38]
test eax, eax
je 0x50d028
mov eax, dword [eax + 0x1c]
mov ecx, dword [ebp + 0xc]
cmp eax, ecx
jbe 0x50d0cc
sub eax, ecx
jmp 0x50d0ca
mov edx, dword [ebp - 0x40]
mov eax, dword [edx + 0xa0]
fld qword [eax + 0x300]
fmul qword [0x5e6a38]
call fcn.00591bf8
cmp eax, dword [ebp + 0xc]
jbe 0x50d068
mov eax, dword [ebp - 0x40]
mov eax, dword [eax + 0xa0]
fld qword [eax + 0x300]
fmul qword [0x603950]
call fcn.00591bf8
mov edi, dword [ebp + 0xc]
neg edi
sub edi, eax
mov ecx, dword [esi + 0xa0]
mov al, byte [ecx + 0x2d3]
test al, al
jne 0x50d0cc
fld qword [ebx + 0x18]
fcomp qword [0x5e3750]
mov ecx, dword [ebp + 0xc]
mov dword [ebp - 0x28], edi
fnstsw ax
test ah, 0x41
jne 0x50d0ab
mov edx, dword [ebp - 0x40]
mov eax, dword [edx + 0xc0]
mov edx, dword [edx + 0xb8]
mov dword [ebp - 0x24], edx
add edx, eax
cmp ecx, edx
jb 0x50d0ab
sub ecx, dword [ebp - 0x24]
sub ecx, eax
lea edx, [ecx + ecx*4]
lea edi, [ecx + 0x2da0]
cmp edx, 0x2da0
jb 0x50d0c3
lea edi, [ecx + ecx + 0x5b43]
mov eax, dword [ebp - 0x28]
cmp eax, edi
jae 0x50d0cc
mov edi, eax
mov eax, dword [ebp + 0xc]
shr edi, 1
add edi, eax
mov eax, dword [ebp - 0x20]
xor ecx, ecx
mov dword [eax + 0x1c], edi
mov dword [esi + 0xb8], edi
mov dword [esi + 0xc0], ecx
mov edx, dword [eax + 0x1c]
mov dword [esi + 0x40], edx
mov dword [esi + 0x44], ecx
mov edi, eax
mov eax, dword [ebp + 0x10]
test eax, eax
je 0x50d193
mov edi, dword [ebp + 0x14]
mov ecx, dword [esi + 0x40]
mov edx, dword [esi + 0x44]
xor eax, eax
sub ecx, edi
push eax
sbb edx, eax
mov eax, dword [ebp + 0x10]
push eax
push edx
push ecx
call fcn.005935d0
mov ecx, dword [ebp + 0x10]
xor edx, edx
sub ecx, eax
mov eax, dword [esi + 0x40]
add ecx, eax
mov eax, dword [esi + 0x44]
adc edx, eax
mov eax, dword [ebp + 8]
mov dword [esi + 0x40], ecx
mov dword [esi + 0x44], edx
mov ecx, dword [eax]
mov eax, 0
push eax
mov edx, dword [ecx + 0x6c]
mov ecx, dword [esi + 0x40]
mov dword [esi + 0x6c], edx
mov edx, dword [esi + 0x44]
sub ecx, edi
sbb edx, eax
mov eax, dword [ebp + 0x10]
push eax
push edx
push ecx
call fcn.00593520
mov ecx, dword [esi + 0x6c]
mov dword [esi + 0x68], eax
cmp ecx, eax
jae 0x50d187
push str.Err_in_Chl:Ins__endPacket___startPacket__n
mov ecx, ebx
call fcn.0050c380
mov esi, dword [ebp - 0x20]
mov ecx, esi
call fcn.00512b20
push esi
call fcn.005aa012
mov ecx, dword [ebp - 0x14]
add esp, 4
push ecx
jmp 0x50ce4e
mov edx, dword [ebp + 8]
mov edi, dword [ebp - 0x20]
dec eax
mov ecx, dword [edx]
mov dword [ecx + 0x6c], eax
mov edx, dword [esi + 0x40]
mov ecx, dword [esi + 0x44]
xor eax, eax
sub edx, 1
mov dword [esi + 0x58], eax
mov dword [esi + 0x5c], eax
sbb ecx, eax
mov eax, dword [ebp + 8]
mov eax, dword [eax]
mov dword [eax + 0x50], edx
mov dword [eax + 0x54], ecx
mov eax, dword [ebx + 0x74]
test eax, eax
je 0x50d2f9
mov eax, dword [edi + 0x40]
mov ecx, dword [edi]
mov dword [ebp - 0x3c], eax
mov edx, dword [ecx + 0x40]
mov dword [ebp - 0x34], edx
mov edx, dword [ebp + 8]
mov ecx, dword [ecx + 0x44]
mov dword [ebp - 0x30], ecx
mov ecx, dword [edx + 0x38]
test ecx, ecx
je 0x50d1e2
mov ecx, dword [ecx + 0x40]
mov dword [ebp - 0x38], ecx
jmp 0x50d1e9
mov dword [ebp - 0x38], 0xffffffff
push eax
lea edx, [ebp - 0x2c]
push 0x665fac
push edx
call fcn.005920ea
mov edx, dword [ebx + 0x74]
add esp, 0xc
lea eax, [ebp - 0x3c]
lea ecx, [ebp - 0x2c]
push 0x10
push eax
push 0
push 0
push ecx
push edx
call dword [sym.imp.ADVAPI32.dll_RegSetValueExA]
mov eax, dword [ebp - 0x38]
mov ecx, dword [ebp - 0x30]
mov edx, dword [ebp - 0x34]
push eax
mov eax, dword [ebp - 0x3c]
push ecx
push edx
push eax
lea ecx, [ebp - 0x144]
push str.Adding_record_to_registry_with_ID__d__startPos__I64d__nextID__d_n
push ecx
call fcn.005920ea
add esp, 0x18
lea edx, [ebp - 0x144]
mov ecx, ebx
push edx
call fcn.0050c380
mov eax, dword [ebp + 8]
lea edx, [ebp - 0x2c]
mov ecx, dword [eax + 0x40]
push ecx
push 0x665fac
push edx
call fcn.005920ea
add esp, 0xc
lea eax, [ebp + 0x10]
lea ecx, [ebp - 0x3c]
lea edx, [ebp - 0x2c]
push eax
mov eax, dword [ebx + 0x74]
push ecx
push 0
push 0
push edx
push eax
mov dword [ebp + 0x10], 0x10
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
test eax, eax
je 0x50d2a5
push eax
lea ecx, [ebp - 0x144]
push str.Error_reading_registry__errCode___d._n
push ecx
call fcn.005920ea
add esp, 0xc
lea edx, [ebp - 0x144]
mov ecx, ebx
push edx
call fcn.0050c380
mov eax, dword [edi + 0x40]
lea ecx, [ebp - 0x3c]
push 0x10
push ecx
mov dword [ebp - 0x38], eax
mov eax, dword [ebx + 0x74]
push 0
lea edx, [ebp - 0x2c]
push 0
push edx
push eax
call dword [sym.imp.ADVAPI32.dll_RegSetValueExA]
mov ecx, dword [ebp - 0x38]
mov edx, dword [ebp - 0x30]
mov eax, dword [ebp - 0x34]
push ecx
mov ecx, dword [ebp - 0x3c]
push edx
push eax
lea edx, [ebp - 0x2c]
push ecx
push edx
lea eax, [ebp - 0x144]
push str.Updating_record_with_num__s:_set_ID__d__startPos__I64d__nextID__d_n
push eax
call fcn.005920ea
add esp, 0x1c
lea ecx, [ebp - 0x144]
push ecx
mov ecx, ebx
call fcn.0050c380
mov ebx, dword [ebp + 8]
mov edx, dword [ebx + 0x38]
mov dword [edi + 0x38], edx
mov dword [ebx + 0x38], edi
mov eax, dword [esi + 0x40]
mov dword [esi + 0x80], edi
mov dword [edi + 8], eax
mov ecx, dword [esi + 0x44]
mov dword [edi + 0xc], ecx
mov edx, dword [esi + 0x40]
mov eax, dword [esi + 0x44]
mov dword [esi + 0x48], edx
mov ecx, esi
mov dword [esi + 0x4c], eax
call fcn.00515fa0
mov ecx, dword [ebx]
call fcn.00515fa0
mov ecx, dword [ebp - 0xc]
pop edi
pop esi
mov eax, 1
mov dword fs:[0], ecx
pop ebx
mov esp, ebp
pop ebp
ret 0x10