Function at 0x1005dfd0
Capabilities:
Encrypt data using rc4 prga
Validate payment card number using luhn algorithm

Disassembly:
push ebp
mov ebp, esp
push 0xfffffffffffffffe
push 0x1016e158
push 0x10118480
mov eax, dword fs:[0]
push eax
sub esp, 0x20
push ebx
push esi
push edi
mov eax, dword [0x1017455c]
xor dword [ebp - 8], eax
xor eax, ebp
push eax
lea eax, [ebp - 0x10]
mov dword fs:[0], eax
mov dword [ebp - 0x18], esp
mov esi, ecx
xor edi, edi
mov dword [ebp - 4], edi
mov dword [ebp - 0x24], edi
mov dword [ebp - 0x20], edi
call fcn.10035e40
mov ecx, eax
mov byte [ebp - 0x19], 0
mov dword [ebp - 0x28], esi
mov dword [ebp - 0x30], edi
cmp esi, edi
je 0x1005e033
cmp esi, 1
je 0x1005e02f
mov dword [ebp - 0x28], edi
jmp 0x1005e033
cmp esi, edi
jne 0x1005e060
mov eax, 0x4ec4ec4f
mul ecx
shr edx, 3
imul edx, edx, 0x1a
mov ebx, ecx
sub ebx, edx
mov byte [ebp - 0x19], bl
movzx eax, bl
add eax, 0x61
cmp eax, 0x6c
je 0x1005e05c
cmp eax, 0x69
je 0x1005e05c
cmp eax, 0x6f
jne 0x1005e076
inc bl
jmp 0x1005e073
mov eax, 0xcccccccd
mul ecx
shr edx, 3
lea eax, [edx + edx*4]
add eax, eax
mov ebx, ecx
sub ebx, eax
mov byte [ebp - 0x19], bl
movzx eax, bl
cdq
mov ecx, 0xa
idiv ecx
mov byte [ebp - 0x1a], dl
mov edx, dword [ebp + 8]
cmp byte [edx], 0
je 0x1005e237
mov eax, dword [ebp + 0x10]
test eax, eax
je 0x1005e237
add eax, 2
push eax
push 0
mov esi, dword [ebp + 0xc]
push esi
call fcn.10116880
add esp, 0xc
mov ecx, dword [ebp + 0x10]
mov eax, ecx
and eax, 0x80000001
jns 0x1005e0be
dec eax
or eax, 0xfffffffe
inc eax
mov eax, ecx
cdq
jne 0x1005e0c9
sub eax, edx
sar eax, 1
jmp 0x1005e0ce
sub eax, edx
sar eax, 1
inc eax
mov dword [ebp - 0x2c], eax
xor eax, eax
mov dword [ebp - 0x24], eax
cmp eax, ecx
jge 0x1005e206
cmp edi, dword [ebp - 0x2c]
jne 0x1005e101
cmp dword [ebp - 0x28], 0
jne 0x1005e0f4
movzx ecx, bl
add ecx, 0x61
mov byte [edi + esi], cl
jmp 0x1005e0fd
movzx edx, bl
add edx, 0x30
mov byte [edi + esi], dl
inc edi
mov dword [ebp - 0x20], edi
mov ecx, dword [ebp + 8]
mov al, byte [eax + ecx]
mov dl, al
sub dl, 0x41
cmp dl, 0x19
ja 0x1005e173
movsx eax, al
movzx ecx, bl
lea ecx, [eax + ecx - 0x41]
cmp ecx, 0x1a
jl 0x1005e136
mov eax, 0x4ec4ec4f
imul ecx
sar edx, 3
mov eax, edx
shr eax, 0x1f
add eax, edx
imul eax, eax, 0x1a
sub ecx, eax
mov al, byte [ecx + 0x1018ccb4]
cmp al, 0x61
jb 0x1005e15d
cmp al, 0x7a
ja 0x1005e15d
movzx eax, al
sub eax, 0x20
mov byte [edi + esi], al
mov eax, dword [ebp - 0x24]
inc eax
inc edi
mov dword [ebp - 0x20], edi
mov ecx, dword [ebp + 0x10]
jmp 0x1005e0d3
movzx eax, al
mov byte [edi + esi], al
mov eax, dword [ebp - 0x24]
inc eax
inc edi
mov dword [ebp - 0x20], edi
mov ecx, dword [ebp + 0x10]
jmp 0x1005e0d3
mov cl, al
sub cl, 0x61
cmp cl, 0x19
ja 0x1005e1bb
movsx edx, al
movzx eax, bl
lea ecx, [edx + eax - 0x61]
cmp ecx, 0x1a
jl 0x1005e1a2
mov eax, 0x4ec4ec4f
imul ecx
sar edx, 3
mov eax, edx
shr eax, 0x1f
add eax, edx
imul eax, eax, 0x1a
sub ecx, eax
mov cl, byte [ecx + 0x1018ccb4]
mov byte [edi + esi], cl
mov eax, dword [ebp - 0x24]
inc eax
inc edi
mov dword [ebp - 0x20], edi
mov ecx, dword [ebp + 0x10]
jmp 0x1005e0d3
mov dl, al
sub dl, 0x30
cmp dl, 9
ja 0x1005e1f3
movsx eax, al
movzx ecx, byte [ebp - 0x1a]
lea ecx, [eax + ecx - 0x30]
cmp ecx, 0xa
jl 0x1005e1ed
mov eax, 0x66666667
imul ecx
sar edx, 2
mov eax, edx
shr eax, 0x1f
add eax, edx
lea edx, [eax + eax*4]
add edx, edx
sub ecx, edx
mov al, byte [ecx + 0x1018ccd0]
mov byte [edi + esi], al
mov eax, dword [ebp - 0x24]
inc eax
inc edi
mov dword [ebp - 0x20], edi
mov ecx, dword [ebp + 0x10]
jmp 0x1005e0d3
cmp edi, 1
jne 0x1005e23a
mov edi, 2
mov dword [ebp - 0x20], edi
cmp dword [ebp - 0x28], 0
jne 0x1005e228
movzx ecx, bl
add ecx, 0x61
mov byte [esi + 1], cl
mov byte [edi + esi], 0
jmp 0x1005e258
movzx edx, bl
add edx, 0x30
mov byte [esi + 1], dl
mov byte [edi + esi], 0
jmp 0x1005e258
mov esi, dword [ebp + 0xc]
mov byte [edi + esi], 0
jmp 0x1005e258
mov dword [ebp - 4], 0xfffffffe
mov ecx, dword [ebp - 0x10]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret