Function at 0x1400bfc70
Capabilities:
Validate payment card number using luhn algorithm

Disassembly:
mov qword [rsp + 8], rbx
mov dword [rsp + 0x20], r9d
mov dword [rsp + 0x10], edx
push rbp
push rsi
push rdi
push r12
push r13
push r14
push r15
sub rsp, 0x20
mov rax, qword [rcx + 0x28]
xor ebp, ebp
mov r10d, r8d
mov r13d, r9d
mov esi, edx
mov rbx, rcx
movzx r12d, bp
movzx r15d, bp
mov dword [rax + 0x4c], ebp
movzx r14d, bp
mov r8, qword [rcx + 0x28]
mov dword [rcx + 0x58], ebp
cmp dword [r8 + 0x50], 0xa
jge 0x1400bfd20
neg r10d
lea r11d, [rbp + 0xb]
sbb edi, edi
and edi, 2
lea rdx, [0x140000000]
cmp edi, 0xd
ja case.default.0x1400bfce0
movsxd rax, edi
mov ecx, dword [rdx + rax*4 + 0xc040c]
add rcx, rdx
jmp rcx
mov rcx, rbx
call fcn.1400bf0d0
test eax, eax
je 0x1400bfd42
mov rax, qword [rbx + 0x28]
cmp dword [rax + 0x4c], 0xfffffc5e
jne 0x1400bfd0f
mov edi, 0xa
lea rdx, str.WaitForAck_:_Sending_NAK__read_char_failure
mov rcx, rbx
call fcn.1400c13a0
mov r11d, reloc.WS2_32.dll_inet_addr
mov r8, qword [rbx + 0x28]
cmp dword [r8 + 0x50], 0xa
jl 0x1400bfcc7
mov dword [r8 + 0x4c], 0xfffffc74
mov eax, 0xfffffc74
mov rbx, qword [rsp + 0x60]
add rsp, 0x20
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbp
ret
cmp dword [rbx + 0x64], 0
je 0x1400bfd69
mov eax, dword [rbx + 0x60]
cmp eax, 3
jne 0x1400bfd59
lea edi, [rax + 1]
lea r15d, [rax - 1]
jmp 0x1400bfd0f
cmp eax, 5
jne 0x1400bfd69
mov r11d, reloc.WS2_32.dll_inet_addr
mov edi, r11d
jmp case.default.0x1400bfce0
mov rcx, qword [rbx + 0x28]
movsx eax, r14w
cmp eax, dword [rcx + 0x3c]
jne 0x1400bfd8e
mov dword [rcx + 0x4c], 0xfffffc6a
lea rdx, str.WaitForAck_:_Sending_NAK__buffer_overflow
mov edi, 0xa
jmp 0x1400bfd07
mov rcx, qword [rbx + 0x38]
movzx eax, byte [rbx + 0x60]
movsx rdx, r14w
inc r14w
mov byte [rdx + rcx], al
mov rcx, rbx
movzx edx, word [rbx + 0x60]
call fcn.1400beb00
jmp 0x1400bfd0f
movsx eax, byte [rbx + 0xe5]
add eax, 2
cmp dword [rbx + 0x68], eax
jle 0x1400bfde6
cmp dword [rbx + 0xc0], 0
jle 0x1400bfde6
mov dword [r8 + 0x4c], 0xfffffc73
mov edi, reloc.OLEAUT32.dll_VariantTimeToDosDateTime
mov rax, qword [rbx + 0x28]
inc dword [rax + 0x50]
mov dword [rbx + 0x68], ebp
jmp case.default.0x1400bfce0
test esi, esi
je 0x1400bfdef
mov edx, dword [rbx + 0x5c]
jmp 0x1400bfdf1
mov edx, ebp
mov rcx, qword [rbx + 0x18]
call fcn.1400bb020
mov dword [rbx + 0x60], eax
test eax, eax
js 0x1400bfe6d
cmp eax, 0x10
jne 0x1400bfe15
lea edi, [rax - 0xf]
lea rdx, str.WaitForAck_:_Got_DLE
jmp 0x1400bfd07
cmp eax, 0x15
jne 0x1400bfe29
lea edi, [rax - 9]
lea rdx, str.WaitForAck_:_Got_NAK_instead_of_DLE
jmp 0x1400bfd07
cmp eax, 5
jne 0x1400bfe48
lea rdx, str.WaitForAck_:_Got_ENQ_instead_of_DLE
mov rcx, rbx
lea edi, [rax + 6]
call fcn.1400c13a0
mov r11d, edi
jmp case.default.0x1400bfce0
cmp eax, 3
jne 0x1400bfd0f
mov rax, qword [rbx + 0x28]
lea rdx, str.WaitForAck_:_ETX_seen_too_early
mov edi, 0xa
mov dword [rax + 0x4c], 0xfffffc6a
jmp 0x1400bfd07
test esi, esi
je 0x1400c03af
cmp dword [rbx + 0xcc], 0
mov r11d, reloc.WS2_32.dll_inet_addr
jne 0x1400bfe8d
lea edi, [r11 + 1]
jmp case.default.0x1400bfce0
mov rax, qword [rbx + 0x28]
inc dword [rax + 0x50]
jmp case.default.0x1400bfce0
mov edx, dword [rbx + 0x5c]
mov rcx, qword [rbx + 0x18]
call fcn.1400bb020
mov dword [rbx + 0x60], eax
mov ecx, eax
test eax, eax
js 0x1400bfffe
add eax, 0xffffffd0
cmp eax, 9
ja 0x1400bffd1
cmp dword [rbx + 0xcc], 0
je 0x1400bfeec
cmp ecx, dword [rbx + 0xd0]
jne 0x1400bfeec
cmp dword [rbx + 0xc0], 0
mov dword [rbx + 0xcc], ebp
je 0x1400c03b9
mov edi, reloc.WS2_32.dll_listen
jmp 0x1400bfd0f
lea rdx, str.WaitForAck_:_Received_ACK
mov rcx, rbx
call fcn.1400c13a0
mov eax, dword [rbx + 0x60]
mov esi, dword [rbx + 0xc0]
mov ebp, dword [rbx + 0xc4]
mov dword [rbx + 0xd0], eax
add ebp, esi
mov eax, 0x66666667
imul ebp
sar edx, 1
mov eax, edx
shr eax, 0x1f
add edx, eax
lea eax, [rdx + rdx*4]
sub ebp, eax
test esi, esi
jle 0x1400bffb7
movsxd rdx, ebp
mov r13d, 0xffffffff
nop dword [rax + rax]
mov rcx, rdx
mov eax, 4
dec rdx
mov rdi, rdx
sar rdi, 0x3f
and edi, 5
add rdi, rcx
test rdx, rdx
cmovns eax, r13d
add ebp, eax
lea rcx, [rdi + 6]
mov eax, dword [rbx + 0x60]
add rcx, rcx
sub eax, 0x30
cmp dword [rbx + rcx*8], eax
jne 0x1400bffa8
lea ecx, [rbp + 1]
mov eax, 0x66666667
imul ecx
sar edx, 1
mov eax, edx
shr eax, 0x1f
add edx, eax
lea eax, [rdx + rdx*4]
sub ecx, eax
mov dword [rbx + 0xc4], ecx
lea rcx, [rdi - 1]
add rcx, rcx
mov rcx, qword [rbx + rcx*8 + 0x78]
call fcn.1400c0e60
dec dword [rbx + 0xc0]
dec esi
lea rdx, [rdi - 1]
test esi, esi
jg 0x1400bff40
mov r13d, dword [rsp + 0x78]
cmp dword [rbx + 0xcc], 0
je 0x1400c03b9
mov esi, dword [rsp + 0x68]
xor ebp, ebp
mov edi, ebp
jmp 0x1400bfd0f
cmp ecx, 0x3b
jne 0x1400bffdd
mov edi, ebp
jmp 0x1400bfd0f
mov r11d, reloc.WS2_32.dll_inet_addr
cmp ecx, 0x42
jne 0x1400bfff0
lea edi, [rcx - 0x40]
jmp case.default.0x1400bfce0
cmp ecx, 5
mov edi, ebp
cmove edi, r11d
jmp case.default.0x1400bfce0
mov edi, reloc.OLEAUT32.dll_VariantTimeToDosDateTime
jmp 0x1400bfd0f
mov edx, dword [rbx + 0x5c]
mov rcx, qword [rbx + 0x18]
call fcn.1400bb020
mov dword [rbx + 0x60], eax
test eax, eax
js 0x1400c0089
cmp eax, 5
jne 0x1400c002e
mov r11d, reloc.WS2_32.dll_inet_addr
mov edi, r11d
jmp case.default.0x1400bfce0
lea rdx, str.WaitForAck_:_Received__DLE__B
mov rcx, rbx
call fcn.1400c13a0
movzx edx, byte [rbx + 0xe4]
lea eax, [rdx - 1]
cmp al, 1
jbe 0x1400c0061
mov rcx, qword [rbx + 0x28]
cmp dl, 3
mov edx, 0xffffffff
mov eax, ebp
cmove eax, edx
mov dword [rcx + 0x40], eax
jmp 0x1400c006c
mov rax, qword [rbx + 0x28]
mov dword [rax + 0x40], 0xffff
movzx edx, word [rbx + 0x60]
mov rcx, rbx
lea r12d, [rdx - 0x30]
call fcn.1400beb00
mov r14d, ebp
mov edi, 3
jmp 0x1400bfd0f
mov edi, 0xa
lea rdx, str.WaitForAck_:_read_char_failure
jmp 0x1400bfd07
mov edx, 3
mov rcx, rbx
call fcn.1400beb00
mov rcx, rbx
call fcn.1400bf0d0
test eax, eax
je 0x1400c00bd
mov edi, 0xa
jmp 0x1400bfd0f
cmp dword [rbx + 0x64], 0
je 0x1400c00d7
cmp dword [rbx + 0x60], 5
jne 0x1400c00d7
mov r11d, reloc.WS2_32.dll_inet_addr
mov edi, r11d
jmp case.default.0x1400bfce0
movzx ecx, byte [rbx + 0xe4]
mov r11d, reloc.WS2_32.dll_inet_addr
lea eax, [rcx - 1]
cmp al, 1
jbe 0x1400c0100
cmp cl, 3
mov edi, 8
mov eax, 6
cmove edi, eax
jmp case.default.0x1400bfce0
mov edi, 5
jmp case.default.0x1400bfce0
movzx edx, word [rbx + 0x60]
mov rcx, rbx
call fcn.1400beb00
mov rcx, rbx
call fcn.1400bf0d0
cmp eax, 0xfffffc5e
jne 0x1400c012f
mov edi, 0xa
jmp 0x1400bfd0f
cmp dword [rbx + 0x64], 0
je 0x1400c0149
cmp dword [rbx + 0x60], 5
jne 0x1400c0149
mov r11d, reloc.WS2_32.dll_inet_addr
mov edi, r11d
jmp case.default.0x1400bfce0
mov edi, 7
jmp 0x1400bfd0f
movzx edx, word [rbx + 0x60]
mov rcx, rbx
call fcn.1400beb00
mov rcx, rbx
call fcn.1400bf0d0
cmp eax, 0xfffffc5e
jne 0x1400c0178
mov edi, 0xa
jmp 0x1400bfd0f
cmp dword [rbx + 0x64], 0
je 0x1400c0192
cmp dword [rbx + 0x60], 5
jne 0x1400c0192
mov r11d, reloc.WS2_32.dll_inet_addr
mov edi, r11d
jmp case.default.0x1400bfce0
mov r11d, reloc.WS2_32.dll_inet_addr
test r15w, r15w
jle 0x1400c01ab
lea edi, [r11 - 5]
dec r15w
jmp case.default.0x1400bfce0
mov edi, 7
jmp case.default.0x1400bfce0
movzx edx, word [rbx + 0x60]
mov rcx, rbx
call fcn.1400beb00
movzx eax, byte [rbx + 0xe4]
cmp al, 1
jne 0x1400c01d6
mov rax, qword [rbx + 0x28]
cmp dword [rax + 0x40], 0
jmp 0x1400c01f6
cmp al, 2
jne 0x1400c01e7
mov rax, qword [rbx + 0x28]
cmp dword [rax + 0x40], 0xf0b8
jmp 0x1400c01f6
cmp al, 3
jne 0x1400c0206
mov rax, qword [rbx + 0x28]
cmp dword [rax + 0x40], 0xdebb20e3
jne 0x1400c01ff
mov edi, 9
jmp 0x1400c0206
mov dword [rax + 0x4c], 0xfffffc6a
mov rax, qword [rbx + 0x28]
cmp dword [rax + 0x4c], 0xfffffc6a
jne 0x1400bfd0f
mov edi, 0xa
lea rdx, str.WaitForAck_:_Bad_CRC
jmp 0x1400bfd07
mov eax, dword [rbx + 0x60]
cmp dword [r8 + 0x40], eax
jne 0x1400c023b
mov edi, 9
jmp case.default.0x1400bfce0
mov dword [r8 + 0x4c], 0xfffffc6a
lea rdx, str.WaitForAck_:_Bad_checksum
mov edi, 0xa
jmp 0x1400bfd07
mov r10d, dword [r8 + 0x38]
mov eax, 0x66666667
movsx r9d, r12w
lea ecx, [r10 + 1]
imul ecx
sar edx, 2
mov eax, edx
shr eax, 0x1f
add edx, eax
lea eax, [rdx + rdx*4]
add eax, eax
sub ecx, eax
cmp r9d, ecx
je 0x1400c03c0
mov rax, qword [rbx + 0x38]
cmp byte [rax], 0x46
je 0x1400c03c0
cmp r9d, r10d
jne 0x1400c029b
mov edi, r11d
jmp case.default.0x1400bfce0
mov dword [r8 + 0x4c], 0xfffffc5a
mov edi, 0xa
jmp case.default.0x1400bfce0
inc dword [r8 + 0x50]
mov dl, reloc.WS2_32.dll_setsockopt
mov rcx, rbx
call fcn.1400c0450
mov edi, ebp
jmp 0x1400bfd0f
mov dl, reloc.OLEAUT32.dll_SafeArrayGetDim
mov rcx, rbx
call fcn.1400c0450
mov rax, qword [rbx + 0x28]
mov rcx, rbx
movzx edx, byte [rax + 0x38]
add dl, 0x30
call fcn.1400c0450
lea rdx, str.SendAck_:_Sent_ACK
mov rcx, rbx
call fcn.1400c13a0
mov edi, ebp
jmp 0x1400bfd0f
cmp dword [rbx + 0xc0], 0
jle 0x1400c02a3
mov dl, 5
mov dword [rbx + 0xcc], 1
mov rcx, rbx
call fcn.1400c0450
mov dl, 5
mov rcx, rbx
call fcn.1400c0450
mov rax, qword [rbx + 0x28]
mov edi, ebp
inc dword [rax + 0x50]
mov dword [rbx + 0xd0], 0xffffffff
jmp 0x1400bfd0f
cmp dword [rsp + 0x80], 0
je 0x1400c0401
cmp dword [rbx + 0xc0], 0
movzx r14d, bp
jle 0x1400c03a8
mov ecx, ebp
add ecx, dword [rbx + 0xc4]
mov eax, 0x66666667
imul ecx
sar edx, 1
mov eax, edx
shr eax, 0x1f
add edx, eax
lea eax, [rdx + rdx*4]
sub ecx, eax
movsx r8, cx
mov rcx, rbx
mov rax, r8
add r8, 7
add rax, rax
add r8, r8
mov r8d, dword [rbx + r8*8]
mov r9, qword [rbx + rax*8 + 0x78]
mov edx, dword [rbx + rax*8 + 0x74]
call fcn.1400bf9d0
inc r14w
movsx ecx, r14w
cmp ecx, dword [rbx + 0xc0]
jl 0x1400c0351
mov r11d, reloc.WS2_32.dll_inet_addr
mov edi, ebp
jmp case.default.0x1400bfce0
mov eax, 0xfffffc5e
jmp 0x1400bfd2d
xor eax, eax
jmp 0x1400bfd2d
inc dword [rbx + 0x68]
mov dword [r8 + 0x38], r9d
test r13d, r13d
je 0x1400c03d4
mov rcx, rbx
call fcn.1400bf660
movsx eax, r14w
lea rdx, str.WaitForAck_:_Received_packet
mov dword [rbx + 0x58], eax
mov rcx, rbx
mov rax, qword [rbx + 0x28]
mov dword [rax + 0x4c], 0xfffffc59
call fcn.1400c13a0
mov rax, qword [rbx + 0x28]
mov eax, dword [rax + 0x4c]
jmp 0x1400bfd2d
mov eax, dword [r8 + 0x4c]
jmp 0x1400bfd2d