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

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x40
push esi
push edi
mov edi, dword [ebp + 8]
mov edx, ecx
xorps xmm0, xmm0
mov dword [esp + 0x20], edx
movsd qword [esp + 0x40], xmm0
movsd qword [esp + 0x38], xmm0
mov eax, dword [edi + 0x18]
mov ecx, eax
sub ecx, dword [edi + 0xc]
sar ecx, 1
add ecx, dword [edi + 0x20]
cmp word [eax], 0x2d
mov dword [esp + 0x24], ecx
jne 0x42945c
mov ecx, edi
call fcn.004277f0
mov edx, dword [esp + 0x20]
mov byte [esp + 0xa], 1
jmp 0x429461
mov byte [esp + 0xa], 0
mov eax, dword [edi + 0x18]
xorps xmm0, xmm0
movlpd qword [esp + 0x28], xmm0
mov byte [esp + 9], 0
mov dword [esp + 0x18], 0
movzx ecx, word [eax]
mov esi, ecx
cmp ecx, 0x30
jne 0x4294ab
xor esi, esi
mov ecx, edi
mov dword [esp + 0x1c], esi
call fcn.004277f0
mov eax, dword [esp + 0x2c]
mov dword [esp + 0xc], eax
mov eax, dword [esp + 0x28]
mov byte [esp + 8], 0
mov dword [esp + 0x10], eax
jmp 0x429796
cmp ecx, 0x31
jb 0x429d93
cmp ecx, 0x39
ja 0x429d93
mov ecx, edi
call fcn.004277f0
cmp byte [esp + 0xa], 0
lea ecx, [esi - 0x30]
mov eax, dword [edi + 0x18]
mov dword [esp + 0x1c], ecx
movzx edx, word [eax]
mov esi, edx
je 0x42958e
mov dword [esp + 0x14], esi
mov esi, eax
cmp edx, 0x30
jb 0x429573
movzx edx, dx
mov dword [esp + 0x10], edx
mov edx, dword [esp + 0x14]
cmp dx, 0x39
ja 0x429573
movzx edx, dx
mov esi, eax
cmp ecx, 0xccccccc
jb 0x429513
jne 0x429559
cmp dx, 0x38
ja 0x429559
mov ecx, edi
call fcn.004277f0
mov esi, dword [esp + 0x1c]
mov eax, dword [esp + 0x10]
inc dword [esp + 0x18]
movzx eax, ax
lea ecx, [esi - 6]
lea ecx, [esi + ecx*4]
mov esi, dword [edi + 0x18]
lea ecx, [eax + ecx*2]
mov dword [esp + 0x1c], ecx
movzx eax, word [esi]
mov edx, eax
cmp eax, 0x30
jb 0x429573
mov dword [esp + 0x10], eax
mov edi, edx
mov dword [esp + 0x34], edi
mov eax, esi
mov edi, dword [ebp + 8]
cmp edx, 0x39
ja 0x429573
jmp 0x429501
mov dword [esp + 0xc], 0
mov edx, dword [esp + 0xc]
mov dword [esp + 0x10], ecx
mov byte [esp + 9], 1
jmp 0x429626
mov eax, dword [esp + 0x2c]
mov dword [esp + 0xc], eax
mov eax, dword [esp + 0x28]
mov ecx, eax
mov edx, dword [esp + 0xc]
mov dword [esp + 0x10], eax
jmp 0x429626
mov dword [esp + 0x14], esi
mov esi, eax
cmp edx, 0x30
jb 0x429616
mov edx, dword [esp + 0x14]
movzx edx, dx
mov dword [esp + 0x10], edx
mov edx, dword [esp + 0x14]
cmp dx, 0x39
ja 0x429616
movzx edx, dx
mov esi, eax
cmp ecx, 0x19999999
jb 0x4295c7
jne 0x42960d
cmp dx, 0x35
ja 0x42960d
mov ecx, edi
call fcn.004277f0
mov esi, dword [esp + 0x1c]
mov eax, dword [esp + 0x10]
inc dword [esp + 0x18]
movzx eax, ax
lea ecx, [esi - 6]
lea ecx, [esi + ecx*4]
mov esi, dword [edi + 0x18]
lea ecx, [eax + ecx*2]
mov dword [esp + 0x1c], ecx
movzx eax, word [esi]
mov edx, eax
cmp eax, 0x30
jb 0x429616
mov dword [esp + 0x10], eax
mov edi, edx
mov dword [esp + 0x34], edi
mov eax, esi
mov edi, dword [ebp + 8]
cmp edx, 0x39
ja 0x429616
jmp 0x4295b5
xor edx, edx
mov byte [esp + 9], 1
jmp 0x42961e
mov ecx, dword [esp + 0x28]
mov edx, dword [esp + 0x2c]
mov dword [esp + 0xc], edx
mov dword [esp + 0x10], ecx
cmp byte [esp + 9], 0
mov byte [esp + 8], 0
mov dword [esp + 0x14], esi
je 0x42973d
cmp byte [esp + 0xa], 0
movzx eax, word [esi]
mov dword [esp + 0x14], esi
je 0x429819
cmp word [esi], 0x30
mov dword [esp + 0x28], eax
jb 0x42973d
movzx eax, ax
mov dword [esp + 0x34], eax
mov eax, dword [esp + 0x28]
mov dword [esp + 0x14], esi
cmp ax, 0x39
ja 0x42973d
movzx eax, ax
mov dword [esp + 0x28], eax
nop word [eax + eax]
mov dword [esp + 0x14], esi
cmp edx, 0xccccccc
jb 0x4296ba
ja 0x429696
cmp ecx, 0xcccccccc
jb 0x4296ba
cmp ecx, 0xcccccccc
jne 0x429804
cmp edx, 0xccccccc
jne 0x429804
cmp word [esp + 0x28], 0x38
ja 0x429804
mov ecx, edi
call fcn.004277f0
mov eax, dword [esp + 0x34]
xor edx, edx
mov ecx, dword [esp + 0xc]
movzx esi, ax
mov eax, dword [esp + 0x10]
sub esi, 0x30
shld ecx, eax, 2
shl eax, 2
add dword [esp + 0x10], eax
mov eax, dword [esp + 0x10]
adc dword [esp + 0xc], ecx
mov ecx, dword [esp + 0xc]
shld ecx, eax, 1
add eax, eax
add esi, eax
adc edx, ecx
inc dword [esp + 0x18]
mov ecx, esi
mov dword [esp + 0xc], edx
mov esi, dword [edi + 0x18]
mov dword [esp + 0x10], ecx
mov dword [esp + 0x14], esi
movzx eax, word [esi]
mov edi, eax
mov dword [esp + 0x34], edi
mov edi, dword [ebp + 8]
cmp eax, 0x30
jb 0x42973d
movzx edi, ax
mov dword [esp + 0x34], edi
movzx edi, ax
mov dword [esp + 0x28], edi
mov edi, dword [ebp + 8]
cmp ax, 0x39
jbe 0x429680
mov eax, esi
mov dword [esp + 0x14], eax
mov esi, dword [esp + 0x14]
cmp byte [esp + 8], 0
je 0x429792
cmp word [esi], 0x30
jb 0x429792
movzx ecx, word [esi]
movzx eax, cx
mov esi, eax
cmp eax, 0x39
ja 0x429792
mov ecx, edi
call fcn.004277f0
movsd xmm1, qword [esp + 0x38]
lea eax, [esi - 0x30]
mulsd xmm1, qword [0x53cc88]
movd xmm0, eax
mov eax, dword [edi + 0x18]
cvtdq2pd xmm0, xmm0
movzx eax, word [eax]
mov ecx, eax
addsd xmm1, xmm0
movsd qword [esp + 0x38], xmm1
cmp eax, 0x30
jae 0x429751
mov esi, dword [esp + 0x1c]
mov edx, dword [edi + 0x18]
mov dword [esp + 0x14], 0
cmp word [edx], 0x2e
jne 0x4299a5
mov ecx, edi
call fcn.004277f0
mov edx, dword [edi + 0x18]
movzx eax, word [edx]
mov ecx, eax
mov dword [esp + 0x34], ecx
cmp eax, 0x30
jb 0x4299d9
cmp eax, 0x39
ja 0x4299d9
mov al, byte [esp + 8]
test al, al
jne 0x429929
cmp byte [esp + 9], al
je 0x429912
mov ecx, dword [esp + 0x10]
mov edx, dword [esp + 0xc]
call fcn.004fc9d0
mov edx, dword [edi + 0x18]
mov ecx, dword [esp + 0x34]
mov byte [esp + 8], 1
jmp 0x429933
call fcn.004fc9d0
movsd qword [esp + 0x38], xmm0
mov byte [esp + 8], 1
jmp 0x42973d
cmp word [esi], 0x30
mov dword [esp + 0x34], eax
jb 0x42973d
movzx eax, ax
mov dword [esp + 0x28], eax
mov eax, dword [esp + 0x34]
mov dword [esp + 0x14], esi
cmp ax, 0x39
ja 0x42973d
movzx eax, ax
cmp edx, 0x19999999
jb 0x429877
ja 0x429855
cmp ecx, 0x99999999
jb 0x429877
cmp ecx, 0x99999999
jne 0x4298fd
cmp edx, 0x19999999
jne 0x4298fd
cmp ax, 0x35
ja 0x4298fd
mov ecx, edi
call fcn.004277f0
mov eax, dword [esp + 0x28]
xor edx, edx
mov ecx, dword [esp + 0xc]
movzx esi, ax
mov eax, dword [esp + 0x10]
sub esi, 0x30
shld ecx, eax, 2
shl eax, 2
add dword [esp + 0x10], eax
mov eax, dword [esp + 0x10]
adc dword [esp + 0xc], ecx
mov ecx, dword [esp + 0xc]
shld ecx, eax, 1
add eax, eax
add esi, eax
adc edx, ecx
inc dword [esp + 0x18]
mov ecx, esi
mov dword [esp + 0xc], edx
mov esi, dword [edi + 0x18]
mov dword [esp + 0x10], ecx
movzx eax, word [esi]
mov edi, eax
mov dword [esp + 0x34], edi
mov edi, dword [ebp + 8]
cmp eax, 0x30
jb 0x429741
movzx edi, ax
mov dword [esp + 0x28], edi
movzx edi, ax
mov dword [esp + 0x34], edi
mov edi, dword [ebp + 8]
cmp ax, 0x39
ja 0x429792
mov eax, dword [esp + 0x34]
jmp 0x429843
call fcn.004fc9d0
movsd qword [esp + 0x38], xmm0
mov byte [esp + 8], 1
jmp 0x429748
mov ecx, esi
xor edx, edx
call fcn.004fc9d0
mov edx, dword [edi + 0x18]
mov ecx, dword [esp + 0x34]
mov byte [esp + 8], 1
jmp 0x429933
movsd xmm0, qword [esp + 0x38]
mov byte [esp + 8], al
movsd qword [esp + 0x38], xmm0
movzx ecx, cx
nop dword [eax]
movzx eax, cx
mov ecx, eax
mov dword [esp + 0x34], ecx
cmp eax, 0x39
ja 0x4299a5
mov ecx, edi
call fcn.004277f0
cmp dword [esp + 0x18], 0x11
jge 0x429998
mov ecx, dword [esp + 0x34]
movsd xmm1, qword [esp + 0x38]
mulsd xmm1, qword [0x53cc88]
dec dword [esp + 0x14]
movzx eax, cx
sub eax, 0x30
movd xmm0, eax
cvtdq2pd xmm0, xmm0
addsd xmm1, xmm0
comisd xmm1, xmmword [0x53cc60]
movsd qword [esp + 0x38], xmm1
jbe 0x429998
inc dword [esp + 0x18]
mov edx, dword [edi + 0x18]
movzx eax, word [edx]
mov ecx, eax
cmp eax, 0x30
jae 0x429940
movzx eax, word [edx]
xor ecx, ecx
mov edx, eax
cmp eax, 0x65
je 0x4299ba
cmp edx, 0x45
jne 0x429b25
mov ecx, edi
call fcn.004277f0
cmp byte [esp + 8], 0
jne 0x429a0b
cmp byte [esp + 9], 0
je 0x4299f7
mov ecx, dword [esp + 0x10]
mov edx, dword [esp + 0xc]
jmp 0x4299fb
sub edx, dword [edi + 0xc]
mov eax, dword [esp + 0x20]
sar edx, 1
add edx, dword [edi + 0x20]
mov dword [eax + 0x18], 0xe
mov dword [eax + 0x1c], edx
pop edi
pop esi
mov esp, ebp
pop ebp
ret 8
mov ecx, esi
xor edx, edx
call fcn.004fc9d0
movsd qword [esp + 0x38], xmm0
mov byte [esp + 8], 1
mov ecx, dword [edi + 0x18]
mov byte [esp + 0xb], 0
movzx eax, word [ecx]
mov edx, eax
cmp eax, 0x2b
jne 0x429a2c
mov ecx, edi
call fcn.004277f0
mov ecx, dword [edi + 0x18]
movzx eax, word [ecx]
jmp 0x429a47
cmp edx, 0x2d
jne 0x429a45
mov ecx, edi
call fcn.004277f0
mov ecx, dword [edi + 0x18]
mov byte [esp + 0xb], 1
movzx eax, word [ecx]
jmp 0x429a47
mov eax, edx
movzx eax, ax
mov dword [esp + 0x34], eax
add eax, 0xffffffd0
cmp ax, 9
ja 0x429be4
mov ecx, edi
call fcn.004277f0
mov eax, dword [esp + 0x34]
movzx ecx, ax
mov eax, dword [edi + 0x18]
sub ecx, 0x30
cmp byte [esp + 0xb], 0
mov dword [esp + 0x18], ecx
movzx edx, word [eax]
mov dword [esp + 0x34], edx
je 0x429b72
mov ecx, dword [esp + 0x14]
mov eax, 0x66666667
lea ecx, [ecx + 0x7ffffff7]
imul ecx
sar edx, 2
mov eax, edx
shr eax, 0x1f
add eax, edx
mov dword [esp + 0x28], eax
mov eax, dword [esp + 0x34]
movzx ecx, ax
cmp ax, 0x30
jb 0x429b1f
mov esi, dword [esp + 0x18]
movzx eax, cx
mov ecx, eax
mov dword [esp + 0x34], ecx
cmp eax, 0x39
ja 0x429b17
mov ecx, edi
call fcn.004277f0
mov eax, dword [esp + 0x34]
lea esi, [esi + esi*4]
movzx eax, ax
lea esi, [esi - 0x18]
lea esi, [eax + esi*2]
cmp esi, dword [esp + 0x28]
jle 0x429b0a
mov eax, dword [edi + 0x18]
movzx eax, word [eax]
mov ecx, eax
cmp eax, 0x30
jb 0x429b0a
nop dword [eax]
cmp cx, 0x39
ja 0x429b0a
mov ecx, edi
call fcn.004277f0
mov eax, dword [edi + 0x18]
movzx eax, word [eax]
mov ecx, eax
cmp eax, 0x30
jae 0x429af0
mov eax, dword [edi + 0x18]
movzx eax, word [eax]
mov ecx, eax
cmp eax, 0x30
jae 0x429ab5
mov dword [esp + 0x18], esi
mov esi, dword [esp + 0x1c]
mov ecx, dword [esp + 0x18]
neg ecx
cmp byte [esp + 8], 0
je 0x429ca9
mov eax, dword [esp + 0x14]
movsd xmm0, qword [esp + 0x38]
add eax, ecx
cmp eax, 0xfffffecc
jge 0x429c02
divsd xmm0, qword [0x53cce0]
add eax, 0x134
cmp eax, 0xfffffecc
jl 0x429c28
shl eax, 3
mov ecx, 0x533e80
sub ecx, eax
divsd xmm0, qword [ecx]
jmp 0x429c22
mov eax, 0x134
sub eax, dword [esp + 0x14]
mov dword [esp + 0x1c], eax
movzx eax, dx
mov dword [esp + 0x28], eax
cmp edx, 0x30
jb 0x429b25
cmp word [esp + 0x28], 0x39
movzx eax, ax
mov dword [esp + 0x34], eax
ja 0x429b25
nop word [eax + eax]
mov ecx, edi
call fcn.004277f0
mov eax, dword [esp + 0x18]
lea ecx, [eax + eax*4]
mov eax, dword [esp + 0x34]
movzx eax, ax
lea ecx, [ecx - 0x18]
lea ecx, [eax + ecx*2]
mov dword [esp + 0x18], ecx
cmp ecx, dword [esp + 0x1c]
jg 0x429c38
mov eax, dword [edi + 0x18]
movzx eax, word [eax]
mov edx, eax
cmp eax, 0x30
jb 0x429b25
mov dword [esp + 0x34], eax
cmp edx, 0x39
jbe 0x429ba0
jmp 0x429b25
sub ecx, dword [edi + 0xc]
mov eax, dword [esp + 0x20]
sar ecx, 1
add ecx, dword [edi + 0x20]
mov dword [eax + 0x18], 0xf
mov dword [eax + 0x1c], ecx
pop edi
pop esi
mov esp, ebp
pop ebp
ret 8
lea ecx, [eax*8]
test eax, eax
js 0x429c17
mulsd xmm0, qword [ecx + 0x533e80]
jmp 0x429c22
mov eax, 0x533e80
sub eax, ecx
divsd xmm0, qword [eax]
movsd qword [esp + 0x40], xmm0
movsd xmm0, qword [esp + 0x40]
comisd xmm0, xmmword [0x53cce8]
jbe 0x429c52
mov eax, dword [esp + 0x20]
mov ecx, dword [esp + 0x24]
mov dword [eax + 0x18], 0xd
mov dword [eax + 0x1c], ecx
pop edi
pop esi
mov esp, ebp
pop ebp
ret 8
cmp byte [esp + 0xa], 0
je 0x429c60
xorps xmm0, xmmword [0x53cd30]
mov ecx, dword [ebp + 0xc]
mov eax, dword [ecx + 0x28]
lea esi, [ecx + 0x18]
sub eax, dword [esi + 0xc]
movsd qword [esp + 0x40], xmm0
cmp eax, 0x10
jge 0x429c7f
push ecx
mov ecx, esi
call fcn.0042a130
mov ecx, dword [esi + 0xc]
xorps xmm0, xmm0
lea eax, [ecx + 0x10]
mov dword [esi + 0xc], eax
mov eax, 0x216
movups xmmword [ecx], xmm0
mov word [ecx + 0xe], ax
movsd xmm0, qword [esp + 0x40]
movsd qword [ecx], xmm0
pop edi
pop esi
mov esp, ebp
pop ebp
ret 8
cmp byte [esp + 9], 0
je 0x429d04
cmp byte [esp + 0xa], 0
je 0x429cd2
mov eax, dword [esp + 0x10]
mov ecx, dword [esp + 0xc]
neg eax
adc ecx, 0
neg ecx
push ecx
mov ecx, dword [ebp + 0xc]
push eax
call fcn.00429ee0
jmp 0x429ce2
push dword [esp + 0xc]
mov ecx, dword [ebp + 0xc]
push dword [esp + 0x14]
call fcn.00429e50
test al, al
jne 0x429da5
mov eax, dword [esp + 0x20]
mov ecx, dword [esp + 0x24]
mov dword [eax + 0x18], 0x10
mov dword [eax + 0x1c], ecx
pop edi
pop esi
mov esp, ebp
pop ebp
ret 8
mov edi, dword [ebp + 0xc]
mov eax, dword [edi + 0x28]
lea ecx, [edi + 0x18]
sub eax, dword [edi + 0x24]
cmp byte [esp + 0xa], 0
je 0x429d56
neg esi
cmp eax, 0x10
jge 0x429d24
push ecx
call fcn.0042a130
mov ecx, dword [edi + 0x24]
xorps xmm0, xmm0
test esi, esi
lea eax, [ecx + 0x10]
mov dword [edi + 0x24], eax
mov eax, esi
cdq
movups xmmword [ecx], xmm0
mov dword [ecx], eax
mov eax, 0xb6
mov dword [ecx + 4], edx
mov edx, 0x1f6
cmovns eax, edx
mov word [ecx + 0xe], ax
pop edi
pop esi
mov esp, ebp
pop ebp
ret 8
cmp eax, 0x10
jge 0x429d61
push ecx
call fcn.0042a130
mov ecx, dword [edi + 0x24]
xorps xmm0, xmm0
lea eax, [ecx + 0x10]
mov dword [edi + 0x24], eax
movups xmmword [ecx], xmm0
mov dword [ecx], esi
shr esi, 0x1a
not esi
mov dword [ecx + 4], 0
and esi, 0x20
or esi, 0x1d6
mov word [ecx + 0xe], si
pop edi
pop esi
mov esp, ebp
pop ebp
ret 8
sub eax, dword [edi + 0xc]
sar eax, 1
add eax, dword [edi + 0x20]
mov dword [edx + 0x18], 3
mov dword [edx + 0x1c], eax
pop edi
pop esi
mov esp, ebp
pop ebp
ret 8