Function at 0x4b0680
Capabilities:
Read file on windows
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x48
push ebx
push esi
xor ebx, ebx
mov dword [ebp - 0x28], 0
push 0x20000000
mov dword [ebp - 0xc], ebx
mov byte [ebp - 1], 2
mov dword [ebp - 0x10], ebx
call sub.WS2_32.dll_htonl
push 0x4000000
mov dword [ebp - 0x2c], eax
call sub.WS2_32.dll_htonl
push 0x121
mov dword [ebp - 0x30], eax
call sub.WS2_32.dll_htons
mov esi, dword [ebp + 8]
movzx eax, ax
mov dword [ebp - 0x34], eax
mov byte [ebp - 2], 0x22
mov dword [ebp - 0x1c], ebx
mov byte [ebp - 3], 0x23
mov dword [ebp - 0x24], ebx
test esi, esi
je 0x4b0af7
cmp dword [ebp + 0xc], ebx
je 0x4b0af7
cmp dword [ebp + 0x10], 2
push edi
je 0x4b07ea
push 0x50e4c8
push esi
call fcn.004b629c
mov edi, eax
add esp, 8
mov dword [ebp - 0x24], edi
test edi, edi
jne 0x4b0721
push esi
push str.InstallCAToOperaFile___Cant_open_file
call fcn.004ae990
add esp, 8
or eax, 0xffffffff
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
push 2
push 0
push edi
call fcn.004b6340
push edi
call fcn.004b6753
push 0
mov esi, eax
push 0
push edi
mov dword [ebp + 8], esi
call fcn.004b6340
lea eax, [esi + 1]
push eax
call fcn.004b7328
mov esi, eax
add esp, 0x20
mov eax, dword [ebp + 0x10]
mov dword [ebp - 0x28], esi
test eax, eax
je 0x4b076d
mov eax, dword [ebp + 8]
inc eax
push eax
call fcn.004b7328
mov ebx, eax
mov dword [ebp - 0xc], eax
mov eax, dword [ebp + 0x10]
add esp, 4
test esi, esi
je 0x4b07cc
test eax, eax
je 0x4b0779
test ebx, ebx
je 0x4b07cc
push edi
push dword [ebp + 8]
push 1
push esi
call fcn.004b6984
add esp, 0x10
cmp dword [ebp + 0x10], 0
mov byte [eax + esi], 0
mov dword [ebp - 8], eax
je 0x4b07c5
push 0
push 0
lea ecx, [ebp - 8]
inc eax
push ecx
push ebx
push 0
push eax
push esi
call dword [sym.imp.CRYPT32.dll_CryptStringToBinaryA]
mov edi, eax
neg edi
sbb edi, edi
inc edi
je 0x4b0838
push str.InstallCAToOperaFile___Ascii_to_binary_failed
call fcn.004ae970
jmp 0x4b0ac0
mov ebx, esi
mov dword [ebp - 0xc], ebx
jmp 0x4b083b
push str.no_memory_n
call fcn.004b6bad
add eax, 0x40
push eax
call fcn.004b97ec
add esp, 8
or edi, 0xffffffff
jmp 0x4b0ac3
lea ecx, [esi + 1]
lea ecx, [ecx]
mov al, byte [esi]
inc esi
test al, al
jne 0x4b07f0
sub esi, ecx
mov dword [ebp - 8], esi
inc esi
push esi
call fcn.004b7328
add esp, 4
mov ebx, eax
lea eax, [ebp - 8]
mov dword [ebp - 0xc], ebx
push 0
push 0
push eax
push ebx
push 0
push esi
push dword [ebp + 8]
call dword [sym.imp.CRYPT32.dll_CryptStringToBinaryA]
mov edi, eax
neg edi
sbb edi, edi
inc edi
je 0x4b0838
push str.InstallCAToOperaFile___Ascii_to_binary_failed__2_
call fcn.004ae970
jmp 0x4b0ad1
mov eax, dword [ebp - 8]
push eax
call sub.WS2_32.dll_htonl
mov esi, dword [ebp + 0xc]
mov dword [ebp - 0x20], eax
mov eax, dword [ebp - 8]
mov dword [ebp - 0x44], eax
lea eax, [ebp - 0x48]
push eax
push 0x4b0b10
push 0
push 0
push esi
mov dword [ebp - 0x48], ebx
mov dword [ebp - 0x40], 0
call fcn.004b01e0
mov edi, eax
add esp, 0x14
test edi, edi
je 0x4b0882
push str.InstallCAToOperaFile___Unknown_Opera_dat_file
call fcn.004ae970
jmp 0x4b0ac0
cmp dword [ebp - 0x40], 0
je 0x4b0897
push str.InstallCAToOperaFile___CA_already_installed
call fcn.004ae970
jmp 0x4b0ac0
push 0x4d2e94
push esi
call fcn.004b629c
mov esi, eax
add esp, 8
mov dword [ebp + 8], esi
test esi, esi
jne 0x4b08c6
push dword [ebp + 0xc]
push str.InstallCAToOperaFile___Cant_open_file
call fcn.004ae990
add esp, 8
or edi, 0xffffffff
jmp 0x4b0ac3
push 2
push 0
push esi
call fcn.004b6340
add esp, 0xc
push dword [ebp - 8]
call sub.WS2_32.dll_htonl
cmp dword [0x522124], 0
mov dword [ebp - 0x20], eax
jne 0x4b08f6
call sub.libnspr4.dll_PR_Init
mov dword [0x522124], 1
push 0x50e4f8
call sub.nss3.dll_NSS_NoDB_Init
add esp, 4
test eax, eax
je 0x4b0919
push str.InstallCAToOperaFile___Failed_to_initialize_nss_n
call fcn.004ae970
add esp, 4
jmp 0x4b0aba
push dword [ebp - 8]
push ebx
call sub.smime3.dll_CERT_DecodeCertFromPackage
add esp, 8
mov dword [ebp - 0x14], eax
test eax, eax
jne 0x4b0941
push str.InstallCAToOperaFile___Could_not_obtain_certificate_from_file_n
call fcn.004ae970
add esp, 4
or edi, 0xffffffff
jmp 0x4b0ab5
push dword [eax + 8]
call sub.nss3.dll_CERT_AsciiToName
mov ebx, eax
push ebx
mov dword [ebp - 0x3c], ebx
call sub.nss3.dll_CERT_GetCommonName
add esp, 8
mov dword [ebp - 0x18], eax
test eax, eax
jne 0x4b096a
push ebx
call sub.nss3.dll_CERT_GetOrgName
add esp, 4
mov dword [ebp - 0x18], eax
mov ebx, eax
lea ecx, [ebx + 1]
nop
mov al, byte [ebx]
inc ebx
test al, al
jne 0x4b0970
sub ebx, ecx
push ebx
call sub.WS2_32.dll_htonl
push esi
push 1
mov dword [ebp - 0x38], eax
lea eax, [ebp - 1]
push 1
push eax
call fcn.004b6de2
push esi
push 1
lea eax, [ebp - 0x10]
push 4
push eax
call fcn.004b6de2
push esi
call fcn.004b6753
push dword [ebp + 8]
mov esi, eax
lea eax, [ebp - 0x2c]
push 1
push 4
push eax
call fcn.004b6de2
push dword [ebp + 8]
lea eax, [ebp - 0x30]
push 1
push 4
push eax
call fcn.004b6de2
add esp, 0x44
lea eax, [ebp - 0x34]
push dword [ebp + 8]
push 1
push 2
push eax
call fcn.004b6de2
push dword [ebp + 8]
lea eax, [ebp - 0x38]
push 1
push 4
push eax
call fcn.004b6de2
push dword [ebp + 8]
push 1
push ebx
push dword [ebp - 0x18]
call fcn.004b6de2
mov ebx, dword [ebp + 8]
lea eax, [ebp - 2]
push ebx
push 1
push 1
push eax
call fcn.004b6de2
mov eax, dword [ebp - 0x14]
add esp, 0x40
push dword [eax + 0x50]
call sub.WS2_32.dll_htonl
push ebx
push 1
mov dword [ebp - 0x1c], eax
lea eax, [ebp - 0x1c]
push 4
push eax
call fcn.004b6de2
mov eax, dword [ebp - 0x14]
push ebx
push 1
push dword [eax + 0x50]
push dword [eax + 0x4c]
call fcn.004b6de2
push ebx
push 1
lea eax, [ebp - 3]
push 1
push eax
call fcn.004b6de2
push ebx
push 1
lea eax, [ebp - 0x20]
push 4
push eax
call fcn.004b6de2
add esp, 0x40
push ebx
mov ebx, dword [ebp - 0xc]
push 1
push dword [ebp - 8]
push ebx
call fcn.004b6de2
push dword [ebp + 8]
call fcn.004b6753
add esp, 0x14
sub eax, esi
push eax
call sub.WS2_32.dll_htonl
mov dword [ebp - 0x10], eax
lea eax, [esi - 4]
mov esi, dword [ebp + 8]
push 0
push eax
push esi
call fcn.004b6340
push esi
push 1
lea eax, [ebp - 0x10]
push 4
push eax
call fcn.004b6de2
push dword [ebp - 0x3c]
call sub.nss3.dll_CERT_DestroyName
mov eax, dword [ebp - 0x14]
push eax
call sub.nss3.dll_CERT_DestroyCertificate
push dword [ebp - 0x18]
call sub.nss3.dll_PORT_Free
add esp, 0x28
call sub.nss3.dll_NSS_Shutdown
push esi
call fcn.004b6a9c
add esp, 4
cmp dword [ebp + 0x10], 2
je 0x4b0ad4
push dword [ebp - 0x24]
call fcn.004b6a9c
add esp, 4
push dword [ebp - 0x28]
call fcn.004b605a
add esp, 4
cmp dword [ebp + 0x10], 0
je 0x4b0aee
push ebx
call fcn.004b605a
add esp, 4
mov eax, edi
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
push str.InstallCAToOperaFile___Empty_catfile_or_datfile
call fcn.004ae970
add esp, 4
or eax, 0xffffffff
pop esi
pop ebx
mov esp, ebp
pop ebp
ret