Function at 0x40a483
Capabilities:
Log keystrokes via polling
Reference sql statements

Disassembly:
push ebp
push ebx
mov edx, 0xe
sub esp, 4
mov dword [esp], 0
dec edx
jne 0x40a48a
call fcn.0048d6d0
mov edx, dword [esp + 0x48]
lea ecx, [esp]
call fcn.0042e000
push 1
call fcn.0040e3ec
mov eax, str.Begin_Transaction
push eax
push dword [esp + 0x48]
call fcn.0047f005
mov ebx, eax
and ebx, ebx
jne 0x40a50a
push edx
call fcn.0048d530
pop edx
push eax
push edx
call fcn.0048d530
pop edx
push eax
mov edx, str.Add_link_error
push edx
call fcn.0048d570
push edx
call fcn.0048d530
pop edx
push eax
push edx
call fcn.0048d530
pop edx
push eax
call fcn.0047f041
pop eax
call fcn.0042e5e2
add dword [esp], edx
call fcn.00420059
call fcn.0042e610
push 7
push 0x5de530
lea eax, [esp + 0xc]
push eax
push 0x1c
call fcn.00486c28
mov dword [esp + 0xc], 0
mov dword [esp + 0x10], 0
jmp 0x40a535
push 0x4d
call fcn.00478744
cmp eax, dword [esp + 0x10]
jl 0x40a8ad
push dword [esp + 0x10]
push 0x4d
call fcn.00473779
mov ebx, eax
and ebx, 1
and ebx, ebx
je 0x40a8a3
push edx
call fcn.0048d530
pop edx
push eax
push edx
call fcn.0048d530
pop edx
push eax
push edx
call fcn.0048d530
pop edx
push eax
push 0
push dword [esp + 0x20]
push 0x4d
call fcn.00478771
call fcn.0042e5e2
add dword [esp], edx
call fcn.0041a15d
lea eax, [esp + 0x18]
push eax
call fcn.0048d5d0
push edx
call fcn.0048d530
pop edx
push eax
push edx
call fcn.0048d530
pop edx
push eax
push 0x42
call fcn.00473529
call fcn.0048d660
mov edx, dword [0x8f9b9c]
pop ecx
push ecx
call fcn.0042e600
mov ecx, eax
call fcn.0042e590
je 0x40a612
push edx
call fcn.0048d530
pop edx
push eax
mov edx, str.SELECT_key__Description__Lic__Blocked__ActivCount__Comment_FROM_keys_WHERE_key
push edx
call fcn.0048d570
mov edx, dword [esp + 0x18]
push edx
call fcn.0048d570
mov edx, 0x5cf830
push edx
call fcn.0048d570
lea eax, [esp + 0x1c]
push eax
call fcn.0048d5d0
jmp 0x40a70c
push edx
call fcn.0048d530
pop edx
push eax
push edx
call fcn.0048d530
pop edx
push eax
push edx
call fcn.0048d530
pop edx
push eax
push 0x4e
call fcn.00473529
call fcn.0042e5e2
add dword [esp], edx
call fcn.0041a15d
call fcn.0048d660
push edx
call fcn.0048d530
pop edx
push eax
mov edx, 0x5d1a70
push edx
call fcn.0048d570
mov edx, dword [0x8f9b58]
push edx
call fcn.0048d570
call fcn.0042e600
mov edx, eax
pop ecx
push ecx
call fcn.0042e600
mov ecx, eax
call fcn.0042e590
je 0x40a6c5
push edx
call fcn.0048d530
pop edx
push eax
mov edx, str.SELECT_key__Description__Lic__Blocked__ActivCount__Comment_FROM_keys_WHERE_BlockedKey_Blocked__AND__key
push edx
call fcn.0048d570
mov edx, dword [esp + 0x18]
push edx
call fcn.0048d570
mov edx, str._OR_Description
push edx
call fcn.0048d570
mov edx, dword [esp + 0x18]
push edx
call fcn.0048d570
mov edx, 0x5d5c64
push edx
call fcn.0048d570
lea eax, [esp + 0x1c]
push eax
call fcn.0048d5d0
jmp 0x40a70c
push edx
call fcn.0048d530
pop edx
push eax
mov edx, 0x5dbb08
push edx
call fcn.0048d570
mov edx, dword [esp + 0x18]
push edx
call fcn.0048d570
mov edx, str._OR_Description
push edx
call fcn.0048d570
mov edx, dword [esp + 0x18]
push edx
call fcn.0048d570
mov edx, 0x5d5c64
push edx
call fcn.0048d570
lea eax, [esp + 0x1c]
push eax
call fcn.0048d5d0
push dword [esp + 0x18]
push dword [esp + 0x48]
call fcn.0047f11d
mov ebx, eax
and ebx, ebx
je 0x40a8a3
push dword [esp + 0x44]
call fcn.0047f12f
and eax, eax
je 0x40a89a
push edx
call fcn.0048d530
pop edx
push eax
push edx
call fcn.0048d530
pop edx
push eax
push 0
push dword [esp + 0x50]
call fcn.0047f157
lea eax, [esp + 0x20]
push eax
call fcn.0048d5d0
push edx
call fcn.0048d530
pop edx
push eax
push edx
call fcn.0048d530
pop edx
push eax
push 1
push dword [esp + 0x50]
call fcn.0047f157
lea eax, [esp + 0x24]
push eax
call fcn.0048d5d0
push edx
call fcn.0048d530
pop edx
push eax
push edx
call fcn.0048d530
pop edx
push eax
push 2
push dword [esp + 0x50]
call fcn.0047f157
lea eax, [esp + 0x28]
push eax
call fcn.0048d5d0
push edx
call fcn.0048d530
pop edx
push eax
push edx
call fcn.0048d530
pop edx
push eax
push 3
push dword [esp + 0x50]
call fcn.0047f157
lea eax, [esp + 0x2c]
push eax
call fcn.0048d5d0
push edx
call fcn.0048d530
pop edx
push eax
push edx
call fcn.0048d530
pop edx
push eax
push 4
push dword [esp + 0x50]
call fcn.0047f157
lea eax, [esp + 0x30]
push eax
call fcn.0048d5d0
push edx
call fcn.0048d530
pop edx
push eax
push edx
call fcn.0048d530
pop edx
push eax
push 5
push dword [esp + 0x50]
call fcn.0047f157
lea eax, [esp + 0x34]
push eax
call fcn.0048d5d0
push dword [esp + 0x1c]
call fcn.00413fd1
and eax, eax
je 0x40a874
push dword [esp + 4]
call fcn.00486cba
mov edx, dword [esp + 0x1c]
push edx
call fcn.0048d530
pop edx
push eax
push edx
call fcn.0048d570
mov ebp, dword [esp + 0xc]
lea eax, [ebp + 8]
push eax
call fcn.0048d5d0
mov edx, dword [esp + 0x20]
push edx
call fcn.0048d530
pop edx
push eax
push edx
call fcn.0048d570
lea eax, [ebp + 0xc]
push eax
call fcn.0048d5d0
mov ebx, dword [esp + 0xc]
cmp ebx, 0x1e
jle 0x40a88c
call fcn.0041a818
mov dword [esp + 0xc], 0
jmp 0x40a895
mov ebx, dword [esp + 0xc]
inc ebx
mov dword [esp + 0xc], ebx
jmp 0x40a723
push dword [esp + 0x44]
call fcn.0047f184
inc dword [esp + 0x10]
jno 0x40a535
push 0
push 0x68
call fcn.00471d63
mov dword [esp + 0x34], 0
push dword [esp + 4]
call fcn.00486d58
mov ebx, eax
and ebx, ebx
jle 0x40aae2
mov eax, str.Delete_key:
push eax
call fcn.0040d182
push dword [esp + 4]
call fcn.00486d62
push dword [esp + 4]
call fcn.00486d77
or eax, eax
je 0x40aac4
mov ebp, dword [esp + 8]
push dword [ebp + 8]
push dword [esp + 4]
push dword [esp + 0x4c]
call fcn.0040b6b2
mov ebp, dword [esp + 8]
push dword [ebp + 8]
call fcn.0040d182
mov ebx, dword [esp + 0x34]
inc ebx
mov dword [esp + 0x34], ebx
push edx
call fcn.0048d530
pop edx
push eax
push edx
call fcn.0048d530
pop edx
push eax
mov edx, 0x5d6716
push edx
call fcn.0048d570
push edx
call fcn.0048d530
pop edx
push eax
push edx
call fcn.0048d530
pop edx
push eax
mov eax, dword [esp + 0x44]
cdq
push edx
push eax
call fcn.0048ad90
pop eax
call fcn.0048d660
push 0x68
call fcn.0042e5e2
add dword [esp + 4], edx
call fcn.004734ac
call fcn.0042e610
push 0x4d
call fcn.00478744
mov dword [esp + 0x10], eax
jmp 0x40a98a
xor eax, eax
cmp eax, dword [esp + 0x10]
jg 0x40aa7b
push dword [esp + 0x10]
push 0x4d
call fcn.00473779
mov ebx, eax
and ebx, 1
and ebx, ebx
je 0x40aa71
push edx
call fcn.0048d530
pop edx
push eax
push edx
call fcn.0048d530
pop edx
push eax
push 0
push dword [esp + 0x1c]
push 0x4d
call fcn.00478771
call fcn.0048d660
mov ebp, dword [esp + 0xc]
mov edx, dword [ebp + 8]
pop ecx
push ecx
call fcn.0042e600
mov ecx, eax
call fcn.0042e590
jne 0x40aa51
push edx
call fcn.0048d530
pop edx
push eax
mov ebp, dword [esp + 0xc]
push dword [ebp + 0xc]
push edx
call fcn.0048d530
pop edx
push eax
push edx
call fcn.0048d530
pop edx
push eax
push edx
call fcn.0048d530
pop edx
push eax
push 0
push dword [esp + 0x28]
push 0x4d
call fcn.00478771
call fcn.0042e5e2
add dword [esp], edx
call fcn.0041a15d
call fcn.0042e5e2
add dword [esp], edx
call fcn.0048ad20
call fcn.0042e610
mov ebx, eax
and ebx, ebx
jg 0x40aa51
jmp 0x40aa58
mov eax, 1
jmp 0x40aa5a
xor eax, eax
and eax, eax
je 0x40aa71
push dword [esp + 0x10]
push 0x4d
call fcn.004787bd
call fcn.0041a818
dec dword [esp + 0x10]
jno 0x40a98a
mov ebx, dword [esp + 0xc]
cmp ebx, 0x1e
jle 0x40aa93
call fcn.0041a818
mov dword [esp + 0xc], 0
jmp 0x40aa9c
mov ebx, dword [esp + 0xc]
inc ebx
mov dword [esp + 0xc], ebx
push 0x1b
call sub.USER32.dll_GetKeyState
mov ebx, eax
cmp ebx, 1
jle 0x40aabf
call fcn.0047af05
mov ebx, eax
and ebx, ebx
jne 0x40aabf
call fcn.0041a818
jmp 0x40aac4
jmp 0x40a8eb
mov eax, 0x5cf064
push eax
call fcn.0040d182
push 0x4d
call fcn.004735b4
push dword [esp + 0x44]
call fcn.00411392
mov eax, str.Commit
push eax
push dword [esp + 0x48]
call fcn.0047f005
mov ebx, eax
and ebx, ebx
jne 0x40ab3a
push edx
call fcn.0048d530
pop edx
push eax
push edx
call fcn.0048d530
pop edx
push eax
mov edx, str.Add_link_error
push edx
call fcn.0048d570
push edx
call fcn.0048d530
pop edx
push eax
push edx
call fcn.0048d530
pop edx
push eax
call fcn.0047f041
pop eax
call fcn.0042e5e2
add dword [esp], edx
call fcn.00420059
call fcn.0042e610
push dword [esp + 4]
call fcn.00486dab
push 0
call fcn.0040e3ec
mov eax, 0x5cf064
push eax
push 0x68
call fcn.004734ac
xor eax, eax
push dword [esp + 0x2c]
call fcn.0048d760
push dword [esp + 0x24]
call fcn.0048d760
push dword [esp]
call fcn.0048d760
push dword [esp + 0x14]
call fcn.0048d760
push dword [esp + 0x20]
call fcn.0048d760
push dword [esp + 0x18]
call fcn.0048d760
push dword [esp + 0x30]
call fcn.0048d760
push dword [esp + 0x1c]
call fcn.0048d760
push dword [esp + 0x28]
call fcn.0048d760
push eax
push dword [esp + 8]
call fcn.00486dab
pop eax
add esp, 0x38
pop ebx
pop ebp
ret 8