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

Disassembly:
push rbp
push rdi
push r13
push r15
mov rbp, rsp
sub rsp, 0x28
mov r13, r8
mov r15, rdx
mov rdi, rcx
test r9d, r9d
je 0x14016de10
mov dword [0x14027c874], 0x76c
mov dword [0x14027c878], 0xffffffff
movzx edx, byte [rdx]
mov qword [rsp + 0x58], rbx
movzx eax, dl
mov qword [rsp + 0x60], rsi
mov qword [rsp + 0x68], r12
mov qword [rsp + 0x20], r14
mov qword [rbp + 0x28], rcx
test dl, dl
je 0x14016e939
lea r12, [0x140000000]
nop dword [rax]
movzx eax, al
xor r8d, r8d
test byte [r12 + rax*2 + 0x231a30], 0x20
je 0x14016de7e
movzx eax, byte [rdi]
test byte [r12 + rax*2 + 0x231a30], 0x20
je 0x14016de76
nop
movzx eax, byte [rdi + 1]
inc rdi
test byte [r12 + rax*2 + 0x231a30], 0x20
jne 0x14016de60
mov qword [rbp + 0x28], rdi
inc r15
jmp 0x14016e92a
inc r15
cmp dl, 0x25
jne case.0x14016deb9.37
nop word [rax + rax]
movzx edx, byte [r15]
inc r15
lea eax, [rdx - 0x25]
cmp eax, 0x55
ja case.0x14016deb9.72
cdqe
movzx eax, byte [r12 + rax + 0x16ea34]
mov ecx, dword [r12 + rax*4 + 0x16e9a4]
add rcx, r12
jmp rcx
test r8d, r8d
jne case.0x14016deb9.72
mov r8d, 1
jmp 0x14016de90
test r8d, r8d
jne case.0x14016deb9.72
mov r8d, 2
jmp 0x14016de90
test r8d, 0xfffffffe
jne case.0x14016deb9.72
mov rdx, qword [0x1402748a0]
mov rdx, qword [rdx + 0x140]
jmp 0x14016df08
test r8d, r8d
jne case.0x14016deb9.72
lea rdx, str._m__d__y
jmp 0x14016df08
test r8d, r8d
jne case.0x14016deb9.72
lea rdx, str._Y__m__d
mov r8, r13
xor r9d, r9d
mov rcx, rdi
call 0x14016dde0
mov qword [rbp + 0x28], rax
mov rdi, rax
test rax, rax
jne 0x14016e92a
xor eax, eax
jmp 0x14016e983
test r8d, r8d
jne case.0x14016deb9.72
lea rdx, str._H:_M
jmp 0x14016df08
test r8d, r8d
jne case.0x14016deb9.72
lea rdx, str._I:_M:_S__p
jmp 0x14016df08
test r8d, r8d
jne case.0x14016deb9.72
lea rdx, str._H:_M:_S
jmp 0x14016df08
test r8d, 0xfffffffe
jne case.0x14016deb9.72
mov rdx, qword [0x1402748a0]
mov rdx, qword [rdx + 0x150]
jmp 0x14016df08
test r8d, 0xfffffffe
jne case.0x14016deb9.72
mov rdx, qword [0x1402748a0]
mov rdx, qword [rdx + 0x148]
jmp 0x14016df08
test r8d, r8d
jne case.0x14016deb9.72
xor r14d, r14d
xor esi, esi
nop word [rax + rax]
mov rax, qword [0x1402748a0]
or rbx, 0xffffffffffffffff
mov rcx, qword [rsi + rax + 0x38]
inc rbx
cmp byte [rcx + rbx], 0
jne 0x14016dfb0
mov r8d, ebx
mov rdx, rdi
call fcn.1401721f0
test eax, eax
je 0x14016dffc
mov rax, qword [0x1402748a0]
or rbx, 0xffffffffffffffff
mov rcx, qword [rsi + rax]
inc rbx
cmp byte [rcx + rbx], 0
jne 0x14016dfd7
mov r8d, ebx
mov rdx, rdi
call fcn.1401721f0
test eax, eax
je 0x14016dffc
inc r14d
add rsi, 8
cmp rsi, 0x38
jl 0x14016dfa0
cmp r14d, 7
je case.0x14016deb9.72
add rdi, rbx
mov dword [r13 + 0x18], r14d
mov qword [rbp + 0x28], rdi
jmp 0x14016e92a
test r8d, r8d
jne case.0x14016deb9.72
xor r14d, r14d
mov esi, reloc.WS2_32.dll_WSASetLastError
nop word [rax + rax]
mov rax, qword [0x1402748a0]
or rbx, 0xffffffffffffffff
mov rcx, qword [rsi + rax + 0x60]
inc rbx
cmp byte [rcx + rbx], 0
jne 0x14016e040
mov r8d, ebx
mov rdx, rdi
call fcn.1401721f0
test eax, eax
je 0x14016e08f
mov rax, qword [0x1402748a0]
or rbx, 0xffffffffffffffff
mov rcx, qword [rsi + rax]
inc rbx
cmp byte [rcx + rbx], 0
jne 0x14016e067
mov r8d, ebx
mov rdx, rdi
call fcn.1401721f0
test eax, eax
je 0x14016e08f
inc r14d
add rsi, 8
cmp rsi, 0xd0
jl 0x14016e030
cmp r14d, 0xc
je case.0x14016deb9.72
add rdi, rbx
mov dword [r13 + 0x10], r14d
mov qword [rbp + 0x28], rdi
jmp 0x14016e92a
test r8d, 0xfffffffe
jne case.0x14016deb9.72
movzx ecx, byte [rdi]
mov r8d, 0x63
lea eax, [rcx - 0x30]
cmp al, 9
ja case.0x14016deb9.72
xor edx, edx
nop dword [rax]
movzx r9d, cl
mov eax, 0x66666667
add r9d, edx
inc rdi
imul r8d
lea r10d, [r9 - 0x30]
mov r8d, edx
sar r8d, 2
mov eax, r8d
shr eax, 0x1f
add r8d, eax
lea eax, [r9 - 0x30]
lea edx, [rax + rax*4]
add edx, edx
cmp edx, 0x63
jg 0x14016e116
test r8d, r8d
je 0x14016e116
movzx ecx, byte [rdi]
cmp cl, 0x30
jb 0x14016e116
cmp cl, 0x39
jbe 0x14016e0d0
mov qword [rbp + 0x28], rdi
cmp r10d, 0x63
ja case.0x14016deb9.72
lea eax, [r9 - 0x30]
imul ecx, eax, 0x64
mov dword [0x14027c874], ecx
jmp 0x14016e92a
test r8d, 0xfffffffd
jne case.0x14016deb9.72
lea rdx, [r13 + 0xc]
mov r9d, 0x1f
mov r8d, 1
lea rcx, [rbp + 0x28]
call fcn.14016dd20
test eax, eax
je case.0x14016deb9.72
mov rdi, qword [rbp + 0x28]
jmp 0x14016e92a
test r8d, r8d
jne case.0x14016deb9.72
test r8d, 0xfffffffd
jne case.0x14016deb9.72
lea rdx, [r13 + 8]
mov r9d, reloc.WS2_32.dll_socket
xor r8d, r8d
jmp 0x14016e153
test r8d, r8d
jne case.0x14016deb9.72
test r8d, 0xfffffffd
jne case.0x14016deb9.72
lea rdx, [r13 + 8]
mov r9d, listen
jmp 0x14016e14d
test r8d, r8d
jne case.0x14016deb9.72
mov r9d, 0x16e
lea rdx, [r13 + 0x1c]
mov r8d, 1
lea rcx, [rbp + 0x28]
call fcn.14016dd20
test eax, eax
je case.0x14016deb9.72
dec dword [r13 + 0x1c]
mov rdi, qword [rbp + 0x28]
jmp 0x14016e92a
test r8d, 0xfffffffd
jne case.0x14016deb9.72
lea rdx, [r13 + 4]
mov r9d, 0x3b
xor r8d, r8d
jmp 0x14016e153
test r8d, 0xfffffffd
jne case.0x14016deb9.72
mov r9d, listen
lea rdx, [r13 + 0x10]
lea rcx, [rbp + 0x28]
lea r8d, [r9 - 0xb]
call fcn.14016dd20
test eax, eax
je case.0x14016deb9.72
dec dword [r13 + 0x10]
mov rdi, qword [rbp + 0x28]
jmp 0x14016e92a
test r8d, r8d
jne case.0x14016deb9.72
mov rax, qword [0x1402748a0]
or rbx, 0xffffffffffffffff
mov rcx, qword [rax + 0x130]
nop
inc rbx
cmp byte [rcx + rbx], 0
jne 0x14016e260
mov r8d, ebx
mov rdx, rdi
call fcn.1401721f0
test eax, eax
jne 0x14016e29b
mov eax, dword [r13 + 8]
cmp eax, 0xc
jg case.0x14016deb9.72
jne 0x14016e28f
mov dword [r13 + 8], 0
add rdi, rbx
mov qword [rbp + 0x28], rdi
jmp 0x14016e92a
mov rax, qword [0x1402748a0]
or rbx, 0xffffffffffffffff
mov rcx, qword [rax + 0x138]
nop dword [rax]
inc rbx
cmp byte [rcx + rbx], 0
jne 0x14016e2b0
mov r8d, ebx
mov rdx, rdi
call fcn.1401721f0
test eax, eax
jne case.0x14016deb9.72
mov eax, dword [r13 + 8]
cmp eax, 0xc
jg case.0x14016deb9.72
jge 0x14016e2e2
add eax, 0xc
mov dword [r13 + 8], eax
add rdi, rbx
mov qword [rbp + 0x28], rdi
jmp 0x14016e92a
test r8d, 0xfffffffd
jne case.0x14016deb9.72
mov r9d, 0x3d
xor r8d, r8d
mov rdx, r13
jmp 0x14016e153
test r8d, 0xfffffffd
jne case.0x14016deb9.72
movzx ecx, byte [rdi]
mov r8d, 0x35
lea eax, [rcx - 0x30]
cmp al, 9
ja case.0x14016deb9.72
xor edx, edx
nop
movzx ecx, cl
mov eax, 0x66666667
add ecx, edx
inc rdi
imul r8d
lea r9d, [rcx - 0x30]
mov r8d, edx
sar r8d, 2
mov eax, r8d
shr eax, 0x1f
add r8d, eax
lea eax, [rcx - 0x30]
lea edx, [rax + rax*4]
add edx, edx
cmp edx, 0x35
jg 0x14016e373
test r8d, r8d
je 0x14016e373
movzx ecx, byte [rdi]
cmp cl, 0x30
jb 0x14016e373
cmp cl, 0x39
jbe 0x14016e330
mov qword [rbp + 0x28], rdi
cmp r9d, 0x35
ja case.0x14016deb9.72
jmp 0x14016e92a
test r8d, 0xfffffffd
jne case.0x14016deb9.72
lea rdx, [r13 + 0x18]
mov r9d, 6
xor r8d, r8d
jmp 0x14016e153
test r8d, 0xfffffffd
jne case.0x14016deb9.72
movzx ecx, byte [rdi]
mov r8d, 7
lea eax, [rcx - 0x30]
cmp al, 9
ja case.0x14016deb9.72
xor edx, edx
nop dword [rax + rax]
lea r9d, [rdx - 0x30]
movzx eax, cl
add r9d, eax
inc rdi
mov eax, 0x66666667
imul r8d
mov r8d, edx
lea edx, [r9 + r9*4]
sar r8d, 2
add edx, edx
mov eax, r8d
shr eax, 0x1f
add r8d, eax
cmp edx, 7
jg 0x14016e412
test r8d, r8d
je 0x14016e412
movzx ecx, byte [rdi]
cmp cl, 0x30
jb 0x14016e412
cmp cl, 0x39
jbe 0x14016e3d0
lea eax, [r9 - 1]
mov qword [rbp + 0x28], rdi
cmp eax, 6
ja case.0x14016deb9.72
mov eax, 0x92492493
imul r9d
add edx, r9d
sar edx, 2
mov eax, edx
shr eax, 0x1f
add edx, eax
imul eax, edx, 7
sub r9d, eax
mov dword [r13 + 0x18], r9d
jmp 0x14016e92a
movzx ecx, byte [rdi]
mov r8d, 0x63
lea eax, [rcx - 0x30]
cmp al, 9
ja case.0x14016deb9.72
xor edx, edx
nop dword [rax]
movzx ecx, cl
mov eax, 0x66666667
add ecx, edx
inc rdi
imul r8d
lea r9d, [rcx - 0x30]
mov r8d, edx
sar r8d, 2
mov eax, r8d
shr eax, 0x1f
add r8d, eax
lea eax, [rcx - 0x30]
lea edx, [rax + rax*4]
add edx, edx
cmp edx, 0x63
jg 0x14016e4a3
test r8d, r8d
je 0x14016e4a3
movzx ecx, byte [rdi]
cmp cl, 0x30
jb 0x14016e4a3
cmp cl, 0x39
jbe 0x14016e460
mov qword [rbp + 0x28], rdi
cmp r9d, 0x63
ja case.0x14016deb9.72
jmp 0x14016e92a
movzx eax, byte [rdi + 1]
inc rdi
test byte [r12 + rax*2 + 0x231a30], 8
jne case.0x14016deb9.44
mov qword [rbp + 0x28], rdi
jmp 0x14016e92a
movzx ecx, byte [rdi]
mov r8d, 0x35
lea eax, [rcx - 0x30]
cmp al, 9
ja case.0x14016deb9.72
xor edx, edx
nop dword [rax]
nop word [rax + rax]
movzx ecx, cl
mov eax, 0x66666667
add ecx, edx
inc rdi
imul r8d
lea r9d, [rcx - 0x30]
mov r8d, edx
sar r8d, 2
mov eax, r8d
shr eax, 0x1f
add r8d, eax
lea eax, [rcx - 0x30]
lea edx, [rax + rax*4]
add edx, edx
cmp edx, 0x35
jg 0x14016e543
test r8d, r8d
je 0x14016e543
movzx ecx, byte [rdi]
cmp cl, 0x30
jb 0x14016e543
cmp cl, 0x39
jbe 0x14016e500
mov qword [rbp + 0x28], rdi
cmp r9d, 0x35
ja case.0x14016deb9.72
jmp 0x14016e92a
test r8d, 0xfffffffe
jne case.0x14016deb9.72
movzx ecx, byte [rdi]
mov r8d, 0x270f
lea eax, [rcx - 0x30]
cmp al, 9
ja case.0x14016deb9.72
xor edx, edx
nop dword [rax]
movzx r9d, cl
mov eax, 0x66666667
add r9d, edx
inc rdi
imul r8d
lea r10d, [r9 - 0x30]
mov r8d, edx
sar r8d, 2
mov eax, r8d
shr eax, 0x1f
add r8d, eax
lea eax, [r9 - 0x30]
lea edx, [rax + rax*4]
add edx, edx
cmp edx, 0x270f
jg 0x14016e5c9
test r8d, r8d
je 0x14016e5c9
movzx ecx, byte [rdi]
cmp cl, 0x30
jb 0x14016e5c9
cmp cl, 0x39
jbe 0x14016e580
mov qword [rbp + 0x28], rdi
cmp r10d, 0x270f
ja case.0x14016deb9.72
lea eax, [r9 - 0x79c]
mov dword [0x14027c878], 0xffffffff
mov dword [r13 + 0x14], eax
jmp 0x14016e92a
movzx ecx, byte [rdi]
mov r8d, 0x63
lea eax, [rcx - 0x30]
cmp al, 9
ja case.0x14016deb9.72
xor edx, edx
nop word [rax + rax]
lea r9d, [rdx - 0x30]
movzx eax, cl
add r9d, eax
inc rdi
mov eax, 0x66666667
imul r8d
mov r8d, edx
lea edx, [r9 + r9*4]
sar r8d, 2
add edx, edx
mov eax, r8d
shr eax, 0x1f
add r8d, eax
cmp edx, 0x63
jg 0x14016e652
test r8d, r8d
je 0x14016e652
movzx ecx, byte [rdi]
cmp cl, 0x30
jb 0x14016e652
cmp cl, 0x39
jbe 0x14016e610
mov qword [rbp + 0x28], rdi
cmp r9d, 0x63
ja case.0x14016deb9.72
mov dword [0x14027c878], r9d
jmp 0x14016e92a
call fcn.140171eb0
mov r8d, 3
lea rdx, [0x1402746e0]
mov rcx, rdi
call fcn.14017dd80
test eax, eax
jne 0x14016e69b
add rdi, 3
mov dword [r13 + 0x20], eax
mov qword [rbp + 0x28], rdi
jmp 0x14016e92a
call fcn.140188730
mov rsi, rax
test rax, rax
je 0x14016e6dc
xor r14d, r14d
nop dword [rax + rax]
mov rcx, qword [rsi]
or rbx, 0xffffffffffffffff
inc rbx
cmp byte [rcx + rbx], 0
jne 0x14016e6b7
mov r8d, ebx
mov rdx, rdi
call fcn.1401721f0
test eax, eax
je 0x14016e6e7
inc r14d
add rsi, 8
cmp r14d, 2
jl 0x14016e6b0
xor edi, edi
mov qword [rbp + 0x28], rdi
jmp 0x14016e92a
mov eax, ebx
add rax, rdi
mov rdi, rax
je 0x14016e6de
mov dword [r13 + 0x20], r14d
mov qword [rbp + 0x28], rax
jmp 0x14016e92a
movzx eax, byte [rdi]
test byte [r12 + rax*2 + 0x231a30], 0x20
je 0x14016e722
nop dword [rax]
movzx eax, byte [rdi + 1]
inc rdi
test byte [r12 + rax*2 + 0x231a30], 0x20
jne 0x14016e710
movzx ecx, byte [rdi]
inc rdi
mov qword [rbp + 0x28], rdi
lea eax, [rcx - 0x2b]
test al, 0xfd
je 0x14016e85d
cmp cl, 0x47
je 0x14016e82c
mov rdx, rdi
cmp cl, 0x55
je 0x14016e83d
cmp cl, 0x5a
je 0x14016e850
dec rdi
lea rsi, [0x1402746e8]
xor r14d, r14d
nop dword [rax]
nop word [rax + rax]
mov rcx, qword [rsi]
or rbx, 0xffffffffffffffff
inc rbx
cmp byte [rcx + rbx], 0
jne 0x14016e777
mov r8d, ebx
mov rdx, rdi
call fcn.1401721f0
test eax, eax
je 0x14016e7fe
inc r14d
add rsi, 8
cmp r14d, 4
jl 0x14016e770
lea rsi, [0x140274710]
xor r14d, r14d
nop word [rax + rax]
mov rcx, qword [rsi]
or rbx, 0xffffffffffffffff
inc rbx
cmp byte [rcx + rbx], 0
jne 0x14016e7b7
mov r8d, ebx
mov rdx, rdi
call fcn.1401721f0
test eax, eax
je 0x14016e811
inc r14d
add rsi, 8
cmp r14d, 4
jl 0x14016e7b0
movzx ecx, byte [rdi]
lea eax, [rcx - 0x41]
cmp al, 8
jbe 0x14016e7f2
sub cl, 0x4c
cmp cl, 0xd
ja case.0x14016deb9.72
inc rdi
mov qword [rbp + 0x28], rdi
jmp 0x14016e92a
mov eax, ebx
add rax, rdi
je 0x14016e79c
mov rdi, rax
mov qword [rbp + 0x28], rax
jmp 0x14016e92a
mov eax, ebx
add rax, rdi
je 0x14016e7dc
mov dword [r13 + 0x20], 1
mov rdi, rax
mov qword [rbp + 0x28], rax
jmp 0x14016e92a
movzx eax, byte [rdi]
inc rdi
mov rdx, rdi
cmp al, 0x4d
jne case.0x14016deb9.72
movzx eax, byte [rdi]
lea rdi, [rdx + 1]
mov qword [rbp + 0x28], rdi
cmp al, 0x54
jne case.0x14016deb9.72
mov dword [r13 + 0x20], 0
jmp 0x14016e92a
xor ecx, ecx
mov r8, rdi
xor edx, edx
nop dword [rax]
nop dword [rax + rax]
movzx eax, byte [rdi]
test byte [r12 + rax*2 + 0x231a30], 8
je 0x14016e88b
lea ecx, [rcx + rcx*4]
inc edx
lea ecx, [rcx - 0x18]
lea ecx, [rax + rcx*2]
jmp 0x14016e894
cmp edx, 2
jne 0x14016e8a9
cmp al, 0x3a
jne 0x14016e850
lea rdi, [r8 + 1]
mov qword [rbp + 0x28], rdi
mov r8, rdi
cmp edx, 4
jl 0x14016e870
cmp edx, 2
je 0x14016e850
cmp edx, 4
jne case.0x14016deb9.72
mov eax, 0x51eb851f
imul ecx
sar edx, 5
mov eax, edx
shr eax, 0x1f
add edx, eax
imul eax, edx, 0x64
sub ecx, eax
cmp ecx, 0x3c
jge case.0x14016deb9.72
mov dword [r13 + 0x20], 0
jmp 0x14016e92a
test r8d, r8d
jne case.0x14016deb9.72
movzx eax, byte [rdi]
test byte [r12 + rax*2 + 0x231a30], 0x20
je 0x14016e92a
nop dword [rax]
nop word [rax + rax]
movzx eax, byte [rdi + 1]
inc rdi
test byte [r12 + rax*2 + 0x231a30], 0x20
jne 0x14016e900
mov qword [rbp + 0x28], rdi
jmp 0x14016e92a
movzx eax, byte [rdi]
inc rdi
mov qword [rbp + 0x28], rdi
cmp dl, al
jne case.0x14016deb9.72
movzx edx, byte [r15]
movzx eax, dl
test dl, dl
jne 0x14016de40
mov eax, dword [0x14027c878]
cmp eax, 0xffffffff
je 0x14016e980
cmp dword [0x14027c874], 0x76c
jne 0x14016e96a
cmp eax, 0x44
jg 0x14016e95e
add eax, 0x64
mov dword [r13 + 0x14], eax
jmp 0x14016e980
mov eax, dword [0x14027c878]
mov dword [r13 + 0x14], eax
jmp 0x14016e980
mov ecx, dword [0x14027c874]
add ecx, 0xfffff894
add ecx, dword [0x14027c878]
mov dword [r13 + 0x14], ecx
mov rax, rdi
mov r14, qword [rsp + 0x20]
mov r12, qword [rsp + 0x68]
mov rsi, qword [rsp + 0x60]
mov rbx, qword [rsp + 0x58]
add rsp, 0x28
pop r15
pop r13
pop rdi
pop rbp
ret
mov r9d, 1
jmp 0x14016dde0