Function at 0x6b40f070
Capabilities:
Write file on windows

Disassembly:
push ebp
push edi
mov edi, edx
push esi
push ebx
mov ebx, eax
add ebx, edi
sub esp, 0x7c
mov dword [esp + 0x3c], edx
mov edx, dword [esp + 0x94]
mov esi, dword [esp + 0x98]
mov dword [esp + 0x2c], eax
mov dword [esp + 0x44], edx
mov eax, dword [esp + 0x90]
mov edx, ecx
and edx, 7
mov dword [esp + 0x38], esi
mov esi, dword [sym.imp.libssp_0.dll___stack_chk_guard]
mov dword [esp + 0x6c], esi
xor esi, esi
mov word [esp + 0x40], ax
mov dword [esp + 0x28], ebx
mov dword [esp + 0x24], edx
cmp edx, 2
je 0x6b40f518
cmp edx, 4
jne 0x6b40f0d7
and edi, 3
jne 0x6b40f6b2
mov edi, dword [esp + 0x28]
xor ebp, ebp
cmp dword [esp + 0x2c], edi
je 0x6b40f1dd
and eax, 1
and ecx, 8
mov edi, dword [esp + 0x2c]
xor ebp, ebp
mov word [esp + 0x32], ax
mov dword [esp + 0x34], ecx
mov eax, dword [esp + 0x2c]
movzx esi, word [esp + 0x32]
shl esi, 5
cmp eax, edi
mov eax, 0
cmovne esi, eax
mov eax, dword [esp + 0x24]
cmp eax, 2
je 0x6b40f3c0
jg 0x6b40f200
test eax, eax
je 0x6b40f3e0
cmp eax, 1
jne 0x6b40f1d8
movzx eax, byte [edi]
add edi, 1
mov dword [esp + 0x54], eax
cmp dword [esp + 0x28], edi
je 0x6b40f21c
mov edx, dword [esp + 0x34]
test edx, edx
jne 0x6b40f236
cmp eax, 0xffff
ja 0x6b40f418
cmp eax, 0xff
ja 0x6b40f4c0
or si, word [esp + 0x40]
mov byte [esp + 0x53], al
mov edx, esi
test al, al
js 0x6b40f478
and dx, word [eax + eax + 0x6b5c8420]
test dl, 0x61
je 0x6b40f6a8
and edx, 8
je 0x6b40f5b0
mov eax, dword [esp + 0x44]
test eax, eax
je 0x6b40f1a4
mov byte [eax], 1
mov ecx, dword [esp + 0x38]
test ecx, ecx
je 0x6b40f4b6
lea eax, [esp + 0x53]
mov dword [esp + 8], 1
mov dword [esp + 4], eax
mov dword [esp], ecx
call sym.libcrypto_1_1.dll_BIO_write
cmp eax, 1
je 0x6b40f4b6
lea esi, [esi]
mov ebp, 0xffffffff
mov eax, dword [esp + 0x6c]
xor eax, dword [sym.imp.libssp_0.dll___stack_chk_guard]
jne 0x6b40f6e8
add esp, 0x7c
mov eax, ebp
pop ebx
pop esi
pop edi
pop ebp
ret
cmp dword [esp + 0x24], 4
jne 0x6b40f1d8
mov eax, dword [edi]
add edi, 4
bswap eax
mov dword [esp + 0x54], eax
cmp dword [esp + 0x28], edi
jne 0x6b40f14a
mov edx, dword [esp + 0x34]
cmp word [esp + 0x32], 0
mov ecx, 0x40
cmovne esi, ecx
test edx, edx
je 0x6b40f156
lea ebx, [esp + 0x5b]
mov dword [esp + 8], eax
mov dword [esp + 4], 6
mov dword [esp], ebx
call sym.libcrypto_1_1.dll_UTF8_putc
test eax, eax
jle 0x6b40f2f7
or si, word [esp + 0x40]
mov dword [esp + 0x48], edi
mov ecx, esi
mov edx, esi
mov edi, dword [esp + 0x38]
mov word [esp + 0x42], si
and dx, 0x40f
and ecx, 4
lea esi, [ebx + eax]
mov word [esp + 0x4e], dx
mov word [esp + 0x4c], cx
lea esi, [esi]
movzx eax, byte [ebx]
mov byte [esp + 0x53], al
test al, al
js 0x6b40f310
movzx ecx, al
movzx edx, word [esp + 0x42]
and dx, word [ecx + ecx + 0x6b5c8420]
test dl, 0x61
je 0x6b40f560
and edx, 8
je 0x6b40f370
mov eax, dword [esp + 0x44]
test eax, eax
je 0x6b40f2c0
mov byte [eax], 1
test edi, edi
je 0x6b40f2e5
lea eax, [esp + 0x53]
mov dword [esp + 8], 1
mov dword [esp + 4], eax
mov dword [esp], edi
call sym.libcrypto_1_1.dll_BIO_write
cmp eax, 1
jne 0x6b40f1d8
mov eax, 1
add ebx, 1
add ebp, eax
cmp esi, ebx
jne 0x6b40f288
mov edi, dword [esp + 0x48]
cmp dword [esp + 0x28], edi
jne 0x6b40f0fc
jmp 0x6b40f1dd
cmp word [esp + 0x4c], 0
movzx ecx, al
je 0x6b40f2c0
lea eax, [esp + 0x61]
mov dword [esp + 0xc], ecx
mov dword [esp + 8], 0x6b5c8398
mov dword [esp + 4], 0xb
mov dword [esp], eax
call sym.libcrypto_1_1.dll_BIO_snprintf
test edi, edi
je 0x6b40f360
lea eax, [esp + 0x61]
mov dword [esp + 8], 3
mov dword [esp + 4], eax
mov dword [esp], edi
call sym.libcrypto_1_1.dll_BIO_write
cmp eax, 3
jne 0x6b40f1d8
mov eax, 3
jmp 0x6b40f2ea
test edi, edi
je 0x6b40f3b6
mov dword [esp + 8], 1
mov dword [esp + 4], 0x6b5c8396
mov dword [esp], edi
call sym.libcrypto_1_1.dll_BIO_write
cmp eax, 1
jne 0x6b40f1d8
lea eax, [esp + 0x53]
mov dword [esp + 8], 1
mov dword [esp + 4], eax
mov dword [esp], edi
call sym.libcrypto_1_1.dll_BIO_write
cmp eax, 1
jne 0x6b40f1d8
mov eax, 2
jmp 0x6b40f2ea
movzx eax, word [edi]
add edi, 2
rol ax, 8
movzx eax, ax
mov dword [esp + 0x54], eax
jmp 0x6b40f140
mov ebx, dword [esp + 0x3c]
lea eax, [esp + 0x54]
mov dword [esp], edi
mov dword [esp + 8], eax
mov dword [esp + 4], ebx
call sym.libcrypto_1_1.dll_UTF8_getc
test eax, eax
js 0x6b40f1d8
sub ebx, eax
add edi, eax
mov eax, dword [esp + 0x54]
mov dword [esp + 0x3c], ebx
jmp 0x6b40f140
lea ebx, [esp + 0x61]
mov dword [esp + 0xc], eax
mov dword [esp + 8], str.W_08lX
mov dword [esp + 4], 0xb
mov dword [esp], ebx
call sym.libcrypto_1_1.dll_BIO_snprintf
mov eax, dword [esp + 0x38]
test eax, eax
je 0x6b40f45d
mov dword [esp + 8], 0xa
mov dword [esp + 4], ebx
mov dword [esp], eax
call sym.libcrypto_1_1.dll_BIO_write
cmp eax, 0xa
jne 0x6b40f1d8
mov eax, 0xa
add ebp, eax
cmp dword [esp + 0x28], edi
jne 0x6b40f0fc
jmp 0x6b40f1dd
and edx, 4
test dx, dx
jne 0x6b40f650
cmp eax, 0x5c
je 0x6b40f610
mov ebx, dword [esp + 0x38]
test ebx, ebx
je 0x6b40f4b6
lea eax, [esp + 0x53]
mov dword [esp + 8], 1
mov dword [esp + 4], eax
mov dword [esp], ebx
call sym.libcrypto_1_1.dll_BIO_write
cmp eax, 1
jne 0x6b40f1d8
mov eax, 1
add ebp, eax
jmp 0x6b40f464
lea ebx, [esp + 0x61]
mov dword [esp + 0xc], eax
mov dword [esp + 8], str.U_04lX
mov dword [esp + 4], 0xb
mov dword [esp], ebx
call sym.libcrypto_1_1.dll_BIO_snprintf
mov eax, dword [esp + 0x38]
test eax, eax
je 0x6b40f505
mov dword [esp + 8], 6
mov dword [esp + 4], ebx
mov dword [esp], eax
call sym.libcrypto_1_1.dll_BIO_write
cmp eax, 6
jne 0x6b40f1d8
mov eax, 6
add ebp, eax
jmp 0x6b40f464
test byte [esp + 0x3c], 1
je 0x6b40f0d7
mov dword [esp + 0x10], 0xa1
mov ebp, 0xffffffff
mov dword [esp + 0xc], str.crypto_asn1_a_strex.c
mov dword [esp + 8], 0x81
mov dword [esp + 4], 0x8e
mov dword [esp], 0xd
call sym.libcrypto_1_1.dll_ERR_put_error
jmp 0x6b40f1dd
test dx, 0x406
jne 0x6b40f31b
cmp al, 0x5c
jne 0x6b40f2c0
cmp word [esp + 0x4e], 0
je 0x6b40f2c0
test edi, edi
je 0x6b40f3b6
mov dword [esp + 8], 2
mov dword [esp + 4], 0x6b5c839e
mov dword [esp], edi
call sym.libcrypto_1_1.dll_BIO_write
cmp eax, 2
jne 0x6b40f1d8
jmp 0x6b40f3b6
mov esi, dword [esp + 0x38]
test esi, esi
je 0x6b40f5fa
mov dword [esp + 8], 1
mov dword [esp + 4], 0x6b5c8396
mov dword [esp], esi
call sym.libcrypto_1_1.dll_BIO_write
cmp eax, 1
jne 0x6b40f1d8
lea eax, [esp + 0x53]
mov dword [esp + 8], 1
mov dword [esp + 4], eax
mov dword [esp], esi
call sym.libcrypto_1_1.dll_BIO_write
cmp eax, 1
jne 0x6b40f1d8
mov eax, 2
add ebp, eax
jmp 0x6b40f464
test si, 0x40f
je 0x6b40f48d
mov eax, dword [esp + 0x38]
test eax, eax
je 0x6b40f5fa
mov dword [esp + 8], 2
mov dword [esp + 4], 0x6b5c839e
mov dword [esp], eax
call sym.libcrypto_1_1.dll_BIO_write
cmp eax, 2
jne 0x6b40f1d8
jmp 0x6b40f5fa
lea ebx, [esp + 0x61]
mov dword [esp + 0xc], eax
mov dword [esp + 8], 0x6b5c8398
mov dword [esp + 4], 0xb
mov dword [esp], ebx
call sym.libcrypto_1_1.dll_BIO_snprintf
mov eax, dword [esp + 0x38]
test eax, eax
je 0x6b40f695
mov dword [esp + 8], 3
mov dword [esp + 4], ebx
mov dword [esp], eax
call sym.libcrypto_1_1.dll_BIO_write
cmp eax, 3
jne 0x6b40f1d8
mov eax, 3
add ebp, eax
jmp 0x6b40f464
and dx, 0x406
jmp 0x6b40f47b
mov dword [esp + 0x10], 0x9b
mov ebp, 0xffffffff
mov dword [esp + 0xc], str.crypto_asn1_a_strex.c
mov dword [esp + 8], 0x85
mov dword [esp + 4], 0x8e
mov dword [esp], 0xd
call sym.libcrypto_1_1.dll_ERR_put_error
jmp 0x6b40f1dd
call sym.___stack_chk_fail
lea esi, [esi]