Function at 0x40b120
Capabilities:
Create directory
Delete file
Extract resource via kernel32 functions
Get file size
Read file on windows
Set file attributes
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x234
mov eax, dword [0x45c040]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push esi
push edi
push str.SCID
mov edi, ecx
push str.SOURCE_CONTROL_ID
push edi
mov dword [ebp - 0x230], edi
call dword [sym.imp.KERNEL32.dll_FindResourceW]
mov esi, eax
test esi, esi
je 0x40b278
push esi
push edi
call dword [sym.imp.KERNEL32.dll_SizeofResource]
mov ebx, eax
test ebx, ebx
je 0x40b278
push esi
push edi
call dword [sym.imp.KERNEL32.dll_LoadResource]
nop dword [eax + eax]
test eax, eax
je 0x40b278
push eax
call dword [sym.imp.KERNEL32.dll_LockResource]
mov edi, eax
test edi, edi
je 0x40b278
push 0
push 0x45e8f0
call dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
test eax, eax
jne 0x40b1bb
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0xb7
jne 0x40b278
push 0x2002
push 0x45e8f0
call dword [sym.imp.KERNEL32.dll_SetFileAttributesW]
push 0x208
lea eax, [ebp - 0x210]
push 0
push eax
call fcn.0041f350
add esp, 0xc
lea eax, [ebp - 0x210]
push 0x45e8f0
push str._sSCID.bin
push 0xffffffffffffffff
push 0x104
push eax
call fcn.00401640
add esp, 0x14
mov byte [ebp - 0x221], 0
lea eax, [ebp - 0x210]
push 0
push 0x80
push 4
push 0
push 0
push 0xc0000000
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov esi, eax
mov dword [ebp - 0x22c], esi
cmp esi, 0xffffffff
je 0x40b417
call dword [sym.imp.KERNEL32.dll_GetLastError]
nop
cmp eax, 0xb7
jne 0x40b45b
lea eax, [ebp - 0x220]
mov dword [ebp - 0x220], 0
push eax
push esi
mov dword [ebp - 0x21c], 0
call dword [sym.imp.KERNEL32.dll_GetFileSizeEx]
test eax, eax
jne 0x40b28b
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
xor al, al
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0041b32c
mov esp, ebp
pop ebp
ret
mov esi, dword [ebp - 0x220]
push esi
call fcn.0041b33f
add esp, 4
mov dword [ebp - 0x228], eax
push esi
push 0
push eax
call fcn.0041f350
add esp, 0xc
mov dword [ebp - 0x218], 0
lea eax, [ebp - 0x218]
push 0
push eax
push dword [ebp - 0x220]
push dword [ebp - 0x228]
push dword [ebp - 0x22c]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x40b42a
mov esi, dword [ebp - 0x218]
cmp esi, dword [ebp - 0x220]
jne 0x40b42a
mov eax, dword [ebp - 0x228]
cmp esi, ebx
ja 0x40b34c
xor ebx, ebx
cmp eax, edi
je 0x40b33f
test esi, esi
je 0x40b33f
lea ecx, [eax + esi]
sub edi, eax
nop dword [eax]
movzx eax, byte [edi + ecx - 1]
dec ecx
mov dword [ebp - 0x214], ecx
movzx edx, byte [ecx]
sub edx, eax
mov eax, edx
not eax
sar eax, 8
lea ecx, [edx - 1]
sar ecx, 8
and ecx, eax
and ebx, ecx
mov ecx, dword [ebp - 0x214]
or ebx, edx
sub esi, 1
jne 0x40b310
lea eax, [ebx - 1]
sar ebx, 8
sar eax, 8
add eax, ebx
jmp 0x40b39a
xor esi, esi
cmp eax, edi
je 0x40b38f
lea ecx, [eax + ebx]
sub edi, eax
nop word [eax + eax]
movzx eax, byte [edi + ecx - 1]
dec ecx
mov dword [ebp - 0x214], ecx
movzx edx, byte [ecx]
sub edx, eax
mov eax, edx
not eax
sar eax, 8
lea ecx, [edx - 1]
sar ecx, 8
and ecx, eax
and esi, ecx
mov ecx, dword [ebp - 0x214]
or esi, edx
sub ebx, 1
jne 0x40b360
lea eax, [esi - 1]
sar esi, 8
sar eax, 8
add eax, esi
add eax, 1
jne 0x40b3ab
push str.No_Steam_update_found__n_n
call fcn.00403aa0
jmp 0x40b3c1
push str.Your_Steam_version_has_changed__SteamLite_might_not_work_correctly_until_its_been_updated__n_n
mov ecx, 0xc
call fcn.00414e80
mov byte [ebp - 0x221], 1
add esp, 4
push dword [ebp - 0x228]
call fcn.0041b33a
mov esi, dword [ebp - 0x22c]
add esp, 4
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push 0x2002
lea eax, [ebp - 0x210]
push eax
call dword [sym.imp.KERNEL32.dll_SetFileAttributesW]
cmp byte [ebp - 0x221], 1
jne 0x40b417
lea eax, [ebp - 0x210]
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
cmp eax, 1
jne 0x40b417
mov ecx, dword [ebp - 0x230]
call fcn.0040b120
mov al, 1
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0041b32c
mov esp, ebp
pop ebp
ret
push dword [ebp - 0x22c]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push dword ds:[ebp - 0x228]
call fcn.0041b33a
add esp, 4
xor al, al
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0041b32c
mov esp, ebp
pop ebp
ret
nop dword [eax + eax]
call dword [sym.imp.KERNEL32.dll_GetLastError]
test eax, eax
jne 0x40b3d8
push eax
mov dword [ebp - 0x214], eax
lea eax, [ebp - 0x214]
push eax
push ebx
push edi
push esi
call dword [sym.imp.KERNEL32.dll_WriteFile]
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push 0x2002
lea eax, [ebp - 0x210]
push eax
call dword [sym.imp.KERNEL32.dll_SetFileAttributesW]
mov ecx, dword [ebp - 4]
mov al, 1
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.0041b32c
mov esp, ebp
pop ebp
ret