Function at 0x49e540
Capabilities:
Reference sql statements

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x5c2990
mov eax, dword fs:[0]
push eax
sub esp, 0x4c
mov eax, dword [0x6c56f8]
xor eax, ebp
mov dword [ebp - 0x14], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x10], esp
mov eax, dword [ebp + 0x1c]
mov dword [ebp - 0x4c], eax
mov esi, dword [0x6ddca4]
mov dword [ebp - 0x40], esi
mov byte [ebp - 0x31], 0
lea eax, [esi + 0x24]
mov dword [ebp - 0x48], eax
push eax
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov dword [ebp - 4], 0
lea edi, [esi + 4]
lea ecx, [ebp + 8]
push ecx
lea edx, [ebp - 0x3c]
push edx
call fcn.0049ee20
mov ebx, dword [edi + 0x18]
mov eax, dword [edi]
mov ecx, dword [ebp - 0x3c]
test ecx, ecx
je 0x49e5b5
cmp ecx, eax
je 0x49e5ba
call fcn.0058204a
cmp dword [ebp - 0x38], ebx
jne 0x49e70b
lea eax, [ebp + 8]
push eax
push edi
lea ebx, [ebp - 0x20]
call fcn.0049ed20
mov ecx, 0x6dc778
mov edx, dword [0x6dc778]
mov eax, dword [edx + 0xc]
call eax
add eax, 0x10
mov dword [ebp - 0x38], eax
mov byte [ebp - 4], 2
mov ecx, dword [ebp + 8]
push ecx
push str.CREATE_TABLE_scanned__x_file_id_INTEGER__file_time_INTEGER__detection_name_TEXT__
lea eax, [ebp - 0x38]
call fcn.0041bfaa
add esp, 8
mov byte [ebp - 4], 3
mov edx, dword [ebp - 0x38]
push edx
mov ebx, dword [esi]
call fcn.0049d150
mov dword [ebp - 4], 2
jmp 0x49e669
mov edx, dword [ebp + 8]
push edx
push str.CREATE_INDEX_fileIndex_ON_scanned__x_file_id__file_time__
lea eax, [ebp - 0x38]
call fcn.0041bfaa
add esp, 8
mov byte [ebp - 4], 6
mov eax, dword [ebp - 0x38]
push eax
mov ebx, dword [esi]
call fcn.0049d150
mov dword [ebp - 4], 2
jmp 0x49e6e8
mov byte [ebp - 4], 0
mov eax, dword [ebp - 0x38]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x49e70b
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov byte [ebp - 4], 0xa
lea ecx, [ebp - 0x38]
push ecx
call fcn.0040844d
mov byte [ebp - 4], 0xb
mov edx, dword [ebp + 8]
push edx
push str.SELECT_detection_name_FROM_scanned__x_WHERE_file_id____AND_file_time____
lea eax, [ebp - 0x38]
call fcn.0041bfaa
add esp, 8
mov eax, dword [ebp - 0x38]
push eax
lea ecx, [ebp - 0x44]
push ecx
mov ecx, dword [esi]
call fcn.0049d0d0
mov bl, 0xc
mov byte [ebp - 4], bl
mov edx, dword [ebp + 0x10]
push edx
mov eax, dword [ebp + 0xc]
push eax
push 1
lea eax, [ebp - 0x44]
call fcn.0049cff0
mov ecx, dword [ebp + 0x18]
push ecx
mov edx, dword [ebp + 0x14]
push edx
push 2
lea eax, [ebp - 0x44]
call fcn.0049cff0
lea eax, [ebp - 0x28]
push eax
lea ecx, [ebp - 0x44]
push ecx
call fcn.0049cd60
mov byte [ebp - 4], 0xd
cmp byte [ebp - 0x20], 0
jne 0x49e797
xor esi, esi
lea edi, [ebp - 0x28]
call fcn.0049c8c0
push eax
mov edx, dword [ebp - 0x4c]
push edx
call fcn.00408519
mov byte [ebp - 0x31], 1
mov byte [ebp - 4], bl
lea esi, [ebp - 0x28]
call fcn.0049c7f0
mov byte [ebp - 4], 0xb
lea ecx, [ebp - 0x44]
call fcn.0049cb30
mov byte [ebp - 4], 0xa
lea ecx, [ebp - 0x38]
call fcn.004084b5
mov dword [ebp - 4], 0
mov dword [ebp - 4], 0xffffffff
mov edx, dword [ebp - 0x48]
push edx
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
mov al, byte [ebp - 0x31]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x14]
xor ecx, ebp
call fcn.00581268
mov esp, ebp
pop ebp
ret 0x18