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

Disassembly:
push r15
push r14
push r13
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x58
mov rbx, rcx
mov rsi, rdx
mov r13, r8
test rcx, rcx
je 0x40b14f
mov rdx, qword [rcx]
cmp r8, rdx
jge 0x40af65
jb 0x40aef6
dec rdx
mov rcx, r13
call sym.raiseIndexError2
cmp byte [rbx + r13 + 0x10], 0x2b
je 0x40af13
mov rdx, qword [rbx]
cmp r13, rdx
jb 0x40af35
dec rdx
mov rcx, r13
call sym.raiseIndexError2
jmp 0x40af35
lea r8, [rsp + 0x48]
mov edx, 1
mov rcx, r13
call sym.nimAddInt_3
test al, al
je 0x40af2e
call sym.raiseOverflow
mov r12, qword [rsp + 0x48]
jmp 0x40af68
cmp byte [rbx + r13 + 0x10], 0x2d
jne 0x40af65
lea r8, [rsp + 0x48]
mov edx, 1
mov rcx, r13
call sym.nimAddInt_3
test al, al
je 0x40af58
call sym.raiseOverflow
mov r12, qword [rsp + 0x48]
mov r14d, 1
jmp 0x40af6c
mov r12, r13
or r14, 0xffffffffffffffff
mov rdx, qword [rbx]
cmp rdx, r12
jle 0x40b123
cmp r12, rdx
jb 0x40af88
dec rdx
mov rcx, r12
call sym.raiseIndexError2
mov al, byte [rbx + r12 + 0x10]
sub eax, 0x30
cmp al, 9
ja 0x40b123
lea rax, [rsp + 0x30]
mov qword [rsi], 0
lea rbp, [rsp + 0x38]
mov qword [rsp + 0x28], rax
mov rdx, qword [rbx]
cmp r12, rdx
jl 0x40afc8
mov rcx, qword [rsi]
cmp r14, 0xffffffffffffffff
jne 0x40b106
jmp 0x40b0f8
jb 0x40afd5
dec rdx
mov rcx, r12
call sym.raiseIndexError2
mov al, byte [rbx + r12 + 0x10]
sub eax, 0x30
cmp al, 9
ja 0x40afb6
mov rdx, qword [rbx]
cmp r12, rdx
jb 0x40aff4
dec rdx
mov rcx, r12
call sym.raiseIndexError2
movzx ecx, byte [rbx + r12 + 0x10]
mov r8, qword [rsp + 0x28]
mov edx, 0x30
call sym.nimSubInt_4
test al, al
je 0x40b012
call sym.raiseOverflow
mov r15, qword [rsp + 0x30]
mov ecx, 1
mov r8, rbp
shl rcx, 0x3f
mov rdx, r15
call sym.nimAddInt_3
test al, al
je 0x40b034
call sym.raiseOverflow
mov rax, qword [rsp + 0x38]
mov edi, 0xa
mov rcx, qword [rsi]
cqo
idiv rdi
lea rdi, [rsp + 0x40]
cmp rcx, rax
jge 0x40b057
call sym.integerOutOfRangeError__pureZparseutils_248
jmp 0x40b090
mov r8, rdi
mov edx, 0xa
call sym.nimMulInt
test al, al
je 0x40b06d
call sym.raiseOverflow
mov rcx, qword [rsp + 0x40]
lea r8, [rsp + 0x48]
mov rdx, r15
call sym.nimSubInt_4
test al, al
je 0x40b088
call sym.raiseOverflow
mov rax, qword [rsp + 0x48]
mov qword [rsi], rax
mov r8, rdi
mov edx, 1
mov rcx, r12
call sym.nimAddInt_3
test al, al
je 0x40b0a9
call sym.raiseOverflow
mov r12, qword [rsp + 0x40]
lea rdi, [rsp + 0x48]
mov rdx, qword [rbx]
cmp r12, rdx
jge 0x40afae
jb 0x40b0cc
dec rdx
mov rcx, r12
call sym.raiseIndexError2
cmp byte [rbx + r12 + 0x10], 0x5f
jne 0x40afae
mov r8, rdi
mov edx, 1
mov rcx, r12
call sym.nimAddInt_3
test al, al
je 0x40b0f1
call sym.raiseOverflow
mov r12, qword [rsp + 0x48]
jmp 0x40b0b3
mov eax, 1
shl rax, 0x3f
cmp rcx, rax
je 0x40b11e
lea r8, [rsp + 0x40]
mov rdx, r14
call sym.nimMulInt
test al, al
je 0x40b127
call sym.raiseOverflow
jmp 0x40b127
call sym.integerOutOfRangeError__pureZparseutils_248
xor eax, eax
jmp 0x40b15e
mov rax, qword [rsp + 0x40]
lea r8, [rsp + 0x48]
mov rdx, r13
mov rcx, r12
mov qword [rsi], rax
call sym.nimSubInt_4
test al, al
je 0x40b148
call sym.raiseOverflow
mov rax, qword [rsp + 0x48]
jmp 0x40b15e
or rdx, 0xffffffffffffffff
test r8, r8
js 0x40aeee
jmp 0x40b123
add rsp, 0x58
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
pop r14
pop r15
ret