Function at 0x66f690
Capabilities:
Encode data using xor
Hash data with crc32

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x444
mov eax, dword [0x82aea4]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 0x20]
push ebx
push esi
mov esi, ecx
mov dword [ebp - 0x418], eax
mov eax, dword [esi + 4]
push edi
mov dword [esi], 0x592717
test eax, eax
js 0x66f6c3
cmp eax, 0x3e
jle 0x66f6e6
push str.write_relmap_file
push 0x29a
push str.src_backendutilscache_relmapper.c
call sym.postgres.exe_elog_start
push str.attempt_to_write_bogus_relation_mapping
push 0x14
call sym.postgres.exe_elog_finish
add esp, 0x14
or ecx, 0xffffffff
mov dword [esi + 0x1f8], ecx
mov ebx, esi
mov edx, 0x1f8
movzx edi, byte [ebx]
mov eax, ecx
sar eax, 0x18
xor eax, edi
and eax, 0xff
shl ecx, 8
xor ecx, dword [eax*4 + sym.postgres.exe_pg_crc32_table]
inc ebx
dec edx
mov dword [esi + 0x1f8], ecx
jne 0x66f6f6
not ecx
mov dword [esi + 0x1f8], ecx
push str.pg_filenode.map
cmp byte [ebp + 8], dl
je 0x66f750
push str.global__s
lea ecx, [ebp - 0x404]
push 0x400
push ecx
call sym.postgres.exe_pg_snprintf
add esp, 0x10
mov dword [ebp - 0x418], 0x85ea48
jmp 0x66f77a
mov edx, dword [ebp - 0x418]
push edx
push 0x6b04b0
lea eax, [ebp - 0x404]
push 0x400
push eax
call sym.postgres.exe_pg_snprintf
add esp, 0x14
mov dword [ebp - 0x418], 0x85ec48
push 0x180
lea ecx, [ebp - 0x404]
push 0x8101
push ecx
call sym.postgres.exe_BasicOpenFile
xor ebx, ebx
add esp, 0xc
mov dword [ebp - 0x41c], eax
cmp eax, ebx
jge 0x66f7e0
push ebx
push str.write_relmap_file
push 0x2be
push str.src_backendutilscache_relmapper.c
push 0x14
call sym.postgres.exe_errstart
add esp, 0x14
test al, al
je 0x66f7e0
lea edx, [ebp - 0x404]
push edx
push str.could_not_open_relation_mapping_file___s_:__m
call sym.postgres.exe_errmsg
add esp, 8
push eax
call sym.postgres.exe_errcode_for_file_access
push eax
call sym.postgres.exe_errfinish
add esp, 8
mov edi, 0x200
cmp byte [ebp + 0xc], bl
je 0x66f861
inc dword [sym.postgres.exe_CritSectionCount]
mov ecx, dword [ebp + 0x1c]
mov eax, dword [ebp + 0x18]
mov dword [ebp - 0x410], ecx
lea ecx, [ebp - 0x444]
push ecx
mov dword [ebp - 0x414], eax
lea edx, [ebp - 0x414]
lea eax, [ebp - 0x430]
push ebx
push 7
mov dword [ebp - 0x40c], edi
mov dword [ebp - 0x444], edx
mov dword [ebp - 0x440], 0xc
mov dword [ebp - 0x43c], ebx
mov dword [ebp - 0x434], eax
mov dword [ebp - 0x430], esi
mov dword [ebp - 0x42c], edi
mov dword [ebp - 0x428], ebx
mov dword [ebp - 0x420], ebx
call sym.postgres.exe_XLogInsert
push edx
push eax
call sym.postgres.exe_XLogFlush
add esp, 0x14
mov ebx, dword [sym.imp.MSVCR100.dll__errno]
call ebx
mov edx, dword [ebp - 0x41c]
push edi
push esi
push edx
mov dword [eax], 0
call dword [sym.imp.MSVCR100.dll__write]
add esp, 0xc
cmp eax, edi
je 0x66f8d6
call ebx
cmp dword [eax], 0
jne 0x66f894
call ebx
mov dword [eax], 0x1c
push 0
push str.write_relmap_file
push 0x2e5
push str.src_backendutilscache_relmapper.c
push 0x14
call sym.postgres.exe_errstart
add esp, 0x14
test al, al
je 0x66f8d6
lea eax, [ebp - 0x404]
push eax
push str.could_not_write_to_relation_mapping_file___s_:__m
call sym.postgres.exe_errmsg
add esp, 8
push eax
call sym.postgres.exe_errcode_for_file_access
push eax
call sym.postgres.exe_errfinish
add esp, 8
mov edi, dword [ebp - 0x41c]
push edi
call sym.postgres.exe_pg_fsync
add esp, 4
test eax, eax
je 0x66f92b
push 0
push str.write_relmap_file
push 0x2f2
push str.src_backendutilscache_relmapper.c
push 0x14
call sym.postgres.exe_errstart
add esp, 0x14
test al, al
je 0x66f92b
lea ecx, [ebp - 0x404]
push ecx
push str.could_not_fsync_relation_mapping_file___s_:__m
call sym.postgres.exe_errmsg
add esp, 8
push eax
call sym.postgres.exe_errcode_for_file_access
push eax
call sym.postgres.exe_errfinish
add esp, 8
push edi
call dword [sym.imp.MSVCR100.dll__close]
add esp, 4
test eax, eax
je 0x66f97b
push 0
push str.write_relmap_file
push 0x2f8
push str.src_backendutilscache_relmapper.c
push 0x14
call sym.postgres.exe_errstart
add esp, 0x14
test al, al
je 0x66f97b
lea edx, [ebp - 0x404]
push edx
push str.could_not_close_relation_mapping_file___s_:__m
call sym.postgres.exe_errmsg
add esp, 8
push eax
call sym.postgres.exe_errcode_for_file_access
push eax
call sym.postgres.exe_errfinish
add esp, 8
cmp byte [ebp + 0x10], 0
je 0x66f98d
mov eax, dword [ebp + 0x18]
push eax
call sym.postgres.exe_CacheInvalidateRelmap
add esp, 4
cmp byte [ebp + 0x14], 0
je 0x66f9c8
xor edi, edi
cmp dword [esi + 4], edi
jle 0x66f9c8
lea ebx, [esi + 0xc]
lea ecx, [ecx]
mov edx, dword [ebp + 0x1c]
mov ecx, dword [ebx]
push 0
sub esp, 0xc
mov eax, esp
mov dword [eax], edx
mov edx, dword [ebp + 0x18]
mov dword [eax + 4], edx
mov dword [eax + 8], ecx
call sym.postgres.exe_RelationPreserveStorage
inc edi
add esp, 0x10
add ebx, 8
cmp edi, dword [esi + 4]
jl 0x66f9a0
cmp byte [ebp + 0xc], 0
mov edi, dword [ebp - 0x418]
mov ecx, 0x80
rep movsd dword es:[edi], dword [esi]
je 0x66f9e1
dec dword [sym.postgres.exe_CritSectionCount]
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.006a8ca2
mov esp, ebp
pop ebp
ret