Function at 0x401587
Capabilities:
Query or enumerate registry value

Disassembly:
jmp 0x405d20
sub esp, 0x30
push ebx
push ebp
push esi
mov esi, ecx
lea eax, [esp + 0x2c]
push edi
mov ecx, dword [esi + 0x1c]
push eax
push ecx
call dword [sym.imp.USER32.dll_GetClientRect]
mov edx, dword [esp + 0x38]
mov edi, dword [esp + 0x30]
mov eax, dword [esp + 0x3c]
mov ecx, dword [esp + 0x34]
sub edx, edi
sub eax, ecx
mov dword [esi + 0x1ec], edx
mov dword [esi + 0x1f0], eax
mov ecx, dword [esi + 0x1ec]
shr ecx, 3
mov dword [esi + 0x1b4], ecx
mov edi, dword [esi + 0x1f0]
mov ebx, dword [esi + 0x1ec]
mov eax, edi
shr eax, 3
mov ebp, edi
mov dword [esi + 0x1b8], eax
sub ebp, eax
mov dword [esi + 0x1c8], eax
mov dword [esi + 0x1d0], eax
mov ecx, ebx
mov eax, edi
mov edx, ebx
shr ecx, 3
shr eax, 1
sub edx, ecx
mov dword [esp + 0x28], eax
mov dword [esi + 0x1e8], eax
mov eax, 0xd41d41d5
mov dword [esi + 0x1bc], edx
mov dword [esi + 0x1cc], edx
mov dword [esi + 0x1dc], edx
mul ebx
mov dword [esi + 0x1c4], ecx
mov dword [esi + 0x1d4], ecx
mov ecx, ebx
lea eax, [esi + 0x240]
sub ecx, edx
mov dword [esp + 0x24], eax
shr ecx, 1
add ecx, edx
mov dword [esi + 0x1c0], ebp
shr ecx, 5
mov dword [eax], ecx
mov eax, 0xd41d41d5
mul edi
mov eax, edi
mov dword [esi + 0x1d8], ebp
sub eax, edx
mov dword [esi + 0x1e0], ebp
shr eax, 1
add eax, edx
lea edx, [esi + 0x244]
mov ebp, ebx
mov dword [esp + 0x20], edx
shr eax, 5
shr ebp, 1
mov dword [edx], eax
mov edx, dword [esp + 0x28]
sub ebx, ecx
mov dword [esi + 0x1e4], ebp
mov dword [esi + 0x248], ebp
mov dword [esi + 0x24c], eax
mov dword [esi + 0x250], ebx
mov dword [esi + 0x254], eax
mov dword [esi + 0x258], ecx
mov dword [esi + 0x25c], edx
mov dword [esi + 0x260], ebp
mov dword [esi + 0x264], edx
mov dword [esi + 0x268], ebx
mov dword [esi + 0x26c], edx
sub edi, eax
lea edx, [esp + 0x2c]
lea eax, [esp + 0x10]
push edx
push eax
push 0
push 0xf003f
push 0
push 0
push 0
mov dword [esi + 0x274], edi
mov dword [esi + 0x27c], edi
mov dword [esi + 0x284], edi
mov edi, dword [sym.imp.ADVAPI32.dll_RegCreateKeyExA]
push str.SoftwareDigitechOption
push 0x80000002
mov dword [esi + 0x270], ecx
mov dword [esi + 0x278], ebp
mov dword [esi + 0x280], ebx
call edi
mov eax, dword [esp + 0x10]
mov ebx, dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
lea ecx, [esp + 0x14]
lea edx, [esp + 0x1c]
push ecx
push edx
push 0
push 0
mov ebp, 4
push str.SpanState
push eax
mov dword [esp + 0x2c], ebp
call ebx
test eax, eax
je 0x405ee1
mov dword [esp + 0x1c], 0
mov ecx, dword [esp + 0x10]
push ecx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
lea edx, [esp + 0x2c]
lea eax, [esp + 0x10]
push edx
push eax
push 0
push 0xf003f
push 0
push 0
push 0
push str.SoftwareDigitechOption
push 0x80000002
call edi
mov eax, dword [esp + 0x10]
lea ecx, [esp + 0x14]
lea edx, [esp + 0x18]
push ecx
push edx
push 0
push 0
push str.SpanEnable
push eax
mov dword [esp + 0x2c], ebp
call ebx
test eax, eax
je 0x405f39
mov dword [esp + 0x18], 0
mov ecx, dword [esp + 0x10]
push ecx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov eax, dword [esp + 0x18]
test eax, eax
jne 0x405f50
xor eax, eax
jmp 0x405f54
mov eax, dword [esp + 0x1c]
add eax, 0xfffffffe
cmp eax, 3
ja case.default.0x405f60
jmp dword [eax*4 + 0x406000]
mov ecx, dword [esp + 0x20]
mov edi, 9
mov eax, dword [ecx]
mov ebx, dword [esi + 0x1f0]
cdq
sub eax, edx
add ecx, 8
shr ebx, 1
sar eax, 1
add ebx, eax
dec edi
mov dword [ecx - 8], ebx
jne 0x405f70
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x30
ret
mov ecx, dword [esp + 0x20]
mov esi, 9
mov eax, dword [ecx]
add ecx, 8
cdq
sub eax, edx
sar eax, 1
mov dword [ecx - 8], eax
dec esi
jne 0x405f9b
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x30
ret
mov ecx, dword [esp + 0x24]
mov esi, 9
mov eax, dword [ecx]
add ecx, 8
cdq
sub eax, edx
sar eax, 1
mov dword [ecx - 8], eax
dec esi
jne 0x405fbc
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x30
ret
mov ecx, dword [esp + 0x24]
mov edi, 9
mov eax, dword [ecx]
mov ebx, dword [esi + 0x1ec]
cdq
sub eax, edx
add ecx, 8
shr ebx, 1
sar eax, 1
add ebx, eax
dec edi
mov dword [ecx - 8], ebx
jne 0x405fdd
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x30
ret